After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 661887 - auto-resize of ClutterCairoTexture does not work correctly
auto-resize of ClutterCairoTexture does not work correctly
Status: RESOLVED FIXED
Product: clutter
Classification: Platform
Component: ClutterTexture
unspecified
Other Linux
: Normal normal
: ---
Assigned To: clutter-maint
clutter-maint
Depends on:
Blocks:
 
 
Reported: 2011-10-16 04:20 UTC by Peng Huang
Modified: 2011-10-31 11:07 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
cairo-texture: Drop the half pixel rounding (1.03 KB, patch)
2011-10-24 11:00 UTC, Emmanuele Bassi (:ebassi)
committed Details | Review

Description Peng Huang 2011-10-16 04:20:20 UTC
auto-resize of ClutterCairoTexture does not work correctly. I assign actor's size to 400x400, but cairo surface size will be resized to 401x401. I think it should be 400x400 too.
Comment 1 Emmanuele Bassi (:ebassi) 2011-10-24 10:59:37 UTC
the surface size is rounded up to the nearest pixel, as Clutter uses floating point values for its dimensional and positional attributes. we don't use the C conversion rules, as they might lead to smaller surfaces - so we use ceilf() instead. I'm going to attach a patch that drops an half-pixel rounding which should be enough to fix this.
Comment 2 Emmanuele Bassi (:ebassi) 2011-10-24 11:00:12 UTC
Created attachment 199809 [details] [review]
cairo-texture: Drop the half pixel rounding

Calling ceilf() should be enough.
Comment 3 Emmanuele Bassi (:ebassi) 2011-10-31 11:07:12 UTC
Attachment 199809 [details] pushed to master.