Advertisement
Guest User

Untitled

a guest
May 13th, 2013
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.67 KB | None | 0 0
  1. swf::matrix SWFStream::readMATRIX(){
  2.         swf::matrix temp = {1, 1, 0, 0, 0, 0};
  3.         alignToNextByte();
  4.  
  5.         if(readBit()){
  6.             U8 NScaleBits = readBitsUB(5);
  7.  
  8.             temp.scalex = readBitsFB(NScaleBits);
  9.             temp.scaley = readBitsFB(NScaleBits);
  10.         }
  11.  
  12.         if(readBit()){
  13.             U8 NRotateBits = readBitsUB(5);
  14.  
  15.             temp.rotateskewx = readBitsFB(NRotateBits);
  16.             temp.rotateskewy = readBitsFB(NRotateBits);
  17.         }
  18.  
  19.  
  20.         U8 NTranslateBits = readBitsUB(5);
  21.  
  22.         temp.translatex = readBitsSB(NTranslateBits);
  23.         temp.translatey = readBitsSB(NTranslateBits);
  24.  
  25.         return temp;
  26.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement