Motion - Support Question 2013x 07x 07x 185426

ffmpeg_open: avcodec_open - could not open codec mpeg4

Question

I build ffmpeg RPM and motion RPM for pidora on my raspberry pi. ffmpeg: FFmpeg version 0.6.6, Copyright (c) 2000-2010 the FFmpeg developers built on Jul 4 2013 10:28:23 with gcc 4.7.2 20120921 (Red Hat 4.7.2-2) configuration: --prefix=/usr --libdir=/usr/lib --shlibdir=/usr/lib --mandir=/usr/share/man --incdir=/usr/include --disable-avisynth --enable-avfilter --enable-avfilter-lavf --enable-libdc1394 --enable-libdirac --enable-libfaac --enable-libfaad --enable-libfaadbin --enable-libgsm --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libx264 --enable-gpl --enable-nonfree --enable-postproc --enable-pthreads --enable-shared --enable-swscale --enable-vdpau --enable-version3 --enable-x11grab libavutil 50.15. 1 / 50.15. 1 libavcodec 52.72. 2 / 52.72. 2 libavformat 52.64. 2 / 52.64. 2 libavdevice 52. 2. 0 / 52. 2. 0 libavfilter 1.19. 0 / 1.19. 0 libswscale 0.11. 0 / 0.11. 0 libpostproc 51. 2. 0 / 51. 2. 0

motion is build from the actual trunk using this ffmpeg installation.

When i start "motion -c /etc/motion/motion.cfg" i'll get the following error in the logfile:

Encoding using ffmpeg as command will work very well!

ffmpeg -f video4linux2 -s 1280x720 -r 25 -i /dev/video0 -vcodec mpeg4 TEST-VIDEO.avi
motion.log:

[1] [NTC] [ALL] [Jul 07 20:52:59] motion_init: Started motion-stream server in port 8081 auth Disabled
[1] [NTC] [EVT] [Jul 07 20:53:01] event_new_video FPS 5
[1] [ERR] [ENC] [Jul 07 20:53:01] ffmpeg_open: avcodec_open - could not open codec mpeg4
[1] [ERR] [EVT] [Jul 07 20:53:01] event_ffmpeg_newfile: ffopen_open error creating (new) file [/var/motion/01-20130707205301.avi]: Success
[1] [NTC] [ALL] [Jul 07 20:53:01] motion_detected: Motion detected - starting event 1
[1] [NTC] [ALL] [Jul 07 20:53:01] motion_loop: Thread exiting

motion.conf:
daemon on
process_id_file /var/run/motion.pid
setup_mode off
logfile /var/log/motion.log
log_level 6
log_type all
videodevice /dev/video0
v4l2_palette 17
input -1
norm 0
frequency 0
rotate 0
width 320
height 240
framerate 5
minimum_frame_time 0
netcam_keepalive off
netcam_tolerant_check off
auto_brightness off
brightness 0
contrast 0
saturation 0
hue 0
roundrobin_frames 1
roundrobin_skip 1
switchfilter off
threshold 1500
threshold_tune off
noise_level 32
noise_tune on
despeckle_filter EedDl
smart_mask_speed 0
lightswitch 0
minimum_motion_frames 1
pre_capture 0
post_capture 0
event_gap 60
max_movie_time 0
emulate_motion off
output_pictures off
output_debug_pictures off
quality 75
picture_type jpeg
ffmpeg_output_movies on
ffmpeg_output_debug_movies off
ffmpeg_timelapse 0
ffmpeg_timelapse_mode daily
ffmpeg_bps 500000
ffmpeg_variable_bitrate 0
ffmpeg_video_codec mpeg4
ffmpeg_deinterlace off
sdl_threadnr 0
use_extpipe off
snapshot_interval 0
locate_motion_mode off
locate_motion_style box
text_right %Y-%m-%d\n%T-%q
text_changes off
text_event %Y%m%d%H%M%S
text_double off
target_dir /var/motion
snapshot_filename %v-%Y%m%d%H%M%S-snapshot
picture_filename %v-%Y%m%d%H%M%S-%q
movie_filename %v-%Y%m%d%H%M%S
timelapse_filename %Y%m%d-timelapse
ipv6_enabled off
stream_port 8081
stream_quality 50
stream_motion off
stream_maxrate 1
stream_localhost on
stream_limit 0
stream_auth_method 0
webcontrol_port 8080
webcontrol_localhost on
webcontrol_html_output on
track_type 0
track_auto off
track_iomojo_id 0
track_step_angle_x 10
track_step_angle_y 10
track_move_wait 10
track_speed 255
track_stepsize 40
quiet on
on_movie_end /etc/motion/uploader.py /etc/motion/uploader.cfg %f

Environment

Motion version: trunkREV557
ffmpeg version: 0.6.6
Libraries: ffmpeg
Server OS: pidora 18
-- UweWeng - 07 Jul 2013

Answer

Topic revision: r1 - 07 Jul 2013, UweWeng
Copyright © 1999-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Please do not email Kenneth for support questions (read why). Use the Support Requests page or join the Mailing List.
This website only use harmless session cookies. See Cookie Policy for details. By using this website you accept the use of these cookies.