Fix crash when the video height or width is zero

Closes #1555. Closes #1644.
This commit is contained in:
Thomas Goyne 2013-10-08 15:21:26 -07:00
parent 4d8adff9d6
commit 267de7ed07

View file

@ -193,6 +193,9 @@ void VideoDisplay::Render() try {
return;
}
if (videoSize.GetWidth() == 0) videoSize.SetWidth(1);
if (videoSize.GetHeight() == 0) videoSize.SetHeight(1);
if (!viewport_height || !viewport_width)
PositionVideo();