diff options
Diffstat (limited to 'source/blender/gpu/intern/gpu_drawlist_private.hh')
-rw-r--r-- | source/blender/gpu/intern/gpu_drawlist_private.hh | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_drawlist_private.hh b/source/blender/gpu/intern/gpu_drawlist_private.hh index ddb09fb0c89..fd223c3f255 100644 --- a/source/blender/gpu/intern/gpu_drawlist_private.hh +++ b/source/blender/gpu/intern/gpu_drawlist_private.hh @@ -25,6 +25,8 @@ #include "MEM_guardedalloc.h" +#include "GPU_drawlist.h" + namespace blender { namespace gpu { @@ -40,5 +42,19 @@ class DrawList { virtual void submit() = 0; }; +/* Syntacting suggar. */ +static inline GPUDrawList *wrap(DrawList *vert) +{ + return reinterpret_cast<GPUDrawList *>(vert); +} +static inline DrawList *unwrap(GPUDrawList *vert) +{ + return reinterpret_cast<DrawList *>(vert); +} +static inline const DrawList *unwrap(const GPUDrawList *vert) +{ + return reinterpret_cast<const DrawList *>(vert); +} + } // namespace gpu } // namespace blender |