mirror of
https://github.com/brl/mutter.git
synced 2024-11-23 00:20:42 -05:00
material: Adds _cogl_material_pre_paint_for_layer
This is a counter part for _cogl_material_layer_pre_paint which takes a layer index instead of a direct CoglMaterialLayer pointer. The aim is to phase out code that directly iterates the internal layer pointers of a material since the layer pointers can change if any property of any layer is changed making direct layer pointers very fragile.
This commit is contained in:
parent
701a693661
commit
94e0619785
@ -606,6 +606,15 @@ _cogl_material_layer_has_user_matrix (CoglMaterialLayer *layer);
|
|||||||
void
|
void
|
||||||
_cogl_material_layer_pre_paint (CoglMaterialLayer *layerr);
|
_cogl_material_layer_pre_paint (CoglMaterialLayer *layerr);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Calls the pre_paint method on the layer texture if there is
|
||||||
|
* one. This will determine whether mipmaps are needed based on the
|
||||||
|
* filter settings.
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
_cogl_material_pre_paint_for_layer (CoglMaterial *material,
|
||||||
|
int layer_id);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* CoglMaterialFlushFlag:
|
* CoglMaterialFlushFlag:
|
||||||
* @COGL_MATERIAL_FLUSH_FALLBACK_MASK: The fallback_layers member is set to
|
* @COGL_MATERIAL_FLUSH_FALLBACK_MASK: The fallback_layers member is set to
|
||||||
|
@ -5237,6 +5237,14 @@ _cogl_material_layer_pre_paint (CoglMaterialLayer *layer)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
_cogl_material_pre_paint_for_layer (CoglMaterial *material,
|
||||||
|
int layer_id)
|
||||||
|
{
|
||||||
|
CoglMaterialLayer *layer = _cogl_material_get_layer (material, layer_id);
|
||||||
|
_cogl_material_layer_pre_paint (layer);
|
||||||
|
}
|
||||||
|
|
||||||
CoglMaterialFilter
|
CoglMaterialFilter
|
||||||
cogl_material_layer_get_min_filter (CoglMaterialLayer *layer)
|
cogl_material_layer_get_min_filter (CoglMaterialLayer *layer)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user