Hi to all,

it took me quite some time, but I seem to have achieved encoding a synthesized video to an h264 or h265 file and the decode it again. I collected bits and pieces from bug trackers, orphaned (unanswered) mails to this mailing list and other blog posts to actually made it happen. the ffmpeg API documentation didn't help me at all, or I overlooked something obvious.

Feel free to help me further, correct me or point me to more intuitive documentation either through this mailing list or the github repo which contains my code:
https://github.com/psteinb/libav-h26x-sandbox

Best,
Peter

On 08/12/2015 05:10 PM, Peter Steinbach wrote:
Hi to all,

I've recently started experimenting with ffmpeg to use it in order to
encode 3D objects (for a scientific purpose rather than stereoscopic
vision before anyone asks). Based on my missing knowledge in video
encoding/decoding, I used the ffmpeg example  and modified it
decoding_encoding.c so that I can create a 3D 8bit object and then
encode it with HEVC and re-read it back to produce *.pgm files.

However the decoding step produces just 2 images, which is clearly not
what I was expecting given than I encoded 25 frames. I am also getting
error messages like
[hevc @ 0xe58760] Invalid NAL unit 0, skipping.
During the decoding. Does anyone have an idea what I did wrong?


I upload the source code here:
https://gist.github.com/psteinb/bf12348d799108f390f5

Running ffprobe on the produced *.h265 file yields:
ffprobe version 2.5.8 Copyright (c) 2007-2015 the FFmpeg developers
   built on Aug 11 2015 08:55:10 with gcc 4.9.2 (GCC) 20150212 (Red Hat
4.9.2-6)
   configuration: --prefix=/home/steinbac/software/ffmpeg/2.5.8
--enable-libx265 --enable-libx264 --enable-gpl --enable-shared
   libavutil      54. 15.100 / 54. 15.100
   libavcodec     56. 13.100 / 56. 13.100
   libavformat    56. 15.102 / 56. 15.102
   libavdevice    56.  3.100 / 56.  3.100
   libavfilter     5.  2.103 /  5.  2.103
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
Input #0, hevc, from 'ffmpeg_roundtrip.h265':
   Duration: N/A, bitrate: N/A
     Stream #0:0: Video: hevc (Main), yuv420p(tv), 352x288, 25 fps, 25
tbr, 1200k tbn, 25 tbc

Any help would be appreciated!
Best,
Peter
_______________________________________________
Libav-user mailing list
[email protected]
http://ffmpeg.org/mailman/listinfo/libav-user
_______________________________________________
Libav-user mailing list
[email protected]
http://ffmpeg.org/mailman/listinfo/libav-user

Reply via email to