Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multi-threaded decoding error in ver2.4.1 #3733

Closed
y9o opened this issue Mar 21, 2024 · 1 comment
Closed

Multi-threaded decoding error in ver2.4.1 #3733

y9o opened this issue Mar 21, 2024 · 1 comment

Comments

@y9o
Copy link

y9o commented Mar 21, 2024

Hello,

It seems that setting DECODER_OPTION_NUM_OF_THREADS to 2 or higher leads to hang-ups. This issue is not present in older versions.

Symptoms similar to issue #3487.

h264dec.cpp:

  int32_t iThreadCount = 3;
  pDecoder->SetOption (DECODER_OPTION_NUM_OF_THREADS, &iThreadCount);

Hang-ups observed:

openh264-2.4.1$ wget https://test-videos.co.uk/vids/bigbuckbunny/mp4/h264/1080/Big_Buck_Bunny_1080_10s_30MB.mp4
openh264-2.4.1$ ffmpeg -i Big_Buck_Bunny_1080_10s_30MB.mp4 -map 0:0 -vcodec copy -an Big_Buck_Bunny_1080_10s_30MB.264
openh264-2.4.1$ make -j BUILDTYPE=Release USE_ASM=No HAVE_AVX2=No
openh264-2.4.1$ ./h264dec Big_Buck_Bunny_1080_10s_30MB.264 x.yuv  -trace 8
[OpenH264] this = 0x0x56518f677ee0, Info:CWelsDecoder::init_decoder(), openh264 codec version = , ParseOnly = 0
[OpenH264] this = 0x0x56518f677ee0, Info:CWelsDecoder::init_decoder(), openh264 codec version = , ParseOnly = 0
[OpenH264] this = 0x0x56518f677ee0, Info:eVideoType: 1
[OpenH264] this = 0x0x56518f677ee0, Info:CWelsDecoder::init_decoder(), openh264 codec version = , ParseOnly = 0
[OpenH264] this = 0x0x56518f677ee0, Info:eVideoType: 1
[OpenH264] this = 0x0x56518f677ee0, Info:CWelsDecoder::init_decoder(), openh264 codec version = , ParseOnly = 0
[OpenH264] this = 0x0x56518f677ee0, Info:eVideoType: 1
[OpenH264] this = 0x0x56518f677ee0, Info:CWelsDecoder::SetOption for ERROR_CON_IDC = 2.
H264 source file name: Big_Buck_Bunny_1080_10s_30MB.264..
Sequence output file name: x.yuv..
------------------------------------------------------
[OpenH264] this = 0x0x56518f677ee0, Info:WelsRequestMem(): memory alloc size = 1920 * 1088, ref list size = 20
[OpenH264] this = 0x0x56518f677ee0, Info:SyncPictureResolutionExt(), overall memory usage: 116230782 bytes
[OpenH264] this = 0x0x56518f677ee0, Info:DecodeFrameConstruction(): will output first frame of new sequence, 1920 x 1088, crop_left:0, crop_right:0, crop_top:0, crop_bottom:4, ignored error packet:0.
[OpenH264] this = 0x0x56518f677ee0, Error:DecodeCurrentAccessUnit()::::::PrefetchPic ERROR, pSps->iNumRefFrames:16.
[OpenH264] this = 0x0x56518f677ee0, Debug:returned error from decoding:[0x3f2]
[OpenH264] this = 0x0x56518f677ee0, Info:ResetDecoder(), context error code is 16384

Thank you.

@y9o y9o changed the title Multi-threaded Decoding Error in ver2.4.1 Multi-threaded decoding error in ver2.4.1 Mar 21, 2024
@tyan0
Copy link
Contributor

tyan0 commented Mar 23, 2024

Hi,

This seems due to my commit 0a6d2d8 via #3707.
I would like to create another PR to fix that. Sorry for my mistake.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants