diff options
author | Axel Davy <[email protected]> | 2016-11-04 22:39:14 +0100 |
---|---|---|
committer | Axel Davy <[email protected]> | 2016-12-20 23:44:22 +0100 |
commit | e068d3afe17cb7e26d8229ee279c71a09e9a20af (patch) | |
tree | ff94bd54e5a5895b7803c70677a146a9a3abf57f /src/gallium/state_trackers/nine/surface9.h | |
parent | bb666b0297cb81fc1b8192ba91efd2e0a69835c5 (diff) |
st/nine: Create pipe_surfaces on resource creation.
Create the pipe_surfaces on renderable resources creation.
This enables to avoid creating them on the fly.
Signed-off-by: Axel Davy <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers/nine/surface9.h')
-rw-r--r-- | src/gallium/state_trackers/nine/surface9.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/gallium/state_trackers/nine/surface9.h b/src/gallium/state_trackers/nine/surface9.h index 856c03b3844..d43739bb2ad 100644 --- a/src/gallium/state_trackers/nine/surface9.h +++ b/src/gallium/state_trackers/nine/surface9.h @@ -94,9 +94,8 @@ NineSurface9_CreatePipeSurface( struct NineSurface9 *This, const int sRGB ); static inline struct pipe_surface * NineSurface9_GetSurface( struct NineSurface9 *This, int sRGB ) { - if (This->surface[sRGB]) - return This->surface[sRGB]; - return NineSurface9_CreatePipeSurface(This, sRGB); + assert(This->surface[sRGB]); + return This->surface[sRGB]; } static inline struct pipe_resource * |