Project

General

Profile

« Previous | Next » 

Revision ecf3d6e3

Added by Leszek Koltunski over 2 years ago

1) introduce possibility to move objects, i.e. display them not in the middle of the screen (not fully functional yet)
2) do away with unneeded any more interface 'EffectController' - since ObjectPreRender is the only implementation now.

View differences:

src/main/java/org/distorted/objectlib/main/ObjectControl.java
26 26

  
27 27
import org.distorted.library.main.QuatHelper;
28 28
import org.distorted.library.type.Static2D;
29
import org.distorted.library.type.Static3D;
29 30
import org.distorted.library.type.Static4D;
30 31

  
31 32
import org.distorted.objectlib.helpers.BlockController;
......
56 57
    private Movement mMovement;
57 58
    private boolean mDragging, mBeginningRotation, mContinuingRotation;
58 59
    private int mScreenWidth, mScreenHeight, mScreenMin;
60
    private Static3D mMove;
59 61

  
60 62
    private float mRotAngle, mInitDistance;
61 63
    private float mStartRotX, mStartRotY;
......
487 489
        }
488 490
      }
489 491

  
492
///////////////////////////////////////////////////////////////////////////////////////////////////
493

  
494
    Static3D getMove()
495
      {
496
      return mMove;
497
      }
490 498

  
491 499
///////////////////////////////////////////////////////////////////////////////////////////////////
492 500
// INTERNAL API (for AutomaticControl)
......
528 536

  
529 537
      mPreRender = new ObjectPreRender(act,this,actioner);
530 538
      mInterface = actioner;
539
      mMove = new Static3D(0,0,0);
531 540
      }
532 541

  
533 542
///////////////////////////////////////////////////////////////////////////////////////////////////
......
540 549
      mPreRender.setScreenSize(width);
541 550
      }
542 551

  
552
///////////////////////////////////////////////////////////////////////////////////////////////////
553

  
554
    public void setMove(int xmove, int ymove)
555
      {
556
      mMove = new Static3D(xmove,ymove,0);
557
      }
558

  
543 559
///////////////////////////////////////////////////////////////////////////////////////////////////
544 560

  
545 561
    public void onPause()

Also available in: Unified diff