FFMPEG segfault on default recording
Versatile Commodore Emulator
Brought to you by:
blackystardust,
gpz
Expectation does not seem to be met at all. Saving a media file with ffmpeg should actually start recording to the defined file format and not stop until emulator exit (or entering the "save media file" menu again and stop recording) - at least that is what I remember from previous behaviour.
Used OS is (old) Ubuntu 12.04 - yasm 1.2 from source.
Start "x64sc" under linux - compiled with:
./configure --enable-gnomeui --enable-memmap --enable-ethernet --enable-fullscreen **--enable-shared-ffmpeg** --with-arts --disable-vte && make clean && make -s
and then installed.
A similar crash happens using "--enable-static-ffmpeg". shared-ffmpeg has a few more problems when actually installing the libraries, but thats a different issue.
"Save media file" -> "choose FFMPEG" -> leave options at default (mp3 sound, mp4 video) -> give path/filename -> instantly returns "file saved" requester (be puzzled) - pressing "ok" leads to this crash: # gdb x64sc GNU gdb (Ubuntu/Linaro 7.4-2012.04-0ubuntu2.1) 7.4-2012.04 Copyright (C) 2012 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". For bug reporting instructions, please see: <http://bugs.launchpad.net/gdb-linaro/>... Reading symbols from /usr/local/bin/x64sc...done. (gdb) run Starting program: /usr/local/bin/x64sc [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". ffmpeg avformat lib has version 380465, VICE expects 380465: full match ffmpeg avcodec lib has version 380164, VICE expects 380164: full match ffmpeg avutil lib has version 360764, VICE expects 360764: full match ffmpeg swscale lib has version 030064, VICE expects 030064: full match ffmpeg swresample lib has version 010164, VICE expects 010164: full match c64cartridge_reset changed: 1 [New Thread 0x7fffe9768700 (LWP 3050)] [New Thread 0x7fffe8f67700 (LWP 3051)] *** VICE Version 2.4.21, rev 30017M *** OS compiled for: Linux glibc 2.15 GUI compiled for: GTK+ CPU compiled for: AMD64/x86_64 Compiler used: GCC-4.6.3 Current OS: Linux 3.2.0-92-generic (glibc 2.15) Current CPU: Intel(R) Core(TM)2 Quad CPU Q9400 @ 2.66GHz Welcome to x64sc, the free portable C64 Emulator. Current VICE team members: Andreas Matthies, Martin Pottendorfer, Marco van den Heuvel, Fabrizio Gennari, Daniel Kahlin, Groepaz, Errol Smith, Olaf Seibert, Marcus Sutton, Kajtar Zsolt. This is free software with ABSOLUTELY NO WARRANTY. See the "About VICE" command for more info. X11: GTK version compiled with: 2.24 (xf86 ext:yes cairo:yes pango:yes VTE:no hwscale:yes fullscreen:yes ui-threads:no) XRandR: XRandR reports current display: 1920x1080@60 Loading system file `/usr/local/lib64/vice/C64/kernal'. Warning - ROM not patched: Already revision #3. Loading system file `/usr/local/lib64/vice/C64/basic'. Loading system file `/usr/local/lib64/vice/C64/chargen'. Loading system file `/usr/local/lib64/vice/PRINTER/mps803'. Palette: Loading palette `/usr/local/lib64/vice/PRINTER/mps803.vpl'. Loading system file `/usr/local/lib64/vice/PRINTER/nl10-cbm'. Palette: Loading palette `/usr/local/lib64/vice/PRINTER/nl10.vpl'. NL10: Printer driver initialized. Palette: Loading palette `/usr/local/lib64/vice/PRINTER/1520.vpl'. Loading system file `/usr/local/lib64/vice/DRIVES/dos1540'. Loading system file `/usr/local/lib64/vice/DRIVES/dos1541'. Loading system file `/usr/local/lib64/vice/DRIVES/d1541II'. Loading system file `/usr/local/lib64/vice/DRIVES/dos1570'. Loading system file `/usr/local/lib64/vice/DRIVES/dos1571'. Loading system file `/usr/local/lib64/vice/DRIVES/dos1581'. Loading system file `/usr/local/lib64/vice/DRIVES/dos2000'. Loading system file `/usr/local/lib64/vice/DRIVES/dos4000'. Loading system file `/usr/local/lib64/vice/DRIVES/dos2031'. Loading system file `/usr/local/lib64/vice/DRIVES/dos2040'. Loading system file `/usr/local/lib64/vice/DRIVES/dos3040'. Loading system file `/usr/local/lib64/vice/DRIVES/dos4040'. Loading system file `/usr/local/lib64/vice/DRIVES/dos1001'. Drive: Finished loading ROM images. VIC-II: Initializing chip model "MOS6569R3" (63 cycles per line, 312 raster lines). [New Thread 0x7fffe3198700 (LWP 3057)] Sound: Available sound devices: pulse alsa uss dummy fs dump wav voc iff aiff mp3 soundmovie Joystick: Linux joystick interface initialization... Joystick: /dev/input/js0 is HID 4242:0134 Joystick: Built in driver version: 2.1.0 Joystick: Kernel driver version : 2.1.0 Joystick: Warning - Cannot open joystick device `/dev/input/js1'. Joystick: Warning - Cannot open joystick device `/dev/input/js2'. Joystick: Warning - Cannot open joystick device `/dev/input/js3'. Joystick: Warning - Cannot open joystick device `/dev/input/js4'. Joystick: Warning - Cannot open joystick device `/dev/input/js5'. Keyboard: Loading keymap `/usr/local/lib64/vice/C64/x11_sym_de.vkm'. Main CPU: starting at ($FFFC). Main CPU: RESET. [New Thread 0x7fffd1db1700 (LWP 3058)] Sound: Opened device `pulse', speed 44100Hz, fragment size 1.5ms, buffer size 100ms reSID: MOS6581, filter on, sampling rate 44100Hz - fast Drive 8: RESET. [New Thread 0x7fffc9d1d700 (LWP 3060)] FFMPEG Driver: avi AC: MP2(86016) AC: MP3(86017) AC: FLAC(86028) AC: PCM uncompressed(65536) VC: MPEG4 (DivX)(13) VC: MPEG1(1) VC: FFV1 (lossless)(34) VC: H264(28) FFMPEG Driver: mp4 AC: MP3(86017) AC: AAC(86018) AC: AC3(86019) VC: H264(28) FFMPEG Driver: matroska AC: MP3(86017) AC: AAC(86018) AC: AC3(86019) VC: H264(28) FFMPEG Driver: wav FFMPEG Driver: mp3 VC: (0) FFMPEG Driver: mp2 [Thread 0x7fffe3198700 (LWP 3057) exited] [New Thread 0x7fffe3198700 (LWP 3061)] [New Thread 0x7fffc8fbd700 (LWP 3062)] FFMPEG: Driver: avi, ac: 86017, vc: 13 [Thread 0x7fffe3198700 (LWP 3061) exited] [Thread 0x7fffc9d1d700 (LWP 3060) exited] Sound: Closing device `pulse' [Thread 0x7fffd1db1700 (LWP 3058) exited] [New Thread 0x7fffd1db1700 (LWP 3063)] Sound: Opened device `pulse', speed 44100Hz, fragment size 1.5ms, buffer size 100ms reSID: MOS6581, filter on, sampling rate 44100Hz - fast Output #0, avi, to '/Data/torr/test3.avi': Stream #0:0: Video: mpeg4 (XVID / 0x44495658), yuv420p, 384x272, q=2-31, 800 kb/s, 50.12 tbn, 50.12 tbc Stream #0:1: Audio: mp3, 44100 Hz, mono, s32p, 64 kb/s ffmpegdrv: Initialized file successfully Sound: Opened recording device device `soundmovie' Program received signal SIGSEGV, Segmentation fault. 0x00007fffeba7b4b9 in ?? () from /usr/local/lib/libavcodec.so.56
(gdb) bt #0 0x00007fffeba7b4b9 in ?? () from /usr/local/lib/libavcodec.so.56 #1 0x00007fffebafd2f7 in ?? () from /usr/local/lib/libavcodec.so.56 #2 0x00007fffeb833ff8 in ?? () from /usr/local/lib/libavcodec.so.56 #3 0x00007fffeb96045f in avcodec_default_execute () from /usr/local/lib/libavcodec.so.56 #4 0x00007fffeb83bdf8 in ?? () from /usr/local/lib/libavcodec.so.56 #5 0x00007fffeb960f90 in avcodec_encode_video2 () from /usr/local/lib/libavcodec.so.56 #6 0x000000000052bbc7 in ffmpegdrv_record (screenshot=0x7fffffffdda0) at ffmpegdrv.c:980 #7 ffmpegdrv_record (screenshot=0x7fffffffdda0) at ffmpegdrv.c:918 #8 0x0000000000468c2d in screenshot_save_core (screenshot=0x7fffffffdda0, drv=0x0, filename=0x0) at screenshot.c:149 #9 0x0000000000468e67 in screenshot_record () at screenshot.c:239 #10 0x00000000004743a8 in machine_vsync_hook () at c64.c:1002 #11 0x0000000000470466 in vsync_do_vsync (c=<optimized out>, been_skipped=0) at vsync.c:369 #12 0x00000000005722f2 in vicii_raster_draw_handler () at vicii.c:457 #13 0x0000000000568216 in vicii_cycle_end_of_line () at vicii-cycle.c:220 #14 vicii_cycle () at vicii-cycle.c:328 #15 0x00000000004794ec in maincpu_mainloop () at ../6510dtvcore.c:1545 #16 0x000000000045f918 in main_program (argc=1, argv=<optimized out>) at main.c:274 #17 0x00007ffff38fe76d in __libc_start_main () from /lib/x86_64-linux-gnu/libc.so.6 #18 0x0000000000447021 in _start ()
Fixed in rev. 30122, please retest.
Yes, fixed with r30164, thx.