Example usage for android.view SurfaceHolder getSurfaceFrame

List of usage examples for android.view SurfaceHolder getSurfaceFrame

Introduction

In this page you can find the example usage for android.view SurfaceHolder getSurfaceFrame.

Prototype

public Rect getSurfaceFrame();

Source Link

Document

Retrieve the current size of the surface.

Usage

From source file:Main.java

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;
    }//from w ww.j av a  2 s . c om
    return false;
}