jp.digitalmuseum.mr.hakoniwa
クラス Hakoniwa

java.lang.Object
  上位を拡張 jp.digitalmuseum.mr.service.ServiceAbstractImpl
      上位を拡張 jp.digitalmuseum.mr.hakoniwa.Hakoniwa
すべての実装されたインタフェース:
java.io.Serializable, java.lang.Runnable, EventProvider, CoordProvider, EntityInformationProvider, ImageProvider, LocationProvider, ScreenLocationProvider, Service

public class Hakoniwa
extends ServiceAbstractImpl
implements LocationProvider, ScreenLocationProvider, CoordProvider
関連項目:
直列化された形式

入れ子のクラスの概要
 
インタフェース jp.digitalmuseum.mr.service.ImageProvider から継承された入れ子のクラス/インタフェース
ImageProvider.ImageListener
 
フィールドの概要
 
クラス jp.digitalmuseum.mr.service.ServiceAbstractImpl から継承されたフィールド
DEFAULT_INTERVAL
 
コンストラクタの概要
Hakoniwa()
           
Hakoniwa(int width, int height)
           
 
メソッドの概要
 void addImageListener(ImageProvider.ImageListener listener)
           
 boolean contains(Entity entity)
           
 boolean contains(Entity e, Position position)
           
 java.awt.Graphics2D createBackgroundGraphics()
          Do not dispose this graphics context.
 void destroyMouseJoint()
           
 void drawImage(java.awt.Graphics g)
          Draw the current image in the specified graphics context.
 void drawImage(java.awt.Graphics g, int x, int y)
          Draw the current image in the specified graphics context and position.
 float getAngularDamping()
           
 javax.swing.JComponent getConfigurationComponent()
           
 CoordProvider getCoordProvider()
           
 java.util.Set<Entity> getEntities()
           
static Hakoniwa getHakoniwaFor(HakoniwaEntity e)
           
 int getHeight()
          Get height of the captured image.
 java.awt.image.BufferedImage getImage()
          Get an image data as a BufferedImage object.
 byte[] getImageData()
          Get an image data as a BGR byte array.
 float getLinearDamping()
           
 Location getLocation(Entity e)
           
 void getLocationOut(Entity e, Location location)
           
 HakoniwaEntity getMouseJointedEntity()
           
 java.lang.String getName()
           
 Position getPosition(Entity e)
           
 void getPositionOut(Entity e, Position position)
           
 double getRealHeight()
          Get height of the real world coordinate area.
 double getRealWidth()
          Get width of the real world coordinate area.
 double getRotation(Entity e)
          Returns 0 if not able to specify the rotation.
 ScreenLocation getScreenLocation(Entity e)
           
 void getScreenLocationOut(Entity e, ScreenLocation screenLocation)
           
 ScreenPosition getScreenPosition(Entity e)
           
 void getScreenPositionOut(Entity e, ScreenPosition screenPosition)
           
 double getScreenRotation(Entity e)
           
 int getScreenX(Entity e)
           
 int getScreenY(Entity e)
           
 int getWidth()
          Get width of the captured image.
 org.jbox2d.dynamics.World getWorld()
           
 double getX(Entity e)
          Returns 0 if not able to specify the position.
 double getY(Entity e)
          Returns 0 if not able to specify the position.
 boolean hasMouseJoint()
           
 boolean isAntialiased()
           
 boolean isBackgroundTransparent()
           
 ScreenLocation realToScreen(Location realLocation)
           
 ScreenPosition realToScreen(Position realPosition)
           
 void realToScreenOut(Location realLocation, ScreenLocation screenLocation)
          Convert real location to screen location.
 void realToScreenOut(Position realPosition, ScreenPosition screenPosition)
          Convert real position to screen position.
 boolean removeImageListener(ImageProvider.ImageListener listener)
           
 void run()
           
 Location screenToReal(ScreenLocation screenLocation)
           
 Position screenToReal(ScreenPosition screenPosition)
           
 void screenToRealOut(ScreenLocation screenLocation, Location location)
          Convert screen location to real location.
 void screenToRealOut(ScreenPosition screenPosition, Position realPosition)
          Convert screen position to real position.
 void setAngularDamping(float angularDamping)
           
 void setAntialiased(boolean isAntialiased)
           
 void setBackgroundTransparent(boolean backgroundTransparent)
           
 void setLinearDamping(float linearDamping)
           
 void setViewportScale(float scale)
          Set scale of the viewport.
 void setViewportSize(int screenWidth, int screenHeight)
          Set size of the viewport.
 void updateMouseJoint(Position p, HakoniwaEntity e)
           
 
クラス jp.digitalmuseum.mr.service.ServiceAbstractImpl から継承されたメソッド
addEventListener, dispose, distributeEvent, getAliveTime, getInterval, getServiceGroup, initialize, isDisposed, isPaused, isStarted, onPause, onResume, onStart, onStop, pause, removeEventListener, resume, setInterval, setServiceGroup, start, start, stop, toString
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
インタフェース jp.digitalmuseum.mr.service.Service から継承されたメソッド
dispose, getAliveTime, getInterval, getServiceGroup, isDisposed, isPaused, isStarted, pause, resume, setInterval, setServiceGroup, start, start, stop
 
インタフェース jp.digitalmuseum.mr.message.EventProvider から継承されたメソッド
addEventListener, removeEventListener
 
コンストラクタの詳細

Hakoniwa

public Hakoniwa()

Hakoniwa

public Hakoniwa(int width,
                int height)
メソッドの詳細

run

public void run()
定義:
インタフェース java.lang.Runnable 内の run

getHakoniwaFor

public static Hakoniwa getHakoniwaFor(HakoniwaEntity e)

getLinearDamping

public float getLinearDamping()

setLinearDamping

public void setLinearDamping(float linearDamping)

getAngularDamping

public float getAngularDamping()

setAngularDamping

public void setAngularDamping(float angularDamping)

updateMouseJoint

public void updateMouseJoint(Position p,
                             HakoniwaEntity e)

destroyMouseJoint

public void destroyMouseJoint()

hasMouseJoint

public boolean hasMouseJoint()

getMouseJointedEntity

public HakoniwaEntity getMouseJointedEntity()

isBackgroundTransparent

public boolean isBackgroundTransparent()

setBackgroundTransparent

public void setBackgroundTransparent(boolean backgroundTransparent)

isAntialiased

public boolean isAntialiased()

setAntialiased

public void setAntialiased(boolean isAntialiased)

getWorld

public org.jbox2d.dynamics.World getWorld()

createBackgroundGraphics

public java.awt.Graphics2D createBackgroundGraphics()
Do not dispose this graphics context.
戻り値:

getName

public java.lang.String getName()
定義:
インタフェース Service 内の getName
オーバーライド:
クラス ServiceAbstractImpl 内の getName
戻り値:
Returns the name of this service.

setViewportSize

public void setViewportSize(int screenWidth,
                            int screenHeight)
Set size of the viewport.
パラメータ:
screenWidth - Width of the viewport in [px].
screenHeight - Height of the viewport in [px].

setViewportScale

public void setViewportScale(float scale)
Set scale of the viewport.
パラメータ:
scale - [pixels/cm]

getWidth

public int getWidth()
インタフェース ImageProvider の記述:
Get width of the captured image.
定義:
インタフェース ImageProvider 内の getWidth

getHeight

public int getHeight()
インタフェース ImageProvider の記述:
Get height of the captured image.
定義:
インタフェース ImageProvider 内の getHeight

getRealWidth

public double getRealWidth()
インタフェース CoordProvider の記述:
Get width of the real world coordinate area.
定義:
インタフェース CoordProvider 内の getRealWidth
戻り値:

getRealHeight

public double getRealHeight()
インタフェース CoordProvider の記述:
Get height of the real world coordinate area.
定義:
インタフェース CoordProvider 内の getRealHeight
戻り値:

realToScreen

public ScreenLocation realToScreen(Location realLocation)
定義:
インタフェース CoordProvider 内の realToScreen
戻り値:
関連項目:
CoordProvider.realToScreenOut(Location, ScreenLocation)

realToScreen

public ScreenPosition realToScreen(Position realPosition)
定義:
インタフェース CoordProvider 内の realToScreen
戻り値:
関連項目:
CoordProvider.realToScreenOut(Position, ScreenPosition)

realToScreenOut

public void realToScreenOut(Location realLocation,
                            ScreenLocation screenLocation)
インタフェース CoordProvider の記述:
Convert real location to screen location.
定義:
インタフェース CoordProvider 内の realToScreenOut

realToScreenOut

public void realToScreenOut(Position realPosition,
                            ScreenPosition screenPosition)
インタフェース CoordProvider の記述:
Convert real position to screen position.
定義:
インタフェース CoordProvider 内の realToScreenOut

screenToReal

public Location screenToReal(ScreenLocation screenLocation)
                      throws java.lang.IllegalArgumentException
定義:
インタフェース CoordProvider 内の screenToReal
戻り値:
例外:
java.lang.IllegalArgumentException
関連項目:
CoordProvider.screenToRealOut(ScreenLocation, Location)

screenToReal

public Position screenToReal(ScreenPosition screenPosition)
                      throws java.lang.IllegalArgumentException
定義:
インタフェース CoordProvider 内の screenToReal
戻り値:
例外:
java.lang.IllegalArgumentException
関連項目:
CoordProvider.screenToRealOut(ScreenPosition, Position)

screenToRealOut

public void screenToRealOut(ScreenLocation screenLocation,
                            Location location)
                     throws java.lang.IllegalArgumentException
インタフェース CoordProvider の記述:
Convert screen location to real location.
定義:
インタフェース CoordProvider 内の screenToRealOut
例外:
java.lang.IllegalArgumentException

screenToRealOut

public void screenToRealOut(ScreenPosition screenPosition,
                            Position realPosition)
                     throws java.lang.IllegalArgumentException
インタフェース CoordProvider の記述:
Convert screen position to real position.
定義:
インタフェース CoordProvider 内の screenToRealOut
例外:
java.lang.IllegalArgumentException

drawImage

public void drawImage(java.awt.Graphics g)
インタフェース ImageProvider の記述:
Draw the current image in the specified graphics context.
定義:
インタフェース ImageProvider 内の drawImage

drawImage

public void drawImage(java.awt.Graphics g,
                      int x,
                      int y)
インタフェース ImageProvider の記述:
Draw the current image in the specified graphics context and position.
定義:
インタフェース ImageProvider 内の drawImage

getImage

public java.awt.image.BufferedImage getImage()
インタフェース ImageProvider の記述:
Get an image data as a BufferedImage object.
定義:
インタフェース ImageProvider 内の getImage

getImageData

public byte[] getImageData()
インタフェース ImageProvider の記述:
Get an image data as a BGR byte array.
定義:
インタフェース ImageProvider 内の getImageData
戻り値:

addImageListener

public void addImageListener(ImageProvider.ImageListener listener)
定義:
インタフェース ImageProvider 内の addImageListener

removeImageListener

public boolean removeImageListener(ImageProvider.ImageListener listener)
定義:
インタフェース ImageProvider 内の removeImageListener

getEntities

public java.util.Set<Entity> getEntities()
定義:
インタフェース EntityInformationProvider 内の getEntities
戻り値:
Returns a set of entities whose information is provided by this instance.

contains

public boolean contains(Entity entity)
定義:
インタフェース EntityInformationProvider 内の contains
戻り値:
Returns whether this provider provides information about the specified entity or not.

getCoordProvider

public CoordProvider getCoordProvider()
定義:
インタフェース LocationProvider 内の getCoordProvider

getLocation

public Location getLocation(Entity e)
定義:
インタフェース LocationProvider 内の getLocation

getLocationOut

public void getLocationOut(Entity e,
                           Location location)
定義:
インタフェース LocationProvider 内の getLocationOut

getPosition

public Position getPosition(Entity e)
定義:
インタフェース LocationProvider 内の getPosition

getPositionOut

public void getPositionOut(Entity e,
                           Position position)
定義:
インタフェース LocationProvider 内の getPositionOut

getX

public double getX(Entity e)
インタフェース LocationProvider の記述:
Returns 0 if not able to specify the position.
定義:
インタフェース LocationProvider 内の getX
戻り値:

getY

public double getY(Entity e)
インタフェース LocationProvider の記述:
Returns 0 if not able to specify the position.
定義:
インタフェース LocationProvider 内の getY
戻り値:

getRotation

public double getRotation(Entity e)
インタフェース LocationProvider の記述:
Returns 0 if not able to specify the rotation.
定義:
インタフェース LocationProvider 内の getRotation
戻り値:

contains

public boolean contains(Entity e,
                        Position position)
定義:
インタフェース LocationProvider 内の contains

getScreenLocation

public ScreenLocation getScreenLocation(Entity e)
定義:
インタフェース ScreenLocationProvider 内の getScreenLocation

getScreenLocationOut

public void getScreenLocationOut(Entity e,
                                 ScreenLocation screenLocation)
定義:
インタフェース ScreenLocationProvider 内の getScreenLocationOut

getScreenPosition

public ScreenPosition getScreenPosition(Entity e)
定義:
インタフェース ScreenLocationProvider 内の getScreenPosition

getScreenPositionOut

public void getScreenPositionOut(Entity e,
                                 ScreenPosition screenPosition)
定義:
インタフェース ScreenLocationProvider 内の getScreenPositionOut

getScreenX

public int getScreenX(Entity e)
定義:
インタフェース ScreenLocationProvider 内の getScreenX

getScreenY

public int getScreenY(Entity e)
定義:
インタフェース ScreenLocationProvider 内の getScreenY

getScreenRotation

public double getScreenRotation(Entity e)
定義:
インタフェース ScreenLocationProvider 内の getScreenRotation

getConfigurationComponent

public javax.swing.JComponent getConfigurationComponent()
定義:
インタフェース Service 内の getConfigurationComponent
オーバーライド:
クラス ServiceAbstractImpl 内の getConfigurationComponent
戻り値:
Returns a Swing component for configuring this service.
関連項目:
JComponent


Copyright by Jun KATO (arc@dmz) at https://mr.digitalmuseum.jp/