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

trying to decode #23

Open
piniSolomon opened this issue Dec 18, 2022 · 2 comments
Open

trying to decode #23

piniSolomon opened this issue Dec 18, 2022 · 2 comments

Comments

@piniSolomon
Copy link

piniSolomon commented Dec 18, 2022

hi, I'm trying to use the library with some mp4 I downloaded from the internet (from here https://dvdloc8.com/clip.php?movieid=8419&clipid=2)
and getting an error, H264BSD_ERROR. when trying the files in the test folder it works.
so I'm guessing I don't understand something. Both files are played with vlc player.
Can you help me understand if this library can decode some "regular" mp4?

@Heath123
Copy link

I think you need to do something like
ffmpeg -i video.mp4 -vcodec copy -an -bsf:v h264_mp4toannexb video.h264
though I'm still getting some errors when I do that (but it's close at least because if I comment out the error checks it sort of works)

@oneam
Copy link
Owner

oneam commented Jan 16, 2023

As long as the video is encoded in Constrained Baseline Profile it should decode fine after the ffmpeg conversion. If it doesn't work, try this incantation:

ffmpeg -i video.mp4 -profile:v baseline video.h264

That will re-encode the video into Annex B H.264 using constrained baseline profile.

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