commit 7a44bbc20e849abac670f528d6adcd51b7b9967a
Author: Leszek Koltunski <leszek@koltunski.pl>
Date:   Sat May 8 16:59:07 2021 +0200

    Progress with RubikControl.

diff --git a/src/main/java/org/distorted/control/RubikControlRotate.java b/src/main/java/org/distorted/control/RubikControlRotate.java
index d0e235e8..80f6ef70 100644
--- a/src/main/java/org/distorted/control/RubikControlRotate.java
+++ b/src/main/java/org/distorted/control/RubikControlRotate.java
@@ -22,6 +22,7 @@ package org.distorted.control;
 import org.distorted.library.effect.MatrixEffectScale;
 import org.distorted.library.main.DistortedEffects;
 import org.distorted.library.main.DistortedNode;
+import org.distorted.library.main.DistortedScreen;
 import org.distorted.library.main.DistortedTexture;
 import org.distorted.library.mesh.MeshQuad;
 import org.distorted.library.type.Dynamic;
@@ -52,8 +53,11 @@ class RubikControlRotate
       mEffects   = new DistortedEffects[NUM_NODE];
       mEffects[0]= new DistortedEffects();
 
+      DistortedScreen screen = mControl.getScreen();
+      int wid = screen.getWidth();
+
       Static3D scaleStart= new Static3D(1,1,1);
-      Static3D scaleEnd  = new Static3D(1000,1000,1000);
+      Static3D scaleEnd  = new Static3D(wid,wid,wid);
 
       mDynamic = new Dynamic3D(10000,0.5f);
       mDynamic.add(scaleStart);
diff --git a/src/main/java/org/distorted/control/RubikControlWhole.java b/src/main/java/org/distorted/control/RubikControlWhole.java
index 52874d68..58ff0baa 100644
--- a/src/main/java/org/distorted/control/RubikControlWhole.java
+++ b/src/main/java/org/distorted/control/RubikControlWhole.java
@@ -86,6 +86,8 @@ class RubikControlWhole
       float x1 = wid*0.35f;
       float y1 = hei*0.28f;
       float z  = 0;
+      float handScale = wid*0.33f;
+      float circScale = handScale*0.5f;
 
       Static3D point0 = new Static3D(-x1,-y1,z);
       Static3D point1 = new Static3D(  0,-y1,z);
@@ -113,9 +115,9 @@ class RubikControlWhole
       mMoveHand1.notifyWhenFinished(mControl);
       mEffectID = mMoveHand1.getID();
 
-      mEffects[0].apply( new MatrixEffectScale(150));
+      mEffects[0].apply( new MatrixEffectScale(circScale));
       mEffects[0].apply(mMoveHand1);
-      mEffects[2].apply( new MatrixEffectScale(300));
+      mEffects[2].apply( new MatrixEffectScale(handScale));
       mEffects[2].apply(mMoveHand1);
       }
     else
