This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

[HELP] Rename tracks help please and help with chapters
#11
Looking at what happens:
  1. first audio stream get's extracted (17_54_42_1410_01_audio)
    "D:\Programs\Hybrid\64bit\ffmpeg.exe" -y -threads 8 -i "G:\PLEX Media\New Things To Sort\Eragon (2006)\Eragon (2006).mp4" -map 0:1 -vn -sn -acodec copy  -map_metadata -1 -metadata handler_name="Hybrid 2018.07.27.1" "C:\Users\mapsk\AppData\Local\Temp\iId_1_aid_0_lang_en_17_54_42_1410_01.aac"
  2. second audio stream get's extracted (17_54_42_1410_02_audio)
    MP4Box -raw 2 "G:\PLEXME~1\NEWTHI~1\ERAGON~1\ERAGON~1.MP4" -out "C:\Users\mapsk\AppData\Local\Temp\iId_2_aid_1_lang_en_17_54_42_1410_02.ac3"
  3. second audio stream is converted to 128kBit/s ac3 (17_54_42_1410_03_audio)
    ffmpeg -y -threads 8 -i "C:\Users\mapsk\AppData\Local\Temp\iId_2_aid_1_lang_en_17_54_42_1410_02.ac3" -b:a 128k -ac 2 -ar 48000 -channel_layout stereo "C:\Users\mapsk\AppData\Local\Temp\iId_2_aid_1_lang_en_17_54_42_1410_03.ac3"
  4. old temporary second audio stream get's deleted (17_54_42_1410_03_audio)
  5. subtitles get converted form .srt to ttxt (17_54_42_1410_05_subs)
  6. time codes get saved into a file (17_54_42_1410_06_create)
  7. video get's extracted (17_54_42_1410_07_video)
  8. Video get's remuxed into an mp4 container (17_54_42_1410_08_muxing)
    MP4Box -par 1=1:1 -add "C:\Users\mapsk\AppData\Local\Temp\Eragon (2006)_new_17_54_42_1410_07.264" -brand avc1 -tmp "C:\Users\mapsk\AppData\Local\Temp" -new "G:\PLEX Media\New Things To Sort\Eragon (2006)\17_54_42_1410__08_mp4Temp.mp4"
  9. Old extracted video stream gets deleted (17_54_42_1410_09_cleanUp)
  10. Time codes get added to the temporary mp4 file (17_54_42_1410_10_muxing)
    mp4fpsmod -t "C:\Users\mapsk\AppData\Local\Temp\timecodeV2_17_54_42_1410.tc" -x "G:\PLEX Media\New Things To Sort\Eragon (2006)\17_54_42_1410__08_mp4Temp.mp4" -o "G:\PLEX Media\New Things To Sort\Eragon (2006)\17_54_42_1410__10_withTimeCodes_0.mp4"
  11. Old temporary mp4 files gets deleted (17_54_42_1410_11_cleanUp)
  12. Time code file gets deleted (17_54_42_1410_12_cleanUp)
  13. Current mp4 file gets renamed (17_54_42_1410_13_rename)
  14. Chaper information get saved into a chapter file (17_54_42_1410_14_create)
  15. Audio, subtitles and tags get added to the mp4 file (17_54_42_1410_15_muxing)
  16. Old mp4 file gets deleted (17_54_42_1410_16_cleanUp)
  17. Old audio file (1st) get's deleted (17_54_42_1410_17)
  18. Old audio file (2nd) get's deleted (17_54_42_1410_18)
  19. Old chapter file get's deleted (17_54_42_1410_19)
  20. Mp4 file gets renamed (17_54_42_1410_20_rename)
  21. Old subtitle file get's deleted (17_54_42_1410_21)
Only thing that seems uncommon is that Hybrid first uses ffmpeg and then MP4Box for the audio extraction.
-> Try whether it helps to enable: "Config->Intput->Extraction->Stream extraction with ffmpeg"

Cu Selur

Ps.: A small sample of the input file would be nice to reproduce this here.
Reply
#12
(05.08.2018, 08:39)Selur Wrote: Looking at what happens:
  1. first audio stream get's extracted (17_54_42_1410_01_audio)
    "D:\Programs\Hybrid\64bit\ffmpeg.exe" -y -threads 8 -i "G:\PLEX Media\New Things To Sort\Eragon (2006)\Eragon (2006).mp4" -map 0:1 -vn -sn -acodec copy  -map_metadata -1 -metadata handler_name="Hybrid 2018.07.27.1" "C:\Users\mapsk\AppData\Local\Temp\iId_1_aid_0_lang_en_17_54_42_1410_01.aac"
  2. second audio stream get's extracted  (17_54_42_1410_02_audio)
    MP4Box -raw 2 "G:\PLEXME~1\NEWTHI~1\ERAGON~1\ERAGON~1.MP4" -out "C:\Users\mapsk\AppData\Local\Temp\iId_2_aid_1_lang_en_17_54_42_1410_02.ac3"
  3. second audio stream is converted to 128kBit/s ac3 (17_54_42_1410_03_audio)
    ffmpeg -y -threads 8 -i "C:\Users\mapsk\AppData\Local\Temp\iId_2_aid_1_lang_en_17_54_42_1410_02.ac3" -b:a 128k -ac 2 -ar 48000 -channel_layout stereo "C:\Users\mapsk\AppData\Local\Temp\iId_2_aid_1_lang_en_17_54_42_1410_03.ac3"
  4. old temporary second audio stream get's deleted (17_54_42_1410_03_audio)
  5. subtitles get converted form .srt to ttxt (17_54_42_1410_05_subs)
  6. time codes get saved into a file (17_54_42_1410_06_create)
  7. video get's extracted (17_54_42_1410_07_video)
  8. Video get's remuxed into an mp4 container (17_54_42_1410_08_muxing)
    MP4Box -par 1=1:1 -add "C:\Users\mapsk\AppData\Local\Temp\Eragon (2006)_new_17_54_42_1410_07.264" -brand avc1 -tmp "C:\Users\mapsk\AppData\Local\Temp" -new "G:\PLEX Media\New Things To Sort\Eragon (2006)\17_54_42_1410__08_mp4Temp.mp4"
  9. Old extracted video stream gets deleted (17_54_42_1410_09_cleanUp)
  10. Time codes get added to the temporary mp4 file (17_54_42_1410_10_muxing)
    mp4fpsmod -t "C:\Users\mapsk\AppData\Local\Temp\timecodeV2_17_54_42_1410.tc" -x "G:\PLEX Media\New Things To Sort\Eragon (2006)\17_54_42_1410__08_mp4Temp.mp4" -o "G:\PLEX Media\New Things To Sort\Eragon (2006)\17_54_42_1410__10_withTimeCodes_0.mp4"
  11. Old temporary mp4 files gets deleted (17_54_42_1410_11_cleanUp)
  12. Time code file gets deleted (17_54_42_1410_12_cleanUp)
  13. Current mp4 file gets renamed (17_54_42_1410_13_rename)
  14. Chaper information get saved into a chapter file (17_54_42_1410_14_create)
  15. Audio, subtitles and tags get added to the mp4 file (17_54_42_1410_15_muxing)
  16. Old mp4 file gets deleted (17_54_42_1410_16_cleanUp)
  17. Old audio file (1st) get's deleted (17_54_42_1410_17)
  18. Old audio file (2nd) get's deleted (17_54_42_1410_18)
  19. Old chapter file get's deleted (17_54_42_1410_19)
  20. Mp4 file gets renamed (17_54_42_1410_20_rename)
  21. Old subtitle file get's deleted (17_54_42_1410_21)
Only thing that seems uncommon is that Hybrid first uses ffmpeg and then MP4Box for the audio extraction.
-> Try whether it helps to enable: "Config->Intput->Extraction->Stream extraction with ffmpeg"

Cu Selur

Ps.: A small sample of the input file would be nice to reproduce this here.
OK, so I did a few experiments, assuming I am doing it correctly, and noticed one thing I did not realize earlier.  The original source video had both audio channels, but I had already converted the second audio track to .ac3.  Not sure it is important, but there are three tests.  The first one, as you should be easily able to decipher from the log, I set to passthrough all audio, but left the force FFMPEG box unchecked.  The result was the same audio for both audio tracks.

Then, I switched back to custom, so the only thing that would change was the force FFMPEG checked.  This actually worked, and I had two separate audio tracks, BUT, it created a new, third audio track in the file, titled "Source Handling".  Not sure what that is, but I don't want it in the file.

Third, I tried passthrough all audio, and force FFMPEG checked, and the program crashed three times I tried to do it, including restarting the program, and starting over from scratch.

Finally, as you asked for, here is a small sample of the original source file, it is chapter 2 of the movie, and has both audio tracks.
Reply
#13
Looking at the crash call, I see nothing inherently wrong with the call.
What happens if you call:
"D:\Programs\Hybrid\64bit\MP4Box.exe" -add "G:\PLEXME~1\NEWTHI~1\ERAGON~1\06_06_~1.MP4" -add "C:\Users\mapsk\AppData\Local\Temp\IID_1_~2.AAC"#audio:name="5.1 Channels":lang="en" -mpeg4 -add "C:\Users\mapsk\AppData\Local\Temp\IID_2_~3.AC3"#audio:name="Commentary":lang="en" -chap "C:\Users\mapsk\AppData\Local\Temp\06_06_28_0310__15.chp" -add "C:\Users\mapsk\AppData\Local\Temp\06_06_~1.TTX":name="Movie Subtitles":lang="en" -itags name="Eragon (2006)":tool="Hybrid 2018.07.27.1" -tmp "C:\Users\mapsk\AppData\Local\Temp" -new "G:\PLEX Media\New Things To Sort\Eragon (2006)\06_06_28_0310__16.mp4
in a Windows command prompt?

Also the link to the source sample is missing. Smile

Cu Selur

Ps.: As a general side note: Whatever you did to create your source file it's strange that it's vfr.
Reply
#14
Wink 
(05.08.2018, 13:41)Selur Wrote: Looking at the crash call, I see nothing inherently wrong with the call.
What happens if you call:
"D:\Programs\Hybrid\64bit\MP4Box.exe" -add "G:\PLEXME~1\NEWTHI~1\ERAGON~1\06_06_~1.MP4" -add "C:\Users\mapsk\AppData\Local\Temp\IID_1_~2.AAC"#audio:name="5.1 Channels":lang="en" -mpeg4 -add "C:\Users\mapsk\AppData\Local\Temp\IID_2_~3.AC3"#audio:name="Commentary":lang="en" -chap "C:\Users\mapsk\AppData\Local\Temp\06_06_28_0310__15.chp" -add "C:\Users\mapsk\AppData\Local\Temp\06_06_~1.TTX":name="Movie Subtitles":lang="en" -itags name="Eragon (2006)":tool="Hybrid 2018.07.27.1" -tmp "C:\Users\mapsk\AppData\Local\Temp" -new "G:\PLEX Media\New Things To Sort\Eragon (2006)\06_06_28_0310__16.mp4
in a Windows command prompt?

Also the link to the source sample is missing. Smile

Cu Selur

Ps.: As a general side note: Whatever you did to create your source file it's strange that it's vfr.

I tried to upload the chapter 2 file, the smallest chapter I could see, but it was too big.  I was trying to reduce the file size, or trim it up, without changing anything in it, but everything I was doing was changing things.  Here is a link to the video sample file.  

Link for video file sample

What I have been doing with my movie collection, for consistency, is to rip my DVDs or Blu-rays with MakeMKV.  Then, for compatibility, changing and encoding it to .mp4 in Handbrake.  I can send you my settings if you wish.  I did not know about Hybrid at the time, but if I send you the settings, maybe you can tell me what settings I need to set in Hybrid, and I can save time and steps, and do it all in Hybrid, or the conversion process?  I don't really care which programs I have to use, but if I can simplify it, the better it is, and the easier it is on me.  Wink

On a side note, I also attached the screenshot of that command prompt code.  All I did is copy and paste it exactly, and was not using an elevated command prompt, but it did not like it.


Attached Files Thumbnail(s)
   
Reply
#15
Quote:Then, for compatibility, changing and encoding it to .mp4 in Handbrake.
And that is where you made your content vfr, my condolences. (personally I would delete such files)

The command line doesn't work any more since it looks like you deleted or moved one of the files. Smile

I'll look at the file.
Reply
#16
Okay.
1st go at it:
  1. Starting Hybrid
  2. Setting 'Base->Processing->Video' to 'passthrough'
  3. Setting 'Base->Processing->Audio' to 'passthrough (all)'
  4. Loading the source
  5. Settings the output file (with .mkv extension)
  6. adding job to queue (Base->Add to queue)
  7. Starting the job processing (Jobs->Queue->Start)
Result: mkv with both audio streams both tagged like in the source.
-> No problem.

2nd test:
Doing the same as int the first test, but using mp4 as output container.
-> No problem either, all tracks are properly tagged and present.

3rd test:
  1. Starting Hybrid
  2. Setting 'Base->Processing->Video' to 'passthrough'
  3. Setting 'Base->Processing->Audio' to 'custom'
  4. Loading the source
  5. Switching to the Audio-tab
  6. making sure the selected track (Audio->Base->Audio Source->Track) is '1 - en' and no audio compression is used ('Audio->Base->Audio Encoding Options' is disabled)
  7. adding track to Audio-Queue (Audio->Base->Add current)
  8. switching to the second audio track (by setting 'Audio->Base->Audio Source->Track' to '2 - en'
  9. enabling 'Audio->Base->Audio Encoding Options' since I want this stream to be reencoded
  10. switching to ac3 encoding, by setting 'Audio->Base->Audio Encoding Options->Encoder->Audio format' to 'ac3'
  11. adding track to Audio-Queue (Audio->Base->Add current)
  12. Settings the output file (with .mkv extension) (Base->Output file)
  13. adding job to queue (Base->Add to queue)
  14. Starting the job processing (Jobs->Queue->Start)
-> No problem, both audio tracks are present and properly tagged.

4th test:
Doing the same as in the 3rd test, but before setting the output file I change the tagging of the streams by:
  1. Enabling: Base->Tabs->Tagging
  2. Selecting the 1st audio stream (6channel aac) in 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Select audio stream to tag'
  3. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Title' and setting it to 'Main Audio'
  4. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Language' and setting it to 'English (eng - en)'
  5. adding this to the Tag-Queue by pressing 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Add to tag list'
  6. Selecting the 2nd audio stream (2channel ac3) in 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Select audio stream to tag'
  7. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Title' and setting it to 'Secondary Audio'
  8. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Language' and setting it to 'English (eng - en)'
  9. adding this to the Tag-Queue by pressing 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Add to tag list'
and also using .mp4 as output container.
-> No problem, both audio streams are present and tagged with the new tags.

5th test:
same as the 4th test, but I now also added two chapters under Chapter->Chapter Editor
-> Same as above + the two chapters I specified.

=> I can't reproduce the problems you are having at all. Hopefully my step-by-step tests help you to understand what you did differently.

Cu Selur
Reply
#17
(05.08.2018, 14:49)Selur Wrote:
Quote:Then, for compatibility, changing and encoding it to .mp4 in Handbrake.
And that is where you made your content vfr, my condolences. (personally I would delete such files)

The command line doesn't work any more since it looks like you deleted or moved one of the files. Smile

I'll look at the file.

What's wrong with .mp4 files?  I have a lot of movies, and .mp4 seems to have a lot more universal compatibility than .mkv.  If I can get a Blu-ray size to go from 35 GB to 4 GB, with no real noticeable loss in quality, and have several hundred movies in my collection, that is a lot of extra space on my hard drives. Would it be better to not have VFR?

(05.08.2018, 15:17)Selur Wrote: Okay.
1st go at it:
  1. Starting Hybrid
  2. Setting 'Base->Processing->Video' to 'passthrough'
  3. Setting 'Base->Processing->Audio' to 'passthrough (all)'
  4. Loading the source
  5. Settings the output file (with .mkv extension)
  6. adding job to queue (Base->Add to queue)
  7. Starting the job processing (Jobs->Queue->Start)
Result: mkv with both audio streams both tagged like in the source.
-> No problem.

2nd test:
Doing the same as int the first test, but using mp4 as output container.
-> No problem either, all tracks are properly tagged and present.

3rd test:
  1. Starting Hybrid
  2. Setting 'Base->Processing->Video' to 'passthrough'
  3. Setting 'Base->Processing->Audio' to 'custom'
  4. Loading the source
  5. Switching to the Audio-tab
  6. making sure the selected track (Audio->Base->Audio Source->Track) is '1 - en' and no audio compression is used ('Audio->Base->Audio Encoding Options' is disabled)
  7. adding track to Audio-Queue (Audio->Base->Add current)
  8. switching to the second audio track  (by setting 'Audio->Base->Audio Source->Track' to '2 - en'
  9. enabling 'Audio->Base->Audio Encoding Options' since I want this stream to be reencoded
  10. switching to ac3 encoding, by setting 'Audio->Base->Audio Encoding Options->Encoder->Audio format' to 'ac3'
  11. adding track to Audio-Queue (Audio->Base->Add current)
  12. Settings the output file (with .mkv extension) (Base->Output file)
  13. adding job to queue (Base->Add to queue)
  14. Starting the job processing (Jobs->Queue->Start)
-> No problem, both audio tracks are present and properly tagged.

4th test:
Doing the same as in the 3rd test, but before setting the output file I change the tagging of the streams by:
  1. Enabling: Base->Tabs->Tagging
  2. Selecting the 1st audio stream (6channel aac) in 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Select audio stream to tag'
  3. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Title' and setting it to 'Main Audio'
  4. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Language' and setting it to 'English (eng - en)'
  5. adding this to the Tag-Queue by pressing 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Add to tag list'
  6. Selecting the 2nd audio stream (2channel ac3) in 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Select audio stream to tag'
  7. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Title' and setting it to 'Secondary Audio'
  8. Enabling 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Language' and setting it to 'English (eng - en)'
  9. adding this to the Tag-Queue by pressing 'Tags->Streams->Audio stream tagging (mp4/mkv only)->Add to tag list'
and also using .mp4 as output container.
-> No problem, both audio streams are present and tagged with the new tags.

5th test:
same as the 4th test, but I now also added two chapters under Chapter->Chapter Editor
-> Same as above + the two chapters I specified.

=> I can't reproduce the problems you are having at all. Hopefully my step-by-step tests help you to understand what you did differently.

Cu Selur

Hmm, I will look back and do the same tests, but everything SEEMS to be the same way I've been doing it, I will perform all the same tests, and see if I can figure out what the difference is, and report back.  Were you using that chapter file I sent?
Reply
#18
Nope, I simply added some chapters manually like I wrote.
Chapter file can't cause a fix-up or missing streams.
(broken chapter file might cause problems during playback and muxing, but that's about it)

Quote:What's wrong with .mp4 files?
mp4 container is fine (not suited for most audio streams on Blu-rays but fine).

Quote:I have a lot of movies, and .mp4 seems to have a lot more universal compatibility than .mkv.
Definitely not the .mkv container allows way more stuff than the mp4 container.

Quote:Would it be better to not have VFR?
Yes! Since your source isn't vfr, I see no good reason why one would create vfr unless one does a lot of filtering on anime content and too much time. For natural content, which was properly mastered once there should be no reason to use vfr.
-> Going from cfr to vfr is normally a stupid thing.

Cu Selur
Reply
#19
(05.08.2018, 20:09)Selur Wrote: Nope, I simply added some chapters manually like I wrote.
Chapter file can't cause a fix-up or missing streams.
(broken chapter file might cause problems during playback and muxing, but that's about it)

Quote:What's wrong with .mp4 files?
mp4 container is fine (not suited for most audio streams on Blu-rays but fine).

Quote:I have a lot of movies, and .mp4 seems to have a lot more universal compatibility than .mkv.
Definitely not the .mkv container allows way more stuff than the mp4 container.

Quote:Would it be better to not have VFR?
Yes! Since your source isn't vfr, I see no good reason why one would create vfr unless one does a lot of filtering on anime content and too much time. For natural content, which was properly mastered once there should be no reason to use vfr.
-> Going from cfr to vfr is normally a stupid thing.

Cu Selur

Hmm, all of my comments seem to have disappeared when I posted them...

Basically, the gist was...

Test #1 worked fine, both audio tracks are present and tagged correctly, but it is in .mkv format, not .mp4, which is what I want.

Test #2 actually seemed to partially work correctly, it is in .mp4 format, it has both audio tracks, and both have the correct audio, tagged correctly, BUT, there is a new sound handler track in the file.  See attached screenshot.

Test #3 worked fine, both audio tracks are present and tagged correctly, but it is in .mkv format, not .mp4, which is what I want.

Test #4 seemed to work correctly, tags changed, both audio streams were present, however, the sound handler track is present once again.

Test #5 seemed to work correctly, tags changed, both audio streams were present, chapters were fine, however, the sound handler track is present once again.

The only difference is that I was using the add to queue and start button, instead of the add to queue button, followed separately by the Start Job button, and I was adding subtitles.  Not sure what changed, because none of that stuff should make any difference at all, unless it is the Stream extraction with FFMPEG option.

I added subtitles, and did the same as in test 3/4, but removed the checkbox from Config>Extraction>Stream extraction with FFMPEG, and everything seemed to work ok, EXCEPT once again, I have the same audio for both audio streams.  Why is it so hard to have an .mp4 container with multiple audio streams, without extra ones getting added it?  Why on earth does it do this??? Angry


Attached Files Thumbnail(s)
   
Reply
#20
Not sure if this should be in a different thread, but I tried to do it again, with the stream FFmpeg option checked, and it crashed with error 1.  Log is attached, did I do something wrong, without realizing it?
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)