X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FOCCViewer%2FOCCViewer_Utilities.cxx;h=4705a35f177c3f1afcc74234e9085598da8fe7eb;hb=a9825bb7bbf67a1d49e832d9db3f4a2d75fa4c35;hp=0330f328afe1fe5f0f5fe4c366d423a507cdbfbb;hpb=d5890a2bbd3eebf1e256c6a86ee1ff854b46711b;p=modules%2Fgui.git diff --git a/src/OCCViewer/OCCViewer_Utilities.cxx b/src/OCCViewer/OCCViewer_Utilities.cxx index 0330f328a..4705a35f1 100755 --- a/src/OCCViewer/OCCViewer_Utilities.cxx +++ b/src/OCCViewer/OCCViewer_Utilities.cxx @@ -27,15 +27,9 @@ #include "QtxActionToolMgr.h" #include "QtxMultiAction.h" -// KERNEL includes -#include - // OCC includes #include #include -#if OCC_VERSION_LARGE < 0x07000000 -#include -#endif // QT includes #include @@ -52,7 +46,6 @@ Handle(Image_PixMap) OCCViewer_Utilities::imageToPixmap( const QImage& anImage ) const uchar* aImageBytes = anImage.bits(); for ( int aLine = anImage.height() - 1; aLine >= 0; --aLine ) { -#if OCC_VERSION_LARGE > 0x06070100 // convert pixels from ARGB to renderer-compatible RGBA for ( int aByte = 0; aByte < anImage.width(); ++aByte ) { Image_ColorBGRA& aPixmapBytes = aPixmap->ChangeValue(aLine, aByte); @@ -62,18 +55,6 @@ Handle(Image_PixMap) OCCViewer_Utilities::imageToPixmap( const QImage& anImage ) aPixmapBytes.r() = (Standard_Byte) *aImageBytes++; aPixmapBytes.a() = (Standard_Byte) *aImageBytes++; } -#else - Image_ColorBGRA* aPixmapBytes = aPixmap->EditData().ChangeRow(aLine); - - // convert pixels from ARGB to renderer-compatible RGBA - for ( int aByte = 0; aByte < anImage.width(); ++aByte ) { - aPixmapBytes->b() = (Standard_Byte) *aImageBytes++; - aPixmapBytes->g() = (Standard_Byte) *aImageBytes++; - aPixmapBytes->r() = (Standard_Byte) *aImageBytes++; - aPixmapBytes->a() = (Standard_Byte) *aImageBytes++; - aPixmapBytes++; - } -#endif } } return aPixmap; @@ -173,7 +154,6 @@ bool OCCViewer_Utilities::computeVisibleBounds( const Handle(V3d_View) theView, aStructure->IsInfinite() || aStructure->CStructure()->IsForHighlight ) continue; double aBounds[6]; -#if OCC_VERSION_LARGE > 0x06070100 Bnd_Box aBox = aStructure->MinMaxValues(); aBounds[0] = aBox.IsVoid() ? RealFirst() : aBox.CornerMin().X(); aBounds[2] = aBox.IsVoid() ? RealFirst() : aBox.CornerMin().Y(); @@ -181,10 +161,6 @@ bool OCCViewer_Utilities::computeVisibleBounds( const Handle(V3d_View) theView, aBounds[1] = aBox.IsVoid() ? RealLast() : aBox.CornerMax().X(); aBounds[3] = aBox.IsVoid() ? RealLast() : aBox.CornerMax().Y(); aBounds[5] = aBox.IsVoid() ? RealLast() : aBox.CornerMax().Z(); -#else - aStructure->MinMaxValues( aBounds[0], aBounds[2], aBounds[4], - aBounds[1], aBounds[3], aBounds[5] ); -#endif if ( aBounds[0] > -DBL_MAX && aBounds[1] < DBL_MAX && aBounds[2] > -DBL_MAX && aBounds[3] < DBL_MAX &&