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

sws_scale crashes with small resolution #656

Open
bign0name opened this issue Nov 7, 2023 · 3 comments
Open

sws_scale crashes with small resolution #656

bign0name opened this issue Nov 7, 2023 · 3 comments

Comments

@bign0name
Copy link

bign0name commented Nov 7, 2023

sws_scale crashes with small resolution

The video I am trying to play a video that has a resolution of 202x360. The first few frames get materialized fine, then sws_scale will cause the program to crash with exit code (0xc0000374). I have analyzed the target scan, stride, data, linesize - nothing seems off. The video plays fine in ffplay or any other player. I wanted to add a try catch to sws_scale, if it cant scale then skip the frame, but issue is the whole program crashes, can't try catch the method.

Issue Categories

  • [✅] Bug

Steps to Reproduce

  1. Try to play this video
exampleTiktokRes.mp4

Expected Results

  • Plays Video

Sample Code

Crashes from this method:

var outputHeight = ffmpeg.sws_scale(

@bign0name
Copy link
Author

@MrBean2016 how can I get some error info from sws_scale? The program crashes instantly after it fails.

@MrBean2016
Copy link
Contributor

@MrBean2016 how can I get some error info from sws_scale? The program crashes instantly after it fails.

I could play the clip without any errors. I do not use the Nuget-packet, I use the source as an component in my project. The ffmpeg version is 6.0

If you play your clip with the sample application, does it work?

One way to debug your application might be activate native debugging since ffmpeg is a collection of native C-libraries. Another is to bump to the the latest FFMPEG 6.1 and see if the problem goes away. Also check if there are any async calls in GUI with callbacks into the GUI, that is often an area where problem occurs.

@bign0name
Copy link
Author

Sorry for the late reply. I am using ffmpeg version 6.1, (i tried 4.8 , 6.0 , 6.1) my sample app is just player in mainwindow. Here is a video of the crash. Please note the exact same video with normal aspect ratio plays perfectly.

2023-11-19.17-39-33.mp4

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

2 participants