mirror of https://github.com/mpv-player/mpv
vo_opengl: don't crash on unsupported formats
Regression from recent refactor.
This commit is contained in:
parent
b3488822fd
commit
f02752c0d5
|
@ -415,10 +415,11 @@ supported:
|
|||
snprintf(out->swizzle, sizeof(out->swizzle), "%s", swizzle);
|
||||
out->num_planes = desc.num_planes;
|
||||
for (int n = 0; n < desc.num_planes; n++) {
|
||||
if (!planes[n])
|
||||
return false;
|
||||
out->xs[n] = desc.xs[n];
|
||||
out->ys[n] = desc.ys[n];
|
||||
out->planes[n] = planes[n];
|
||||
assert(planes[n]);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue