Author: stippi Date: 2010-09-14 14:32:04 +0200 (Tue, 14 Sep 2010) New Revision: 38646 Changeset: http://dev.haiku-os.org/changeset/38646 Removed: haiku/trunk/src/add-ons/media/plugins/ogg/ haiku/trunk/src/add-ons/media/plugins/speex/ haiku/trunk/src/add-ons/media/plugins/theora/ haiku/trunk/src/add-ons/media/plugins/vorbis/ Modified: haiku/trunk/build/jam/HaikuImage haiku/trunk/src/add-ons/media/plugins/Jamfile haiku/trunk/src/add-ons/media/plugins/ffmpeg/AVFormatReader.cpp haiku/trunk/src/add-ons/media/plugins/ffmpeg/CodecTable.cpp haiku/trunk/src/add-ons/media/plugins/ffmpeg/DemuxerTable.cpp haiku/trunk/src/add-ons/media/plugins/ffmpeg/Jamfile haiku/trunk/src/add-ons/media/plugins/ffmpeg/config.h haiku/trunk/src/add-ons/media/plugins/ffmpeg/libavcodec/Jamfile Log: Removed the "native" ogg, vorbis, theora and speex plugins in favor of support for these codecs and demuxer in the FFmpeg plugin. The ogg test streams I downloaded play fine now. For example, Big Buck Bunny would play without video before and ogg files natively encoded with the FFmpeg plugin wouldn't play at all. Since the removed plugins were not maintained and were based on external libs themselves, I didn't see the point in keeping them. Modified: haiku/trunk/build/jam/HaikuImage =================================================================== --- haiku/trunk/build/jam/HaikuImage 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/build/jam/HaikuImage 2010-09-14 12:32:04 UTC (rev 38646) @@ -141,10 +141,8 @@ ; SYSTEM_ADD_ONS_MEDIA_PLUGINS = $(GPL_ONLY)ac3_decoder aiff_reader asf_reader au_reader $(X86_ONLY)ffmpeg - mov_reader musepack ogg raw_decoder speex - $(X86_ONLY)ape_reader - # theora - vorbis wav_reader + mov_reader musepack raw_decoder $(X86_ONLY)ape_reader + wav_reader ; SYSTEM_ADD_ONS_PRINT = Canon\ LIPS3\ Compatible Canon\ LIPS4\ Compatible PCL5\ Compatible PCL6\ Compatible PDF\ Writer PS\ Compatible Preview Modified: haiku/trunk/src/add-ons/media/plugins/Jamfile =================================================================== --- haiku/trunk/src/add-ons/media/plugins/Jamfile 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/Jamfile 2010-09-14 12:32:04 UTC (rev 38646) @@ -12,11 +12,7 @@ SubInclude HAIKU_TOP src add-ons media plugins mov_reader ; SubInclude HAIKU_TOP src add-ons media plugins mp4_reader ; SubInclude HAIKU_TOP src add-ons media plugins musepack ; -SubInclude HAIKU_TOP src add-ons media plugins ogg ; SubInclude HAIKU_TOP src add-ons media plugins raw_decoder ; -SubInclude HAIKU_TOP src add-ons media plugins speex ; -#SubInclude HAIKU_TOP src add-ons media plugins theora ; -SubInclude HAIKU_TOP src add-ons media plugins vorbis ; SubInclude HAIKU_TOP src add-ons media plugins wav_reader ; # The following add-ons are GPL licensed, and can only be used with Modified: haiku/trunk/src/add-ons/media/plugins/ffmpeg/AVFormatReader.cpp =================================================================== --- haiku/trunk/src/add-ons/media/plugins/ffmpeg/AVFormatReader.cpp 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/ffmpeg/AVFormatReader.cpp 2010-09-14 12:32:04 UTC (rev 38646) @@ -446,6 +446,31 @@ description.family = B_WAV_FORMAT_FAMILY; codecTag = ' DTS'; break; + case CODEC_ID_THEORA: + // Use the same format description as the native Ogg + // reader and decoder did. + description.family = B_MISC_FORMAT_FAMILY; +// TODO: The rest of this plugin (Decoders/Encoders) does not support +// this yet, specifying it would throw off the format matching. +// description.u.misc.file_format = 'OggS'; + codecTag = 'theo'; + break; + case CODEC_ID_SPEEX: + // Use the same format description as the native Ogg + // reader and decoder did. + description.family = B_MISC_FORMAT_FAMILY; +// TODO: See above. +// description.u.misc.file_format = 'OggS'; + codecTag = 'spex'; + break; + case CODEC_ID_VORBIS: + // Use the same format description as the native Ogg + // reader and decoder did. + description.family = B_MISC_FORMAT_FAMILY; +// TODO: See above. +// description.u.misc.file_format = 'OggS'; + codecTag = 'vorb'; + break; default: fprintf(stderr, "ffmpeg codecTag is null, codec_id " "unknown 0x%x\n", codecContext->codec_id); @@ -627,6 +652,8 @@ = codecContext->width; format->u.encoded_video.output.display.line_count = codecContext->height; + TRACE(" width/height: %d/%d\n", codecContext->width, + codecContext->height); format->u.encoded_video.output.display.bytes_per_row = 0; format->u.encoded_video.output.display.pixel_offset = 0; format->u.encoded_video.output.display.line_offset = 0; @@ -647,10 +674,10 @@ } TRACE(" extradata_size: %d\n", codecContext->extradata_size); - TRACE(" intra_matrix: %p\n", codecContext->intra_matrix); - TRACE(" inter_matrix: %p\n", codecContext->inter_matrix); - TRACE(" get_buffer(): %p\n", codecContext->get_buffer); - TRACE(" release_buffer(): %p\n", codecContext->release_buffer); +// TRACE(" intra_matrix: %p\n", codecContext->intra_matrix); +// TRACE(" inter_matrix: %p\n", codecContext->inter_matrix); +// TRACE(" get_buffer(): %p\n", codecContext->get_buffer); +// TRACE(" release_buffer(): %p\n", codecContext->release_buffer); #ifdef TRACE_AVFORMAT_READER char formatString[512]; Modified: haiku/trunk/src/add-ons/media/plugins/ffmpeg/CodecTable.cpp =================================================================== --- haiku/trunk/src/add-ons/media/plugins/ffmpeg/CodecTable.cpp 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/ffmpeg/CodecTable.cpp 2010-09-14 12:32:04 UTC (rev 38646) @@ -214,6 +214,10 @@ {CODEC_ID_INDEO3, B_MEDIA_ENCODED_VIDEO, B_AVI_FORMAT_FAMILY, FOURCC('IV31'), "Indeo 3"}, {CODEC_ID_INDEO3, B_MEDIA_ENCODED_VIDEO, B_AVI_FORMAT_FAMILY, FOURCC('IV32'), "Indeo 3"}, + {CODEC_ID_THEORA, B_MEDIA_ENCODED_VIDEO, B_MISC_FORMAT_FAMILY, 'theo', "Theora"}, + {CODEC_ID_VORBIS, B_MEDIA_ENCODED_AUDIO, B_MISC_FORMAT_FAMILY, 'vorb', "Vorbis"}, + {CODEC_ID_SPEEX, B_MEDIA_ENCODED_AUDIO, B_MISC_FORMAT_FAMILY, 'spex', "Speex"}, + {CODEC_ID_VP3, B_MEDIA_ENCODED_VIDEO, B_QUICKTIME_FORMAT_FAMILY, 'VP31', "On2 VP3"}, {CODEC_ID_VP6F, B_MEDIA_ENCODED_VIDEO, B_QUICKTIME_FORMAT_FAMILY, 'VP6F', "On2 VP6"}, Modified: haiku/trunk/src/add-ons/media/plugins/ffmpeg/DemuxerTable.cpp =================================================================== --- haiku/trunk/src/add-ons/media/plugins/ffmpeg/DemuxerTable.cpp 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/ffmpeg/DemuxerTable.cpp 2010-09-14 12:32:04 UTC (rev 38646) @@ -85,6 +85,13 @@ B_QUICKTIME_FORMAT_FAMILY, B_QUICKTIME_FORMAT_FAMILY }, { + // Works fine, expect for seeking in clips generated by + // native software when the video and audio stream are + // not interleaved. + "ogg", "Ogg", "video/ogg", + B_MISC_FORMAT_FAMILY, B_MISC_FORMAT_FAMILY + }, + { // TODO: untested! "rm", "RM (RealVideo Clip)", "video/vnd.rn-realvideo", B_WAV_FORMAT_FAMILY, B_AVI_FORMAT_FAMILY Modified: haiku/trunk/src/add-ons/media/plugins/ffmpeg/Jamfile =================================================================== --- haiku/trunk/src/add-ons/media/plugins/ffmpeg/Jamfile 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/ffmpeg/Jamfile 2010-09-14 12:32:04 UTC (rev 38646) @@ -34,6 +34,7 @@ libswscale.a libvorbis_ffmpeg.a + libspeex_ffmpeg.a libtheora_ffmpeg.a libogg_ffmpeg.a @@ -109,5 +110,6 @@ SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libavutil ; SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libogg ; SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libswscale ; +SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libspeex ; SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libtheora ; SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libvorbis ; Modified: haiku/trunk/src/add-ons/media/plugins/ffmpeg/config.h =================================================================== --- haiku/trunk/src/add-ons/media/plugins/ffmpeg/config.h 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/ffmpeg/config.h 2010-09-14 12:32:04 UTC (rev 38646) @@ -195,7 +195,7 @@ #define CONFIG_LIBOPENJPEG 0 #define CONFIG_LIBRTMP 0 #define CONFIG_LIBSCHROEDINGER 0 -#define CONFIG_LIBSPEEX 0 +#define CONFIG_LIBSPEEX 1 #define CONFIG_LIBTHEORA 1 #define CONFIG_LIBVORBIS 1 #define CONFIG_LIBVPX 0 @@ -487,7 +487,7 @@ #define CONFIG_LIBOPENCORE_AMRWB_DECODER 0 #define CONFIG_LIBOPENJPEG_DECODER 0 #define CONFIG_LIBSCHROEDINGER_DECODER 0 -#define CONFIG_LIBSPEEX_DECODER 0 +#define CONFIG_LIBSPEEX_DECODER 1 #define CONFIG_LIBVPX_DECODER 0 #define CONFIG_ASV1_ENCODER 0 #define CONFIG_ASV2_ENCODER 0 Modified: haiku/trunk/src/add-ons/media/plugins/ffmpeg/libavcodec/Jamfile =================================================================== --- haiku/trunk/src/add-ons/media/plugins/ffmpeg/libavcodec/Jamfile 2010-09-14 12:24:09 UTC (rev 38645) +++ haiku/trunk/src/add-ons/media/plugins/ffmpeg/libavcodec/Jamfile 2010-09-14 12:32:04 UTC (rev 38646) @@ -7,6 +7,7 @@ SubDirSysHdrs [ FDirName $(SUBDIR) .. libogg include ] ; SubDirSysHdrs [ FDirName $(SUBDIR) .. libtheora include ] ; SubDirSysHdrs [ FDirName $(SUBDIR) .. libvorbis include ] ; +SubDirSysHdrs [ FDirName $(SUBDIR) .. libspeex include ] ; UseLibraryHeaders zlib ; @@ -188,6 +189,7 @@ kmvc.c lcldec.c # lclenc.c + libspeexdec.c libtheoraenc.c libvorbis.c # ljpegenc.c @@ -373,6 +375,7 @@ # per individual file. SourceHdrs libvorbis.c : [ FDirName $(SUBDIR) .. libvorbis include vorbis ] ; SourceHdrs libtheoraenc.c : [ FDirName $(SUBDIR) .. libtheora include theora ] ; +SourceHdrs libspeexdec.c : [ FDirName $(SUBDIR) .. libspeex include speex ] ; SubInclude HAIKU_TOP src add-ons media plugins ffmpeg libavcodec $(TARGET_ARCH) ;