mirror of
https://github.com/brl/mutter.git
synced 2025-06-14 01:09:30 +00:00
cogl-material: Add support for point sprites
This adds a new API call to enable point sprite coordinate generation for a material layer: void cogl_material_set_layer_point_sprite_coords_enabled (CoglHandle material, int layer_index, gboolean enable); There is also a corresponding get function. Enabling point sprite coords simply sets the GL_COORD_REPLACE of the GL_POINT_SPRITE glTexEnv when flusing the material. There is no separate application control for glEnable(GL_POINT_SPRITE). Instead it is left permanently enabled under the assumption that it has no affect unless GL_COORD_REPLACE is enabled for a texture unit. http://bugzilla.openedhand.com/show_bug.cgi?id=2047
This commit is contained in:

committed by
Robert Bragg

parent
06b58baa10
commit
da3be3df6b
@ -248,6 +248,8 @@ typedef enum { /*< prefix=COGL_PIXEL_FORMAT >*/
|
||||
* @COGL_FEATURE_TEXTURE_NPOT_REPEAT: Repeat modes other than
|
||||
* %COGL_MATERIAL_WRAP_MODE_CLAMP_TO_EDGE are supported by the
|
||||
* hardware.
|
||||
* @COGL_FEATURE_POINT_SPRITE: Whether
|
||||
* cogl_material_set_layer_point_sprite_coords_enabled() is supported.
|
||||
*
|
||||
* Flags for the supported features.
|
||||
*
|
||||
@ -271,7 +273,8 @@ typedef enum
|
||||
COGL_FEATURE_DEPTH_RANGE = (1 << 14),
|
||||
COGL_FEATURE_TEXTURE_NPOT_BASIC = (1 << 15),
|
||||
COGL_FEATURE_TEXTURE_NPOT_MIPMAP = (1 << 16),
|
||||
COGL_FEATURE_TEXTURE_NPOT_REPEAT = (1 << 17)
|
||||
COGL_FEATURE_TEXTURE_NPOT_REPEAT = (1 << 17),
|
||||
COGL_FEATURE_POINT_SPRITE = (1 << 18)
|
||||
} CoglFeatureFlags;
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user