]> granicus.if.org Git - libjpeg-turbo/commitdiff
If we have transformed a 4:2:2 or 4:4:0 image in any way that transposes the horizont...
authorDRC <dcommander@users.sourceforge.net>
Thu, 13 Mar 2014 20:33:43 +0000 (20:33 +0000)
committerDRC <dcommander@users.sourceforge.net>
Thu, 13 Mar 2014 20:33:43 +0000 (20:33 +0000)
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1162 632fc199-4ca6-4c93-a231-07263d6284db

tjbench.c

index 707501d7841192cf8c54684aecfac5bd54957c82..4e28f06e80352e0c69b4657168e6ba1146918850 100644 (file)
--- a/tjbench.c
+++ b/tjbench.c
@@ -584,6 +584,13 @@ void decompTest(char *filename)
                        _ntilesw=(_w+_tilew-1)/_tilew;
                        _ntilesh=(_h+_tileh-1)/_tileh;
 
+                       if(xformop==TJXOP_TRANSPOSE || xformop==TJXOP_TRANSVERSE
+                               || xformop==TJXOP_ROT90 || xformop==TJXOP_ROT270)
+                       {
+                               if(_subsamp==TJSAMP_422) _subsamp=TJSAMP_440;
+                               else if(_subsamp==TJSAMP_440) _subsamp=TJSAMP_422;
+                       }
+
                        for(row=0, tile=0; row<_ntilesh; row++)
                        {
                                for(col=0; col<_ntilesw; col++, tile++)