Code example for Allocation

Methods: setSurfaceTexture

0
        filter(); 
    } 
 
    @Override 
    public void onSurfaceTextureSizeChanged(SurfaceTexture surface, int width, int height) {
        mOutPixelsAllocation.setSurfaceTexture(surface);
    } 
 
    @Override 
    public boolean onSurfaceTextureDestroyed(SurfaceTexture surface) {
        mOutPixelsAllocation.setSurfaceTexture(null);
        return true; 
    } 
 
    @Override 
    public void onSurfaceTextureUpdated(SurfaceTexture surface) {
    } 
}