From 7acd8ea6673b7a90ed4041408ccf1b024b8a007a Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Sun, 12 Jun 2011 02:37:51 -0600 Subject: Vast libdimension API and internals improvements. Couldn't really do these while I was trying to be POV-Ray compatible, 'cause they would've broken compatibility. --- libdimension/dimension/texture.h | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'libdimension/dimension/texture.h') diff --git a/libdimension/dimension/texture.h b/libdimension/dimension/texture.h index 7edcabc..0c944a9 100644 --- a/libdimension/dimension/texture.h +++ b/libdimension/dimension/texture.h @@ -26,13 +26,13 @@ /** A complete texture. */ typedef struct { dmnsn_pigment *pigment; /**< Pigment. */ - dmnsn_finish *finish; /**< Finish. */ + dmnsn_finish finish; /**< Finish. */ dmnsn_matrix trans; /**< Transformation matrix. */ dmnsn_matrix trans_inv; /**< The inverse of the transformation matrix. */ dmnsn_refcount refcount; /**< @internal Reference count. */ - bool should_init; /**< @internal Whether to initialize the texture. */ + bool initialized; /**< @internal Whether the texture is initialized yet. */ } dmnsn_texture; /** @@ -54,3 +54,11 @@ void dmnsn_delete_texture(dmnsn_texture *texture); * @param[in,out] texture The texture to initialize. */ void dmnsn_initialize_texture(dmnsn_texture *texture); + +/** + * Fill missing texture properties from a default texture. + * @param[in] default_texture The default texture. + * @param[in,out] texturep A pointer to the texture to fill. + */ +void dmnsn_texture_cascade(dmnsn_texture *default_texture, + dmnsn_texture **texture); -- cgit v1.2.3