Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- swf::matrix SWFStream::readMATRIX(){
- swf::matrix temp = {1, 1, 0, 0, 0, 0};
- alignToNextByte();
- if(readBit()){
- U8 NScaleBits = readBitsUB(5);
- temp.scalex = readBitsFB(NScaleBits);
- temp.scaley = readBitsFB(NScaleBits);
- }
- if(readBit()){
- U8 NRotateBits = readBitsUB(5);
- temp.rotateskewx = readBitsFB(NRotateBits);
- temp.rotateskewy = readBitsFB(NRotateBits);
- }
- U8 NTranslateBits = readBitsUB(5);
- temp.translatex = readBitsSB(NTranslateBits);
- temp.translatey = readBitsSB(NTranslateBits);
- return temp;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement