Closed moveman closed 1 year ago
@moveman agreed, this is weird. I am not clear on the utility of this VodCore. I have replaced one VodCoreException with a BitStreamException in commit a302806, however I don't know whether this can be generalized. @xavery maybe you could advise on this ?
Hi @jcdr428 , @xavery , actually changing to catch BitStreamException cannot help much. The muxed file is still abnormal. Could you check why tsMuxeR failed to mux this https://drive.google.com/drive/folders/1Q-eC7bbNa5KycTCE7iad8rOQQvCi-3Q8?usp=share_link ? The stack trace is like this:
(gdb) bt
#0 0x00007ffff6b32387 in raise () from /lib64/libc.so.6
#1 0x00007ffff6b33a78 in abort () from /lib64/libc.so.6
#2 0x00007ffff7442a95 in __gnu_cxx::__verbose_terminate_handler() () from /lib64/libstdc++.so.6
#3 0x00007ffff7440a06 in ?? () from /lib64/libstdc++.so.6
#4 0x00007ffff7440a33 in std::terminate() () from /lib64/libstdc++.so.6
#5 0x00007ffff7440c53 in __cxa_throw () from /lib64/libstdc++.so.6
#6 0x0000000000547e8a in BitStreamReader::skipBits (this=0x93e3b8, num=8) at ../tsMuxer/bitStream.h:130
#7 0x000000000057f3bb in HevcHdrUnit::deserialize (this=0x93e390) at ../tsMuxer/hevc.cpp:918
#8 0x000000000058386f in HEVCStreamReader::checkStream (this=0x93d480, buffer=0x7ffff5ec0010 "", len=2097152)
at ../tsMuxer/hevcStreamReader.cpp:90
#9 0x0000000000583f0e in HEVCStreamReader::getTSDescriptor (this=0x93d480, dstBuff=0x7fffffffbbe0 "", blurayMode=false,
hdmvDescriptors=false) at ../tsMuxer/hevcStreamReader.cpp:145
#10 0x000000000062f08d in TSMuxer::intAddStream (this=0x93e720, streamName=..., codecName=..., streamIndex=1, params=...,
codecReader=0x93d480) at ../tsMuxer/tsMuxer.cpp:172
#11 0x00000000005f4ffb in MuxerManager::preinitMux (this=0x7fffffffd990, outFileName=..., fileFactory=0x0)
at ../tsMuxer/muxerManager.cpp:149
#12 0x00000000005f53e5 in MuxerManager::doMux (this=0x7fffffffd990, outFileName=..., fileFactory=0x0)
at ../tsMuxer/muxerManager.cpp:197
#13 0x000000000059bbf7 in main (argc=3, argv=0x7fffffffe088) at ../tsMuxer/main.cpp:758
@moveman no error with latest release 7165e3b on w64. What release and OS are you using ?
Hi @jcdr428, thanks for your reply. Right, it seems no error with latest release but the output should be abnormal. If you check the mediainfo (https://sourceforge.net/projects/mediainfo/) of the muxed TS, I remember the video stream is missing in the mediainfo. So the output TS is abnormal.
We are using Nightly build from 2021-02-13-01-46-27 Pre-release. OS is Centos 7.
@moveman agreed, this is weird. I am not clear on the utility of this VodCore. I have replaced one VodCoreException with a BitStreamException in commit a302806, however I don't know whether this can be generalized. @xavery maybe you could advise on this ?
Hard to say what the intent was here. A BitStreamException
can be thrown by BitStream
classes themselves so perhaps it was meant to bubble up and not be caught here. Either way, "mismatched" throw
and catch
as described here is not necessarily an error.
We are using Nightly build from 2021-02-13-01-46-27
Wow. A lot has happened in the 21 months since 2021-02-13...
I remember the video stream is missing in the mediainfo
With w64 and latest release, I have no problems playing the .ts and with its mediainfo. So I can't help.
Hi @jcdr428 , thanks a lot for your time. Indeed latest release work well with the last asset.
But I have tried it on another one here https://drive.google.com/drive/folders/1tHIOFF51PNC7qXMncko4Hdjt81ILtgPX?usp=sharing and the output is abnormal. I have also put the muxed TS there. You can see the mediainfo of 0.ts is:
The starting PTS is 4985900 (90k) which is also abnormal.
Would you also please try muxing this asset and see if you have any idea?
[vagrant@28845f8be915 bin]$ ./tsMuxeR 0.meta 0.ts
tsMuxeR version git-260ffb2. github.com/justdan96/tsMuxer
HEVC muxing fps is not set. Get fps from stream. Value: 25
B-pyramid level 1 detected. Shift DTS to 2 frames
Bad SEI detected. SEI too short
Decoding AAC stream (track 2): Sample Rate: 24KHz Channels: 2
0.0% complete
Processed 8749 video frames
100.0% complete
Flushing write buffer
Mux successful complete
Muxing time: 0 sec
Many thanks!
Hi @jcdr428, do you confirm the output is abnormal, even muxing with latest release?
Hi @moveman, I am away this week. I'll try next week.
@moveman ok I think I understand what's the problem: the large -54sec. audio delay is above the 10sec. initial PTS offset. I have changed the initial PTS offset to 10min., please try tomorrows's release.
Edit: actually the best way would be to adapt the PTS offset from the largest detected delay. I'll work on this when I have time.
Closing. Can be reopened on request.
Is it expected call like m_reader.skipBits(8) will throw bitstreamException but the function will catch VodCoreException only? This caused exception to be thrown when m_reader has not enough buffer to read and program aborted. There are multiple places in the code like this. Shall all catch
(VodCoreException& e)
in hevc.cpp be changed tocatch(BitStreamException& e)
?