video-app icon indicating copy to clipboard operation
video-app copied to clipboard

Assertion desc failed at src/libswscale/swscale_internal.h:764

Open H-A-a-12 opened this issue 4 years ago • 4 comments

Issue when passing video or RTSP link in the code . Its show the strange bug when trying to run the exe.

[rtsp @ 0x55def0b00ac0] getaddrinfo(): Name or service not known [rtsp @ 0x55def0b00ac0] max delay reached. need to consume packet [rtsp @ 0x55def0b00ac0] RTP: missed 10 packets Assertion desc failed at src/libswscale/swscale_internal.h:764 Aborted (core dumped)

H-A-a-12 avatar Apr 18 '22 15:04 H-A-a-12

i have faced this similer error. tried many versions of ffmpeg

nowfalsalahudeen avatar Apr 21 '22 11:04 nowfalsalahudeen

Any solution?

MrStPL-codes avatar May 02 '22 10:05 MrStPL-codes

I had a similar error which was fixed when I realized that the code assumed that the VideoReaderState vr_state.sws_scaler_ctx was initialized to NULL. Since it is a local variable on the stack, it is not and the scaler was usuing a random part of memory as it's context. I added a constructor with initialization and my error was resolved. See commit d56d8c44136ae8d73770021c5424398796309ca7

If Bart wants a pull request, I can put one in. alternatively you can fix by adding after line 33 in main.cpp

VideoReaderState vr_state;
vr_state.sws_scaler_ctx = NULL;  // add this line as this pointer  is checked later to see if initialized and it must be NULL in order for initialization to happen

cleemesser avatar May 02 '22 17:05 cleemesser

I had a similar error which was fixed when I realized that the code assumed that the VideoReaderState vr_state.sws_scaler_ctx was initialized to NULL. Since it is a local variable on the stack, it is not and the scaler was usuing a random part of memory as it's context. I added a constructor with initialization and my error was resolved. See commit d56d8c44136ae8d73770021c5424398796309ca7

If Bart wants a pull request, I can put one in. alternatively you can fix by adding after line 33 in main.cpp

VideoReaderState vr_state;
vr_state.sws_scaler_ctx = NULL;  // add this line as this pointer  is checked later to see if initialized and it must be NULL in order for initialization to happen

it does help me, thanks.

ghexian avatar Jan 09 '23 09:01 ghexian