Project

General

Profile

« Previous | Next » 

Revision 3d267840

Added by Leszek Koltunski over 5 years ago

Improve the Rubik App.

View differences:

src/main/java/org/distorted/examples/rubik/RubikRenderer.java
279 279
      return scaleFactor*NUM_CUBES*SIZE;
280 280
      }
281 281

  
282
///////////////////////////////////////////////////////////////////////////////////////////////////
283

  
284
    void rotateFace(Static3D vector, int angle, int row )
285
      {
286
      String vect = "("+vector.get1()+","+vector.get2()+","+vector.get3()+")";
287

  
288
      android.util.Log.e("rubik", "rotating by "+angle+" degrees, row="+row+" vector: "+vect);
289
      }
290

  
282 291
///////////////////////////////////////////////////////////////////////////////////////////////////
283 292

  
284 293
    float getScreenWidth()
src/main/java/org/distorted/examples/rubik/RubikSurfaceView.java
199 199
                     break;
200 200
        }
201 201

  
202
      //if( rotRC==cubeHalfSize+1 ) rotRC=cubeHalfSize;
203

  
204
      String vect = (rotV==VECTX ? "X" : (rotV==VECTY? "Y":"Z") );
205

  
206
      android.util.Log.e("rubik", "rotating by "+rotA+" degrees, face="+rotRC+" vector: "+vect);
202
      mRenderer.rotateFace(rotV,rotA,rotRC);
207 203
      }
208 204

  
209 205
///////////////////////////////////////////////////////////////////////////////////////////////////

Also available in: Unified diff