Project

General

Profile

« Previous | Next » 

Revision 126393c8

Added by Leszek Koltunski about 4 years ago

Remove width & height from InternalSurface and move it to InternalOutputSurface.

View differences:

src/main/java/org/distorted/examples/listener/ListenerRenderer.java
114 114
    
115 115
   public void onSurfaceChanged(GL10 glUnused, int width, int height)
116 116
     {
117
     float horiRatio = (float)width / mTexture.getWidth();
118
     float vertRatio = (float)height/ mTexture.getHeight();
117
     float horiRatio = (float)width / mMesh.getStretchX();
118
     float vertRatio = (float)height/ mMesh.getStretchY();
119 119
     float factor    = horiRatio > vertRatio ? vertRatio : horiRatio;
120 120

  
121 121
     mScale.set( factor,factor,factor );

Also available in: Unified diff