Loading LrPertColorTexture.cpp +7 −4 Original line number Diff line number Diff line Loading @@ -99,12 +99,15 @@ bool operator != (const LrPertColorTexture &lhs, const LrPertColorTexture &rhs) *---------------------------------------------------------------------------*/ LrColor LrPertColorTexture::getColor(Real u, Real v, LrPoint &point) const { //int numC=1+((m_ImageTexture.getWidth()/2)*(u+1)); //int numL=1+((m_ImageTexture.getHeight()/2)*(v+1)); //u et v compris entre 0 et 1 int numC=1+((int)((m_ImageTexture.getWidth()-1)*u)); int numL=1+((int)((m_ImageTexture.getHeight()-1)*v)); //int numC=1+((int)((m_ImageTexture.getWidth()-1)*u)); //int numL=1+((int)((m_ImageTexture.getHeight()-1)*v)); int numC=1+((int)((m_ImageTexture.getWidth()-1)*(1-u))); int numL=1+((int)((m_ImageTexture.getHeight()-1)*(1-v))); return m_ImageTexture.getPixel(numL,numC); //return LrColor::YELLOW; Loading LrPertColorTwoLayers.cpp +3 −2 Original line number Diff line number Diff line Loading @@ -31,8 +31,9 @@ LrPertColorTwoLayers::LrPertColorTwoLayers( LrPertColor *pertColorHaute, LrPertColorComposed(), m_coef(coef) { m_listPertColors.push_back(pertColorHaute); m_listPertColors.push_back(pertColorBasse); m_listPertColors.push_back(pertColorHaute); } Loading Loading @@ -96,7 +97,7 @@ LrColor LrPertColorTwoLayers::getColor(Real u, Real v, LrPoint &pointInter)const LrPertColorList::const_iterator itB; itH=m_listPertColors.begin(); itB=m_listPertColors.end(); itB=itH++; LrColor CoucheHaute=(*itH)->getColor(u,v, pointInter); LrColor CoucheBasse=(*itB)->getColor(u,v, pointInter); Loading Loading
LrPertColorTexture.cpp +7 −4 Original line number Diff line number Diff line Loading @@ -99,12 +99,15 @@ bool operator != (const LrPertColorTexture &lhs, const LrPertColorTexture &rhs) *---------------------------------------------------------------------------*/ LrColor LrPertColorTexture::getColor(Real u, Real v, LrPoint &point) const { //int numC=1+((m_ImageTexture.getWidth()/2)*(u+1)); //int numL=1+((m_ImageTexture.getHeight()/2)*(v+1)); //u et v compris entre 0 et 1 int numC=1+((int)((m_ImageTexture.getWidth()-1)*u)); int numL=1+((int)((m_ImageTexture.getHeight()-1)*v)); //int numC=1+((int)((m_ImageTexture.getWidth()-1)*u)); //int numL=1+((int)((m_ImageTexture.getHeight()-1)*v)); int numC=1+((int)((m_ImageTexture.getWidth()-1)*(1-u))); int numL=1+((int)((m_ImageTexture.getHeight()-1)*(1-v))); return m_ImageTexture.getPixel(numL,numC); //return LrColor::YELLOW; Loading
LrPertColorTwoLayers.cpp +3 −2 Original line number Diff line number Diff line Loading @@ -31,8 +31,9 @@ LrPertColorTwoLayers::LrPertColorTwoLayers( LrPertColor *pertColorHaute, LrPertColorComposed(), m_coef(coef) { m_listPertColors.push_back(pertColorHaute); m_listPertColors.push_back(pertColorBasse); m_listPertColors.push_back(pertColorHaute); } Loading Loading @@ -96,7 +97,7 @@ LrColor LrPertColorTwoLayers::getColor(Real u, Real v, LrPoint &pointInter)const LrPertColorList::const_iterator itB; itH=m_listPertColors.begin(); itB=m_listPertColors.end(); itB=itH++; LrColor CoucheHaute=(*itH)->getColor(u,v, pointInter); LrColor CoucheBasse=(*itB)->getColor(u,v, pointInter); Loading