Fix NV12 video rendering in Picture-in-Picture panel.
This commit is contained in:
parent
3e1cac94bf
commit
4b328a236c
2 changed files with 8 additions and 0 deletions
|
@ -241,6 +241,10 @@ void OverlayWidget::RendererGL::paintTransformedVideoFrame(
|
|||
_chromaSize,
|
||||
yuv->u.stride / (nv12 ? 2 : 1),
|
||||
yuv->u.data);
|
||||
if (nv12) {
|
||||
_chromaSize = yuv->chromaSize;
|
||||
_f->glPixelStorei(GL_UNPACK_ALIGNMENT, 4);
|
||||
}
|
||||
}
|
||||
if (!nv12) {
|
||||
_f->glActiveTexture(GL_TEXTURE2);
|
||||
|
|
|
@ -334,6 +334,10 @@ void Pip::RendererGL::paintTransformedVideoFrame(
|
|||
_chromaSize,
|
||||
yuv->u.stride / (nv12 ? 2 : 1),
|
||||
yuv->u.data);
|
||||
if (nv12) {
|
||||
_chromaSize = yuv->chromaSize;
|
||||
_f->glPixelStorei(GL_UNPACK_ALIGNMENT, 4);
|
||||
}
|
||||
}
|
||||
if (!nv12) {
|
||||
_f->glActiveTexture(GL_TEXTURE2);
|
||||
|
|
Loading…
Reference in a new issue