diff options
Diffstat (limited to 'src/ui/visbuf.c')
-rw-r--r-- | src/ui/visbuf.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/ui/visbuf.c b/src/ui/visbuf.c index 107b8568..64d861c6 100644 --- a/src/ui/visbuf.c +++ b/src/ui/visbuf.c | |||
@@ -123,6 +123,14 @@ void invalidRanges_VisBuf(const iVisBuf *d, const iRangei full, iRangei *out_inv | |||
123 | } | 123 | } |
124 | } | 124 | } |
125 | 125 | ||
126 | void validate_VisBuf(iVisBuf *d) { | ||
127 | iForIndices(i, d->buffers) { | ||
128 | iVisBufTexture *buf = &d->buffers[i]; | ||
129 | buf->validRange = | ||
130 | intersect_Rangei(d->vis, (iRangei){ buf->origin, buf->origin + d->texSize.y }); | ||
131 | } | ||
132 | } | ||
133 | |||
126 | void draw_VisBuf(const iVisBuf *d, iInt2 topLeft) { | 134 | void draw_VisBuf(const iVisBuf *d, iInt2 topLeft) { |
127 | SDL_Renderer *render = renderer_Window(get_Window()); | 135 | SDL_Renderer *render = renderer_Window(get_Window()); |
128 | iForIndices(i, d->buffers) { | 136 | iForIndices(i, d->buffers) { |