Methods Summary |
---|
public RenderScriptGL | createRenderScriptGL(RenderScriptGL.SurfaceConfig sc)
RenderScriptGL rs = new RenderScriptGL(this.getContext(), sc);
setRenderScriptGL(rs);
if (mSurfaceTexture != null) {
mRS.setSurfaceTexture(mSurfaceTexture, getWidth(), getHeight());
}
return rs;
|
public void | destroyRenderScriptGL()
mRS.destroy();
mRS = null;
|
public RenderScriptGL | getRenderScriptGL()
return mRS;
|
private void | init()
setSurfaceTextureListener(this);
//android.util.Log.e("rs", "getSurfaceTextureListerner " + getSurfaceTextureListener());
|
public void | onSurfaceTextureAvailable(android.graphics.SurfaceTexture surface, int width, int height)
//Log.e(RenderScript.LOG_TAG, "onSurfaceTextureAvailable");
mSurfaceTexture = surface;
if (mRS != null) {
mRS.setSurfaceTexture(mSurfaceTexture, width, height);
}
|
public boolean | onSurfaceTextureDestroyed(android.graphics.SurfaceTexture surface)
//Log.e(RenderScript.LOG_TAG, "onSurfaceTextureDestroyed");
mSurfaceTexture = surface;
if (mRS != null) {
mRS.setSurfaceTexture(null, 0, 0);
}
return true;
|
public void | onSurfaceTextureSizeChanged(android.graphics.SurfaceTexture surface, int width, int height)
//Log.e(RenderScript.LOG_TAG, "onSurfaceTextureSizeChanged");
mSurfaceTexture = surface;
if (mRS != null) {
mRS.setSurfaceTexture(mSurfaceTexture, width, height);
}
|
public void | onSurfaceTextureUpdated(android.graphics.SurfaceTexture surface)
//Log.e(RenderScript.LOG_TAG, "onSurfaceTextureUpdated");
mSurfaceTexture = surface;
|
public void | pause()
if(mRS != null) {
mRS.pause();
}
|
public void | resume()
if(mRS != null) {
mRS.resume();
}
|
public void | setRenderScriptGL(RenderScriptGL rs)
mRS = rs;
if (mSurfaceTexture != null) {
mRS.setSurfaceTexture(mSurfaceTexture, getWidth(), getHeight());
}
|