Commit Graph

15 Commits

Author SHA1 Message Date
Emmanuele Bassi
8afb499ce5 image: Do not put large textures in the atlas
Atlasing is fine for smaller textures, but once they get too large its
downsides outweight the benefits. At worst, the larger texture will end
up inside its own atlas, but at worst it will require copying and/or
resizing of an existing atlas.

The cut-off at 512x512 pixels is a bit arbitrary, and we can change it
at any point; it would be nice if we could get the texture limit from
Cogl, and then use a fraction of that size as the cut-off limit. Sadly,
that's not portable, and it's not guaranteed to work either.
2014-12-03 12:12:43 +00:00
Emmanuele Bassi
0255b5a133 docs: Add an explicit example of image loading
Using GdkPixbuf, which is what we expect people to use anyway.
2014-04-26 20:50:43 +01:00
Emmanuele Bassi
10ff9a4679 docs: Fix the ClutterImage example URL 2014-04-26 20:50:29 +01:00
Emmanuele Bassi
12370bd4f8 docs: Move to markdown
We're removing docbook tags in favour of the markdown syntax.
2014-03-17 23:07:58 +00:00
Emmanuele Bassi
32ccff8525 image: Do not premultiply the blend color
ClutterTextureNode will do that for us when converting the ClutterColor
to a CoglColor, so we can simply pass a white color with the correct
alpha channel.
2013-10-10 13:40:42 +01:00
Emmanuele Bassi
41bb03da2d Use the new macros for adding private data 2013-07-03 18:04:32 +01:00
Emmanuele Bassi
92fc2c760c image: Use the actor's content repeat policy
When painting we can now use the ClutterActor content-repeat property to
decide whether or not to repeat the texture data.
2012-06-08 14:33:00 +01:00
Emmanuele Bassi
65c8b11604 image: Add a data setter using GBytes
The plain C bytes array, while convenient from a C perspective, is not
well handled by language bindings: the length of the array is not
specified, and it's only just implied by the image data size, rowstride,
and pixel format.

GBytes is a read-only bytes buffer that has an implicit length; we can
use it as the storage medium so that language bindings can actually
function correctly.
2012-06-04 10:34:22 +01:00
Emmanuele Bassi
07c95ebf0c Move examples from tests/interactive to a new top-level
The example code that is meant to be XIncluded into the API reference
should not be part of the interactive test suite: it's code that it is
meant to be used as a reference implementation - whereas the interactive
test suite should be allowed to be lean and test behaviour even in nasty
ways. In short: the test suite should not be the place where we show off
idiomatic code for educational purposes.
2012-05-01 19:00:35 +01:00
Emmanuele Bassi
74f5bbe5aa docs: Fixes for ClutterImage's API reference 2012-03-16 12:33:39 +00:00
Emmanuele Bassi
75e6560160 image: Add set_area() method
This method allows replacing an area inside the texture data used by a
ClutterImage.
2012-03-16 12:33:39 +00:00
Emmanuele Bassi
2be850f441 image: Add get_texture()
Allow retrieving the Cogl texture used by the ClutterImage.
2012-03-16 12:33:39 +00:00
Emmanuele Bassi
b6403b01a1 Documentation fixes 2012-03-16 12:33:38 +00:00
Emmanuele Bassi
fb106ece05 Use the content scaling filters
Both ClutterCanvas and ClutterImage should use the minification and
magnification filters set on the actor, just like the use the content
box and the paint opacity.
2012-03-16 12:33:38 +00:00
Emmanuele Bassi
cadae5b325 Add ClutterImage, and image data content 2012-03-16 12:33:37 +00:00