diff options
-rw-r--r-- | video/out/gpu/video.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/video/out/gpu/video.c b/video/out/gpu/video.c index 2aae3171e6..e5a9737473 100644 --- a/video/out/gpu/video.c +++ b/video/out/gpu/video.c @@ -957,9 +957,6 @@ static void init_video(struct gl_video *p) params.w, params.h); plane->tex = ra_tex_create(p->ra, ¶ms); - if (!plane->tex) - abort(); // shit happens - p->use_integer_conversion |= format->ctype == RA_CTYPE_UINT; } } @@ -3588,6 +3585,10 @@ static bool pass_upload_image(struct gl_video *p, struct mp_image *mpi, uint64_t timer_pool_start(p->upload_timer); for (int n = 0; n < p->plane_count; n++) { struct texplane *plane = &vimg->planes[n]; + if (!plane->tex) { + timer_pool_stop(p->upload_timer); + goto error; + } struct ra_tex_upload_params params = { .tex = plane->tex, |