Using ffmpeg in the SDK Demo

Added by Jeremy Graham 1061 days ago

Hello, everybody:

I am trying to figure out how to capture the video stream from the AR Drone as a video file. After reading the developers guide, I decided that the best way to learn how to do this is to modify the 'video_stage.c' file that is found in the SDK Demo. I am making an attempt to do this by borrowing code from here:

However, when I try to compile using the makefile provided by Parrot, I get a series of errors:
../../Soft/Build/targets_versions/linux_sdk_demo_PROD_MODE_ffmpeg_Intel_Linux_3.0.0-14-generic-pae_GNU_Linux_gcc_4.6.1/Video/video_stage.o: In function `output_gtk_stage_open':
video_stage.c:(.text+0x4c): undefined reference to `avcodec_find_encoder'
video_stage.c:(.text+0x5e): undefined reference to `avcodec_alloc_context'
video_stage.c:(.text+0x68): undefined reference to `avcodec_alloc_frame'
video_stage.c:(.text+0xc8): undefined reference to `avcodec_open'
video_stage.c:(.text+0x107): undefined reference to `please_use_vp_os_malloc'
video_stage.c:(.text+0x135): undefined reference to `please_use_vp_os_malloc'
collect2: ld returned 1 exit status

I also get a couple of messages about deprecated functions. I assume that the above errors occur because the necessary instructions to link the required ffmpeg libraries are not in the given makefile. Has anybody accomplished this task already? If so, could you tell me how to modify the makefile so that I can compile (and execute) my modified version of the SDK Demo? Anybody's help would be most appreciated!