Commit e624c93b authored by Sébastien Toque's avatar Sébastien Toque

Do not try to resize surface with 0x0 size

This can happen if video size equals screen size,
setSurfaceSize is not called since no resize is required,
which means mVideoWidth is not intialized.
In this case, a simple orientation change will trigger
a useless setSurfaceSize(0,0,0,0)
parent a2c49f4d
......@@ -475,6 +475,9 @@ public class VideoPlayerActivity extends Activity {
public void setSurfaceSize(int width, int height, int sar_num, int sar_den) {
if (width * height == 0)
// store video size
mVideoHeight = height;
mVideoWidth = width;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment