Yeah, found it. I’ll get right on it as soon as my machine has finished rebooting (my entire machine froze, so I think I beat your app crashes :-) ).
From: FDnC Red <fdnc...@yahoo.com<mailto:fdnc...@yahoo.com>> Reply-To: FDnC Red <fdnc...@yahoo.com<mailto:fdnc...@yahoo.com>>, Post all your questions about iText here <itext-questions@lists.sourceforge.net<mailto:itext-questions@lists.sourceforge.net>> Date: Thursday, 18 September 2014 14:35 To: "itext-questions@lists.sourceforge.net<mailto:itext-questions@lists.sourceforge.net>" <itext-questions@lists.sourceforge.net<mailto:itext-questions@lists.sourceforge.net>> Subject: [iText-questions] CTM + re Two questions. 1) Am I transforming this rectangle by the matrix correctly? 2) Is there an easier way? The Content Stream q 1.1342565 0 0 1.199793 0 0 cm 41.906 201.086 0.936 -69.448 re f Q float rectXPt = ((PdfNumber)operands[0]).FloatValue; //41.906 float rectYPt = ((PdfNumber)operands[1]).FloatValue; //201.086 float rectWidthPt = ((PdfNumber)operands[2]).FloatValue; //0.936 float rectHeightPt = ((PdfNumber)operands[3]).FloatValue; //-69.48 //Translate based on transformation matrix //x1 = a * x + c * y + e //y1 = b * x + d * y + f //a = 1.1342565 //b = 0 //c = 0 //d = 1.199793 //e = 0 //f = 0 float transStartXPt = m[0] * rectXPt + m[3] * rectYPt + m[6]; float transStartYPt = m[1] * rectXPt + m[4] * rectYPt + m[7]; float tempEndXPt = rectXPt + rectAbsWidthPt; float tempEndYPt = rectYPt + rectAbsHeightPt; float transEndXPt = m[0] * tempEndXPt + m[3] * tempEndYPt + m[6];; float transEndYPt = m[1] * tempEndXPt + m[4] * tempEndYPt + m[7]; Thanks, Darren ------------------------------------------------------------------------------ Want excitement? Manually upgrade your production database. When you want reliability, choose Perforce Perforce version control. Predictably reliable. http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions iText(R) is a registered trademark of 1T3XT BVBA. Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/ Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php