diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-13 08:32:36 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-13 08:32:36 +0000 |
commit | f7e71d47719ab6094cf4a9fafffa5ea351973522 (patch) | |
tree | 30834aa632d442019e14f88685001d94657d060b /kimgio/jp2.cpp | |
parent | b31cfd9a1ee986fe2ae9a693f3afd7f171dd897c (diff) | |
download | tdelibs-f7e71d47719ab6094cf4a9fafffa5ea351973522.tar.gz tdelibs-f7e71d47719ab6094cf4a9fafffa5ea351973522.zip |
Initial conversion for TQt for Qt4 3.4.0 TP2
This will also compile with TQt for Qt3, and should not cause any problems
with dependent modules such as kdebase. If it does then it needs to be fixed!
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1214149 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kimgio/jp2.cpp')
-rw-r--r-- | kimgio/jp2.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/kimgio/jp2.cpp b/kimgio/jp2.cpp index 71b260375..ed5ef99c3 100644 --- a/kimgio/jp2.cpp +++ b/kimgio/jp2.cpp @@ -60,7 +60,7 @@ read_image( const TQImageIO* io ) TQFile* out = tempf->file(); // 4096 (=4k) is a common page size. TQByteArray b( 4096 ); - Q_LONG size; + TQ_LONG size; // 0 or -1 is EOF / error while( ( size = io->ioDevice()->readBlock( b.data(), 4096 ) ) > 0 ) { // in case of a write error, still give the decoder a try @@ -139,7 +139,7 @@ render_view( gs_t& gs, TQImage& qti ) else if( v[k] > 255 ) v[k] = 255; } // for k - *data++ = qRgb( v[0], v[1], v[2] ); + *data++ = tqRgb( v[0], v[1], v[2] ); } // for x } // for y return true; @@ -163,7 +163,7 @@ kimgio_jp2_read( TQImageIO* io ) if( gs.altimage ) jas_image_destroy( gs.altimage ); io->setImage( image ); - io->setStatus( 0 ); + io->setqStatus( 0 ); } // kimgio_jp2_read @@ -211,19 +211,19 @@ write_components( jas_image_t* ji, const TQImage& qi ) jas_image_setcmpttype( ji, 0, JAS_IMAGE_CT_RGB_R ); for( uint y = 0; y < height; ++y ) for( uint x = 0; x < width; ++x ) - jas_matrix_set( m, y, x, qRed( qi.pixel( x, y ) ) ); + jas_matrix_set( m, y, x, tqRed( qi.pixel( x, y ) ) ); jas_image_writecmpt( ji, 0, 0, 0, width, height, m ); jas_image_setcmpttype( ji, 1, JAS_IMAGE_CT_RGB_G ); for( uint y = 0; y < height; ++y ) for( uint x = 0; x < width; ++x ) - jas_matrix_set( m, y, x, qGreen( qi.pixel( x, y ) ) ); + jas_matrix_set( m, y, x, tqGreen( qi.pixel( x, y ) ) ); jas_image_writecmpt( ji, 1, 0, 0, width, height, m ); jas_image_setcmpttype( ji, 2, JAS_IMAGE_CT_RGB_B ); for( uint y = 0; y < height; ++y ) for( uint x = 0; x < width; ++x ) - jas_matrix_set( m, y, x, qBlue( qi.pixel( x, y ) ) ); + jas_matrix_set( m, y, x, tqBlue( qi.pixel( x, y ) ) ); jas_image_writecmpt( ji, 2, 0, 0, width, height, m ); jas_matrix_destroy( m ); @@ -288,7 +288,7 @@ kimgio_jp2_write( TQImageIO* io ) TQFile* in = ktempf->file(); TQByteArray b( 4096 ); - Q_LONG size; + TQ_LONG size; // seek to the beginning of the file. if( !in->at( 0 ) ) { delete ktempf; return; } @@ -309,7 +309,7 @@ kimgio_jp2_write( TQImageIO* io ) // everything went fine - io->setStatus( IO_Ok ); + io->setqStatus( IO_Ok ); } // kimgio_jp2_write #endif // HAVE_JASPER |