svgtopt/nvgdecoder/src/TLVRenderer.cpp
changeset 1 bfff372fb1f4
parent 0 d46562c3d99d
child 17 443d52b01c62
equal deleted inserted replaced
0:d46562c3d99d 1:bfff372fb1f4
   763     width  = iNVGIconData->ReadReal32L();
   763     width  = iNVGIconData->ReadReal32L();
   764     height = iNVGIconData->ReadReal32L();
   764     height = iNVGIconData->ReadReal32L();
   765 
   765 
   766     if (!iScaled)
   766     if (!iScaled)
   767         {
   767         {
   768         VGfloat scaleX = iTargetWidth  / width;
   768         VGfloat scaleX = ((VGfloat)iTargetWidth)  / width;
   769         VGfloat scaleY = iTargetHeight / height;
   769         VGfloat scaleY = ((VGfloat)iTargetHeight) / height;
   770         vgLoadMatrix(iUserMatrix);
   770         vgLoadMatrix(iUserMatrix);
   771         vgTranslate(iTargetWidth / 2, iTargetHeight / 2);
   771         vgTranslate(((VGfloat)iTargetWidth) / 2, ((VGfloat)iTargetHeight) / 2);
   772         vgScale(scaleX, scaleY);
   772         vgScale(scaleX, scaleY);
   773         vgTranslate(- width / 2, - height / 2);
   773         vgTranslate(- width / 2, - height / 2);
   774 
   774 
   775         vgGetMatrix(iUserMatrix);
   775         vgGetMatrix(iUserMatrix);
   776         iScaled = ETrue;
   776         iScaled = ETrue;