Browse code

remove ENABLE_SWSCALER conditions patch by Ronald S. Bultje: [rsbultje gmail com]

Originally committed as revision 9435 to svn://svn.ffmpeg.org/ffmpeg/trunk

Ronald S. Bultje authored on 2007/06/27 01:13:44
Showing 1 changed files
... ...
@@ -1610,8 +1610,7 @@ static int av_encode(AVFormatContext **output_files,
1610 1610
                         fprintf(stderr, "Cannot allocate temp picture, check pix fmt\n");
1611 1611
                         exit(1);
1612 1612
                     }
1613
-                    if (ENABLE_SWSCALER)
1614
-                        sws_flags = av_get_int(sws_opts, "sws_flags", NULL);
1613
+                    sws_flags = av_get_int(sws_opts, "sws_flags", NULL);
1615 1614
                     ost->img_resample_ctx = sws_getContext(
1616 1615
                             icodec->width - (frame_leftBand + frame_rightBand),
1617 1616
                             icodec->height - (frame_topBand + frame_bottomBand),
... ...
@@ -3534,7 +3533,7 @@ static int opt_default(const char *opt, const char *arg){
3534 3534
     }
3535 3535
     if(!o)
3536 3536
         o = av_set_string(avformat_opts, opt, arg);
3537
-    if(ENABLE_SWSCALER && !o)
3537
+    if(!o)
3538 3538
         o = av_set_string(sws_opts, opt, arg);
3539 3539
     if(!o){
3540 3540
         if(opt[0] == 'a')
... ...
@@ -3778,8 +3777,7 @@ static void show_help(void)
3778 3778
                       OPT_EXPERT);
3779 3779
     av_opt_show(avctx_opts[0], NULL);
3780 3780
     av_opt_show(avformat_opts, NULL);
3781
-    if (ENABLE_SWSCALER)
3782
-        av_opt_show(sws_opts, NULL);
3781
+    av_opt_show(sws_opts, NULL);
3783 3782
 
3784 3783
     exit(1);
3785 3784
 }
... ...
@@ -3800,8 +3798,7 @@ int main(int argc, char **argv)
3800 3800
         avctx_opts[i]= avcodec_alloc_context2(i);
3801 3801
     }
3802 3802
     avformat_opts = av_alloc_format_context();
3803
-    if (ENABLE_SWSCALER)
3804
-        sws_opts = sws_getContext(16,16,0, 16,16,0, sws_flags, NULL,NULL,NULL);
3803
+    sws_opts = sws_getContext(16,16,0, 16,16,0, sws_flags, NULL,NULL,NULL);
3805 3804
 
3806 3805
     if (argc <= 1)
3807 3806
         show_help();