[x264-devel] Cosmetic changes

Anton Mitrofanov git at videolan.org
Tue Feb 24 20:37:45 CET 2015


x264 | branch: master | Anton Mitrofanov <BugMaster at narod.ru> | Mon Feb 23 14:23:18 2015 +0300| [121396c71b4907ca82301d1a529795d98daab5f8] | committer: Anton Mitrofanov

Cosmetic changes

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=121396c71b4907ca82301d1a529795d98daab5f8
---

 encoder/encoder.c |    4 ++--
 x264.c            |    6 +++---
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/encoder/encoder.c b/encoder/encoder.c
index dffa356..edc387c 100644
--- a/encoder/encoder.c
+++ b/encoder/encoder.c
@@ -474,12 +474,12 @@ static int x264_validate_parameters( x264_t *h, int b_open )
 
     int i_csp = h->param.i_csp & X264_CSP_MASK;
 #if X264_CHROMA_FORMAT
-    if( CHROMA_FORMAT != CHROMA_420 && i_csp >= X264_CSP_I420 && i_csp <= X264_CSP_NV12 )
+    if( CHROMA_FORMAT != CHROMA_420 && i_csp >= X264_CSP_I420 && i_csp < X264_CSP_I422 )
     {
         x264_log( h, X264_LOG_ERROR, "not compiled with 4:2:0 support\n" );
         return -1;
     }
-    else if( CHROMA_FORMAT != CHROMA_422 && i_csp >= X264_CSP_I422 && i_csp <= X264_CSP_V210 )
+    else if( CHROMA_FORMAT != CHROMA_422 && i_csp >= X264_CSP_I422 && i_csp < X264_CSP_I444 )
     {
         x264_log( h, X264_LOG_ERROR, "not compiled with 4:2:2 support\n" );
         return -1;
diff --git a/x264.c b/x264.c
index cc8ace1..4dd2a26 100644
--- a/x264.c
+++ b/x264.c
@@ -1297,11 +1297,11 @@ static int init_vid_filters( char *sequence, hnd_t *handle, video_info_t *info,
     /* force the output csp to what the user specified (or the default) */
     param->i_csp = info->csp;
     int csp = info->csp & X264_CSP_MASK;
-    if( output_csp == X264_CSP_I420 && (csp < X264_CSP_I420 || csp > X264_CSP_NV12) )
+    if( output_csp == X264_CSP_I420 && (csp < X264_CSP_I420 || csp >= X264_CSP_I422) )
         param->i_csp = X264_CSP_I420;
-    else if( output_csp == X264_CSP_I422 && (csp < X264_CSP_I422 || csp > X264_CSP_V210) )
+    else if( output_csp == X264_CSP_I422 && (csp < X264_CSP_I422 || csp >= X264_CSP_I444) )
         param->i_csp = X264_CSP_I422;
-    else if( output_csp == X264_CSP_I444 && (csp < X264_CSP_I444 || csp > X264_CSP_YV24) )
+    else if( output_csp == X264_CSP_I444 && (csp < X264_CSP_I444 || csp >= X264_CSP_BGR) )
         param->i_csp = X264_CSP_I444;
     else if( output_csp == X264_CSP_RGB && (csp < X264_CSP_BGR || csp > X264_CSP_RGB) )
         param->i_csp = X264_CSP_RGB;



More information about the x264-devel mailing list