Changeset c0662427d22a4c90a57a051a46a552eaef1f31bf

Show
Ignore:
Timestamp:
03/06/08 12:29:48 (4 months ago)
Author:
Antoine Cellerier <dionoea@videolan.org>
git-committer:
Antoine Cellerier <dionoea@videolan.org> 1212488988 +0200
git-parent:

[1ce62168f30a42924db2535fe8c499e1eae5d2bb]

git-author:
Antoine Cellerier <dionoea@videolan.org> 1212487310 +0200
Message:

Img resample based module (functionality untested ... but compilation and loading works). Remove unneeded stuff from swscale.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • configure.ac

    rebbc287 rc066242  
    30093009      CPPFLAGS="${CPPFLAGS} ${IMGRESAMPLE_CFLAGS}" 
    30103010      CFLAGS="${CFLAGS} ${IMGRESAMPLE_CFLAGS}" 
    3011       LIBS="${CFLAGS} ${IMGRESAMPLE_LIBS}" 
    30123011      AC_CHECK_HEADERS(libavcodec/avcodec.h ffmpeg/avcodec.h) 
    30133012      AC_CHECK_HEADERS(libavutil/avutil.h ffmpeg/avutil.h) 
     
    30233022            AC_MSG_ERROR([swscale (and its fallback module imgresample) support will be missing. Use --disable-swscale to ignore this error. (This basically means that you will be missing any good software scaling module and some video chroma converters.)]) 
    30243023          fi 
    3025         ]
     3024        ],${IMGRESAMPLE_LIBS}
    30263025      VLC_RESTORE_FLAGS 
    30273026    ],[ 
  • modules/codec/ffmpeg/Modules.am

    rebbc287 rc066242  
    3232    swscale.c \ 
    3333    swscale.h \ 
    34     video_filter.c \ 
    35     chroma.c \ 
    3634    scale.c \ 
    3735    $(NULL) 
    3836 
    39 # FIXME 
    4037SOURCES_imgresample = \ 
    41     avcodec.c \ 
    42     avcodec.h \ 
    43     video.c \ 
    44     audio.c \ 
    45     deinterlace.c \ 
     38    imgresample.c \ 
     39    imgresample.h \ 
     40        chroma.c \ 
     41        video_filter.c \ 
    4642    $(NULL) 
    4743 
     
    5450    $(LTLIBavformat) \ 
    5551    $(LTLIBswscale) \ 
     52    $(LTLIBimgresample) \ 
    5653    $(LTLIBpostproc) 
    5754 
     
    6057    libavformat_plugin.la \ 
    6158    libswscale_plugin.la \ 
     59    libimgresample_plugin.la \ 
    6260    libpostproc_plugin.la 
    6361 
  • modules/codec/ffmpeg/chroma.c

    ra519cac rc066242  
    22 * chroma.c: chroma conversion using ffmpeg library 
    33 ***************************************************************************** 
    4  * Copyright (C) 1999-2001 the VideoLAN team 
     4 * Copyright (C) 1999-2008 the VideoLAN team 
    55 * $Id$ 
    66 * 
     
    3232#include <vlc_common.h> 
    3333#include <vlc_vout.h> 
    34  
    35 #if defined(HAVE_LIBSWSCALE_SWSCALE_H)  || defined(HAVE_FFMPEG_SWSCALE_H) 
    3634#include <vlc_filter.h> 
    37 #endif 
    3835 
    3936/* ffmpeg header */ 
     
    4845#include "ffmpeg.h" 
    4946 
    50 #if !defined(HAVE_LIBSWSCALE_SWSCALE_H)  && !defined(HAVE_FFMPEG_SWSCALE_H) 
    51 static void ChromaConversion( vout_thread_t *, picture_t *, picture_t * ); 
     47static void ChromaConversion( filter_t *, picture_t *, picture_t * ); 
     48static picture_t *ChromaConversion_Filter( filter_t *, picture_t * ); 
    5249 
    5350/***************************************************************************** 
     
    8885    } 
    8986 
    90     p_filter->pf_video_filter_io = ChromaConversion
     87    p_filter->pf_video_filter = ChromaConversion_Filter
    9188 
    9289    p_filter->p_sys = malloc( sizeof( filter_sys_t ) ); 
     
    9693    } 
    9794 
    98     p_filter->.p_sys->i_src_vlc_chroma = p_vout->render.i_chroma; 
    99     p_filter->p_sys->i_dst_vlc_chroma = p_vout->output.i_chroma; 
     95    p_filter->p_sys->i_src_vlc_chroma = p_filter->fmt_in.video.i_chroma; 
     96    p_filter->p_sys->i_dst_vlc_chroma = p_filter->fmt_out.video.i_chroma; 
    10097    p_filter->p_sys->i_src_ffmpeg_chroma = i_ffmpeg_chroma[0]; 
    10198    p_filter->p_sys->i_dst_ffmpeg_chroma = i_ffmpeg_chroma[1]; 
     
    126123} 
    127124 
     125VIDEO_FILTER_WRAPPER( ChromaConversion ) 
     126 
    128127/***************************************************************************** 
    129128 * ChromaConversion: actual chroma conversion function 
     
    201200    free( p_filter->p_sys ); 
    202201} 
    203 #endif 
  • modules/codec/ffmpeg/scale.c

    r3561b9b rc066242  
    5252 
    5353/* Version checking */ 
    54 #if ( (defined(HAVE_LIBSWSCALE_SWSCALE_H) || defined(HAVE_FFMPEG_SWSCALE_H)) && (LIBSWSCALE_VERSION_INT >= ((0<<16)+(5<<8)+0))
     54#if LIBSWSCALE_VERSION_INT >= ((0<<16)+(5<<8)+0
    5555 
    5656/***************************************************************************** 
  • modules/codec/ffmpeg/swscale.c

    ra519cac rc066242  
    5050#include "ffmpeg.h" 
    5151 
    52 #ifdef HAVE_POSTPROC_POSTPROCESS_H 
    53 #    include <postproc/postprocess.h> 
    54 #else 
    55 #    include <libpostproc/postprocess.h> 
    56 #endif 
    57  
    58 /***************************************************************************** 
    59  * decoder_sys_t: decoder descriptor 
    60  *****************************************************************************/ 
    61 struct decoder_sys_t 
    62 { 
    63     /* Common part between video and audio decoder */ 
    64     FFMPEG_COMMON_MEMBERS 
    65 }; 
    66  
    6752/**************************************************************************** 
    6853 * Local prototypes 
     
    7964 *****************************************************************************/ 
    8065vlc_module_begin(); 
    81 #if defined(HAVE_LIBSWSCALE_SWSCALE_H)  || defined(HAVE_FFMPEG_SWSCALE_H) 
    82     /* video filter submodule */ 
    8366    set_description( N_("Video scaling filter") ); 
    8467    set_capability( "video filter2", 1000 ); 
     
    8871    add_integer( "swscale-mode", 0, NULL, SCALEMODE_TEXT, SCALEMODE_LONGTEXT, true ); 
    8972        change_integer_list( pi_mode_values, ppsz_mode_descriptions, 0 ); 
    90  
    91 #else 
    92     /* video filter submodule */ 
    93     set_capability( "video filter2", 50 ); 
    94     set_callbacks( OpenFilter, CloseFilter ); 
    95     set_description( N_("FFmpeg video filter") ); 
    96  
    97     /* crop/padd submodule */ 
    98     add_submodule(); 
    99     set_capability( "crop padd", 10 ); 
    100     set_callbacks( OpenCropPadd, CloseFilter ); 
    101     set_description( N_("FFmpeg crop padd filter") ); 
    102  
    103     /* chroma conversion submodule */ 
    104     add_submodule(); 
    105     set_capability( "chroma", 50 ); 
    106     set_callbacks( OpenChroma, CloseChroma ); 
    107     set_description( N_("FFmpeg chroma conversion") ); 
    108 #endif 
    10973vlc_module_end(); 
    11074 
  • modules/codec/ffmpeg/video_filter.c

    ra519cac rc066242  
    4646#include "ffmpeg.h" 
    4747 
    48 #if !defined(HAVE_LIBSWSCALE_SWSCALE_H)  && !defined(HAVE_FFMPEG_SWSCALE_H) 
    4948static int CheckInit( filter_t *p_filter ); 
    5049static picture_t *Process( filter_t *p_filter, picture_t *p_pic ); 
     
    565564    return p_pic_dst; 
    566565} 
    567 #endif /* ( (defined(HAVE_LIBSWSCALE_SWSCALE_H)  || defined(HAVE_FFMPEG_SWSCALE_H) */