+
+ float inwf, inhf;
+ Point itl, ibr;
+
+ if (trimmed)
+ {
+ inwf = (br[0] - tl[0])*surface.get_w()/width;
+ inhf = (br[1] - tl[1])*surface.get_h()/height;
+ itl = Point(tl[0] + (br[0]-tl[0])*left/width,
+ tl[1] + (br[1]-tl[1])*top/height);
+ ibr = Point(tl[0] + (br[0]-tl[0])*(left+inw)/width,
+ tl[1] + (br[1]-tl[1])*(top+inh)/height);
+ }
+ else
+ {
+ inwf = br[0] - tl[0];
+ inhf = br[1] - tl[1];
+ itl = tl;
+ ibr = br;
+ }
+