Robert Bragg ae57c30e93 [texture] fix rounding when calculating update_fbo viewport offset
When rendering to an fbo for supporting clutter_texture_new_from_actor we
render to an fbo with the same size as the source actor, but with a viewport
the same size as the stage.  We offset the viewport so when we render the
source actor in its normal transformed stage position it lands on the fbo.
Previously we were rounding the transformed position given as a float by
truncating the fraction (just using a C cast) but that resulted in an
incorrect pixel offset when rendering offscreen depending on the source
position.

We now simply + 0.5 before casting (or -0.5 for negative numbers)
2009-11-04 03:34:07 +00:00
..
2009-10-14 11:31:26 +01:00
2009-10-14 11:31:26 +01:00
2009-07-10 11:38:42 +01:00
2009-07-10 11:38:42 +01:00
2009-10-19 12:01:38 +01:00
2009-10-14 11:31:26 +01:00
2009-10-16 15:55:05 +01:00
2009-10-19 11:45:15 +01:00