Code example for ScaleGestureDetector

public class TestAppView extends RSSurfaceView { 
    public TestAppView(Context context) {
        mScaleDetector = new ScaleGestureDetector(context, new ScaleListener());
    private RenderScriptGL mRS;
    TestAppRS mRender;
    private ScaleGestureDetector mScaleDetector;
    private static final int INVALID_POINTER_ID = -1;
    private int mActivePointerId = INVALID_POINTER_ID;
    public void surfaceChanged(SurfaceHolder holder, int format, int w, int h) {
        super.surfaceChanged(holder, format, w, h);
        if (mRS == null) {
            RenderScriptGL.SurfaceConfig sc = new RenderScriptGL.SurfaceConfig();
            sc.setDepth(16, 24);
Connect your IDE to all the code out there  Get Codota for Java