diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2014-05-30 15:48:29 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2014-05-30 15:48:29 -0400 |
commit | 45e219eac23ea4a8181f68300fed693d9ac361a0 (patch) | |
tree | 06b72b3ca9a97b1352537836a2a42af7033ae6b1 /libdimension/dimension/canvas.h | |
parent | f61c7c75c3c7ff4a329315700d3efa1d77bafa6d (diff) | |
download | dimension-45e219eac23ea4a8181f68300fed693d9ac361a0.tar.xz |
canvas: Use pool.
Diffstat (limited to 'libdimension/dimension/canvas.h')
-rw-r--r-- | libdimension/dimension/canvas.h | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/libdimension/dimension/canvas.h b/libdimension/dimension/canvas.h index ba549ad..d03a37e 100644 --- a/libdimension/dimension/canvas.h +++ b/libdimension/dimension/canvas.h @@ -1,5 +1,5 @@ /************************************************************************* - * Copyright (C) 2009-2011 Tavian Barnes <tavianator@tavianator.com> * + * Copyright (C) 2009-2014 Tavian Barnes <tavianator@tavianator.com> * * * * This file is part of The Dimension Library. * * * @@ -39,8 +39,6 @@ typedef struct dmnsn_canvas { * at (a,b) is accessible as pixels[b*width + a]. */ dmnsn_tcolor *pixels; - - DMNSN_REFCOUNT; /**< Reference count. */ } dmnsn_canvas; /** @@ -63,17 +61,12 @@ typedef struct dmnsn_canvas_optimizer { /** * Allocate a new canvas. - * @param[in] width The width of the canvas to allocate (in pixels). + * @param[in] pool The memory pool to allocate from. + * @param[in] width The width of the canvas to allocate (in pixels). * @param[in] height The height of the canvas to allocate (in pixels). * @return The allocated canvas. */ -dmnsn_canvas *dmnsn_new_canvas(size_t width, size_t height); - -/** - * Delete a canvas. - * @param[in,out] canvas The canvas to delete. - */ -void dmnsn_delete_canvas(dmnsn_canvas *canvas); +dmnsn_canvas *dmnsn_new_canvas(dmnsn_pool *pool, size_t width, size_t height); /** * Set a canvas optimizer |