Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2017-03-26 20:25:45 +0300
committerClément Foucault <foucault.clem@gmail.com>2017-03-27 15:01:47 +0300
commit7ee41920fa0b7ed51a03fe4ee15c6fd782d294a8 (patch)
tree714908420f080cd068937da0aaa0e4e44873e81e /source/blender/gpu/GPU_viewport.h
parente54d8eeab2eac9b98bb57a886eb334a812f6487a (diff)
Draw Manager: New debug timers
Both CPU time and GPU time are printed to spot bottlenecks. GPU Timers works only if cache is enabled.
Diffstat (limited to 'source/blender/gpu/GPU_viewport.h')
-rw-r--r--source/blender/gpu/GPU_viewport.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/gpu/GPU_viewport.h b/source/blender/gpu/GPU_viewport.h
index 73619eb4a54..db68b603ae6 100644
--- a/source/blender/gpu/GPU_viewport.h
+++ b/source/blender/gpu/GPU_viewport.h
@@ -70,6 +70,12 @@ typedef struct ViewportEngineData {
TextureList *txl;
PassList *psl;
StorageList *stl;
+
+ /* Profiling data */
+ double init_time;
+ double cache_time;
+ double render_time;
+ double background_time;
} ViewportEngineData;
GPUViewport *GPU_viewport_create(void);
@@ -83,7 +89,7 @@ void *GPU_viewport_framebuffer_list_get(GPUViewport *viewport);
void *GPU_viewport_texture_list_get(GPUViewport *viewport);
void GPU_viewport_size_get(GPUViewport *viewport, int *size);
-bool GPU_viewport_cache_validate(GPUViewport *viewport, int hash);
+bool GPU_viewport_cache_validate(GPUViewport *viewport, unsigned int hash);
/* debug */
bool GPU_viewport_debug_depth_create(GPUViewport *viewport, int width, int height, char err_out[256]);