Example usage for com.badlogic.gdx.graphics GL10 glScalef

List of usage examples for com.badlogic.gdx.graphics GL10 glScalef

Introduction

In this page you can find the example usage for com.badlogic.gdx.graphics GL10 glScalef.

Prototype

public void glScalef(float x, float y, float z);

Source Link

Usage

From source file:org.interreg.docexplore.reader.book.roi.ROIOverlay.java

License:Open Source License

static void doQuad(float x1, float y1, float x2, float y2) {
    if (quad == null)
        quad = GfxUtils.buildQuad(0, 0, 0, 0, 1, 1, 1, 1);

    GL10 gl = Gdx.gl10;
    gl.glMatrixMode(GL10.GL_MODELVIEW);//from w w  w  .  j  a  v  a  2  s .  c  om
    gl.glPushMatrix();
    gl.glTranslatef(x1, y1, 0);
    gl.glScalef(x2 - x1, y2 - y1, 1);
    quad.render(GL10.GL_TRIANGLES);
    gl.glPopMatrix();
}