Closed norbusan closed 3 years ago
Thank you for reporting the issue.
However, I'm not being able to reproduce the issue. Having tried input mkv file with 7 subtitles, the subtitle tracks were in order in the output file.
I've tried command line below on both Windows and Ubuntu, but had no problem there.
It might be specific to input file. Would you please run again adding --log-level debug --log log.txt
and share the log.txt
file? It might provide some hints.
Thanks for looking into this. I just run:
nvencc" --log-level debug --log log.txt -i "/home/norbert/LOTR/LOTR1/The Lord of the Rings- The Fellowship of the Ring (EXT.) PT. 1.mkv" --audio-copy --sub-copy -o bla.mkv
and in the log file there is
avcuvid/avsw: found subtitle stream, stream idx 25, trackID 1.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 36, trackID 2.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 35, trackID 3.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 34, trackID 4.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 33, trackID 5.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 32, trackID 6.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 31, trackID 7.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 30, trackID 8.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 29, trackID 9.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 28, trackID 10.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 27, trackID 11.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 26, trackID 12.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 13, trackID 13.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 24, trackID 14.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 23, trackID 15.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 22, trackID 16.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 21, trackID 17.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 20, trackID 18.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 19, trackID 19.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 18, trackID 20.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 17, trackID 21.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 16, trackID 22.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 15, trackID 23.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 14, trackID 24.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
which seems strange that the stream idx
and the trackID
are not ordered in parallel.
I can send you the complete log (about 300M for conversion of a few minutes) if you want.
Thanks again.
Thank you for pointing out the problem from the log, it helped me much. I also think the log you mentioned shows where the problem is.
I made a commit ( 1e07de2 ) which I think will fix the problem. It removes the old and unnecessary code which I think was causing the problem.
Will you please pull and have a try?
Thanks a lot for the quick fix, this is MUCH appreciated!!! I can confirm that with the above commit the subtitles are now correctly ordered, and the log file shows the expected output:
avcuvid/avsw: found subtitle stream, stream idx 13, trackID 1.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 14, trackID 2.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 15, trackID 3.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 16, trackID 4.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 17, trackID 5.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 18, trackID 6.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 19, trackID 7.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 20, trackID 8.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 21, trackID 9.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 22, trackID 10.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 23, trackID 11.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 24, trackID 12.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 25, trackID 13.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 26, trackID 14.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 27, trackID 15.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 28, trackID 16.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 29, trackID 17.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 30, trackID 18.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 31, trackID 19.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 32, trackID 20.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 33, trackID 21.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 34, trackID 22.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 35, trackID 23.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
avcuvid/avsw: found subtitle stream, stream idx 36, trackID 24.0, hdmv_pgs_subtitle, frame_size 0, timebase 1/1000, delay 0 ms
Thank you for confirming, nice to hear it now works fine.
I'll have this issue closed now.
Yesterday I have tried to convert a BD 4k rip using nvencc. The video and audio worked absolutely correctly, but interestingly the subtitle tracks are completely messed up. I used
which is seemingly correct looking at the
mediainfo
output:But at the end, the encoded files gives me Finnish subtitles when selecting
English
etc. As far as I see the mapping that is there now isWhat one sees is that
Note that if I do NOT specify
--sub-metadata
and let nvencc copy the information I get the correct tagging of language, but as shown above in the secondActual
column, the order is very different from the original.I checked that the above
--sub-metadata
entries are all correct.This is with nvencc compiled from source in git checkout yesterday, running on Debian/sid.
Thanks
追加:今気が付きましたが、日本語でも連絡して構いません。よろしくお願いします。