uiacceltk/hitchcock/coretoolkit/src/HuiFxVisualLayer.cpp
branchRCL_3
changeset 7 433cbbb6a04b
parent 0 15bf7259bb7c
child 11 46927d61fef3
child 19 f5bac0badc7e
equal deleted inserted replaced
3:d8a3531bc6b8 7:433cbbb6a04b
   298     // Therefore the order of the transformations matters.
   298     // Therefore the order of the transformations matters.
   299     // In order to prevent the scaling ang skewing from affecting the translation,
   299     // In order to prevent the scaling ang skewing from affecting the translation,
   300     // if seems wiser to do the translation first, otherwise the results seem to be unpredictable.
   300     // if seems wiser to do the translation first, otherwise the results seem to be unpredictable.
   301     
   301     
   302     // Translation
   302     // Translation
   303     if (iTranslationX != 0.0f || iTranslationY != 0.0f || iTranslationZ != 0.0f)
   303 	TReal32 translationX = 0.0f;
   304         {
   304 	TReal32 translationY = 0.0f;
   305         aGc.Translate(EHuiGcMatrixModel, iTranslationX, iTranslationY, iTranslationZ);
   305 	TReal32 translationZ = 0.0f;
       
   306 
       
   307     if (iTranslationX != 0.0f)
       
   308 		{
       
   309 		translationX = iTranslationX - iVisual->EffectDisplayRect().iTl.iX;
       
   310 		}
       
   311 	if (iTranslationY != 0.0f)
       
   312         {
       
   313         translationY = iTranslationY - iVisual->EffectDisplayRect().iTl.iY;
   306         }    
   314         }    
       
   315 
       
   316 	if (iTranslationZ != 0.0f)
       
   317         {
       
   318 		// Z translation not supported by the model
       
   319         translationZ = iTranslationZ;
       
   320         }    
       
   321 
       
   322 	  if (translationX != 0.0f || translationY != 0.0f || translationZ != 0.0f)
       
   323 	  	{
       
   324         aGc.Translate(EHuiGcMatrixModel, translationX, translationY, translationZ);
       
   325 		}
   307         
   326         
   308     // Scaling
   327     // Scaling
   309     if (iScaleX != 1.0f || iScaleY != 1.0f || iScaleZ != 1.0f)
   328     if (iScaleX != 1.0f || iScaleY != 1.0f || iScaleZ != 1.0f)
   310         {
   329         {
   311         if ( iScaleOriginX != 0 || iScaleOriginY != 0 || iScaleOriginZ != 0 )
   330         if ( iScaleOriginX != 0 || iScaleOriginY != 0 || iScaleOriginZ != 0 )