Java tutorial
//package com.java2s; //License from project: Apache License import android.graphics.Rect; import android.view.SurfaceHolder; public class Main { static boolean validSurface(SurfaceHolder holder) { if (holder.getSurface() != null) { Rect r = holder.getSurfaceFrame(); System.out.println("ExoVlcUtil.validSurface() r = " + r); return (r.width() * r.height()) > 0; } return false; } }