org.diamondspin
Class DSEngineForN

java.lang.Object
  extended by org.diamondspin.DSEngineForN
All Implemented Interfaces:
DSEngine

public class DSEngineForN
extends Object
implements DSEngine

DSEngineForN is an engine to rotate/zoom/translate the documents according to n sides where n is the number of users.

Copyright 2002-2009 DiamondSpin project. All Rights Reserved.

Permission to use, copy, modify and distribute this software and its documentation for educational, research and non-profit purposes, without fee, and without a written agreement is hereby granted, provided that the above copyright notice and the following three paragraphs appear in all copies.

To request Permission to incorporate this software into commercial products contact one of the authors of the project.
  • Frederic Vernier (frederic.vernier@limsi.fr)
  • Chia Shen (chia_shen@harvard.edu)
  • Guillaume Besacier (guillaume.besacier@limsi.fr)
  • Daniel Wigdor (dwigdor@microsoft.com)

IN NO EVENT SHALL THE AUTHORS BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE AUTHORS HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

THE AUTHORS SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE AUTHORS HAS NO OBLIGATIONS TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.

Version:
: 1.1
Author:
: Frederic vernier, (frederic.vernier@limsi.com)

Field Summary
static int BLACKHOLE
           
protected  int defMode
           
static int ENGINE_FOR_2H
           
static int ENGINE_FOR_2V
           
static int ENGINE_FOR_4
           
static int ENGINE_FOR_8
           
static int ENGINE_FOR_N
           
static int FISHEYE
           
static int NORMAL
           
 
Fields inherited from interface org.diamondspin.DSEngine
BETA_ABS, DRAG_ELEMENT, ELEMENT, MENUBAR, POPUPMENU, STROKE
 
Constructor Summary
DSEngineForN(DSTabletopPane dsTabletopPane_Arg, int userCount_Arg)
          Constructor
 
Method Summary
 int getDefMode()
           
 boolean isMenubarCircular()
          tells to DSMenubar which policy to choose to draw the border of the menubar
 void setDefMode(int defMode)
           
 AffineTransform transformTable(double d, double alpha, double beta, double scale, double tangle, double tzoom, int elType, int userid)
          Return an AffineTransform object to apply to a Graphics2D before drawing an element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ENGINE_FOR_4

public static final int ENGINE_FOR_4
See Also:
Constant Field Values

ENGINE_FOR_2V

public static final int ENGINE_FOR_2V
See Also:
Constant Field Values

ENGINE_FOR_2H

public static final int ENGINE_FOR_2H
See Also:
Constant Field Values

ENGINE_FOR_8

public static final int ENGINE_FOR_8
See Also:
Constant Field Values

ENGINE_FOR_N

public static final int ENGINE_FOR_N
See Also:
Constant Field Values

NORMAL

public static final int NORMAL
See Also:
Constant Field Values

FISHEYE

public static final int FISHEYE
See Also:
Constant Field Values

BLACKHOLE

public static final int BLACKHOLE
See Also:
Constant Field Values

defMode

protected int defMode
Constructor Detail

DSEngineForN

public DSEngineForN(DSTabletopPane dsTabletopPane_Arg,
                    int userCount_Arg)
Constructor

Method Detail

isMenubarCircular

public boolean isMenubarCircular()
Description copied from interface: DSEngine
tells to DSMenubar which policy to choose to draw the border of the menubar

Specified by:
isMenubarCircular in interface DSEngine

transformTable

public AffineTransform transformTable(double d,
                                      double alpha,
                                      double beta,
                                      double scale,
                                      double tangle,
                                      double tzoom,
                                      int elType,
                                      int userid)
Description copied from interface: DSEngine
Return an AffineTransform object to apply to a Graphics2D before drawing an element.

Specified by:
transformTable in interface DSEngine
Parameters:
d - the distance from the center of the table to the center of the element. 0.5 means between the center and the border
alpha - the angle of the element. Angle around the center of the table (trigonometric system)
beta - angle around the center of the element
scale - the scale factor. may be modified by a blackhole or fisheye technique
tangle - the angle of the whole table to add it to Alpha. 0 when dragged and = angle of the view otherwise
tzoom - the scale of the whole table
elType - element type tells if the element is metalic or not then subject to magnetization !
userid - user id of the owner of element to transform
Returns:
a transformation matrix decribing the element rotations, scale, translation according to the parameter values

getDefMode

public int getDefMode()

setDefMode

public void setDefMode(int defMode)


Copyright © 2006 Frederic Vernier(LIMSI) Chia Shen(MERL) Guillaume Besacier(LIMSI). All Rights Reserved.