com.partnersoft.maps.render
Class GLDrawingSurface

java.lang.Object
  extended by com.partnersoft.maps.render.AbstractDrawingSurface
      extended by com.partnersoft.maps.render.GLDrawingSurface
All Implemented Interfaces:
RoverConstants, DrawingSurface

public class GLDrawingSurface
extends AbstractDrawingSurface
implements RoverConstants

Superslow direct rendering of geometry into an image buffer.

Author:
Paul Reavis Copyright 2003 Partner Software, Inc.

Field Summary
 
Fields inherited from class com.partnersoft.maps.render.AbstractDrawingSurface
backgroundColor, currentMapSet, currentPointStyle, currentPolygonStyle, currentPolylineStyle, currentTextStyle, foregroundColor, frame, invisiblePolylineStyle, printing, renderMode, renderPointStyle, renderPolylineStyle, renderQuality, renderTextStyle, selectionPixelX, selectionPixelY, showInvisibleGraphics
 
Fields inherited from interface com.partnersoft.io.formats.rover.RoverConstants
ALIGN_BOTTOM_CENTER, ALIGN_BOTTOM_FIT, ALIGN_BOTTOM_LEFT, ALIGN_BOTTOM_RIGHT, ALIGN_CENTER, ALIGN_CENTER_LEFT, ALIGN_CENTER_RIGHT, ALIGN_CODE_CENTER, ALIGN_CODE_FIT, ALIGN_CODE_HIGH, ALIGN_CODE_LOW, ALIGN_FIT, ALIGN_FIT_LEFT, ALIGN_FIT_RIGHT, ALIGN_TOP_CENTER, ALIGN_TOP_FIT, ALIGN_TOP_LEFT, ALIGN_TOP_RIGHT, COMMENT, DATA_FIELDS_MAX, EOF, FLOAT_COORDS, GEOMETRY_TYPE_NAMES, HAS_DATA, HAS_OFFSET, HAS_ROTATION, LIST, MASK_TYPECODE, NAMING, POINT, POINT_COLOR, POLYGON, POLYLINE, POP, PUSH, RENDER_FINDITEM, RENDER_INDICATION, RENDER_NORMAL, RENDER_SELECTION, ROTATION_MULT, TEXEL_COORD_MAX, TEXEL_COORD_SIZE, TEXT, TILE_COORD_MAX, TILE_SIZE_PIXELS, VALUE
 
Fields inherited from interface com.partnersoft.maps.render.DrawingSurface
QUALITY_GOOD, QUALITY_OK, QUALITY_POOR, RENDER_EPHEMERA, RENDER_RASTER, RENDER_RETICULE, RENDER_SELECT, RENDER_SELECTION, RENDER_VECTOR
 
Constructor Summary
GLDrawingSurface(EZ2DGL ezgl, int quality, boolean animated)
           
 
Method Summary
 void clear()
           
 int displayListFor(long key)
           
 int displayListFor(java.lang.Object key)
           
 void drawDisplayList(int displayListID)
           
 void drawPoint(int dataID, double x, double y, int offsetX, int offsetY, int rotation)
           
 void drawPointColor(int dataID, double x, double y, int offsetX, int offsetY, int rotation, int red, int green, int blue, int alpha)
           
 void drawPolygon(int dataID, DoubleBuffer coords)
           
 void drawPolyline(int dataID, DoubleBuffer coords)
           
 void drawRasterImage(RasterImage image)
           
 void drawText(double x, double y, int offsetX, int offsetY, int rotation, int alignment, java.lang.String text)
           
 void drawWheelMenu(WheelMenu menu)
           
 void drawWheelMenuCenter(WheelMenu menu)
           
 void endDisplayList()
           
 void endTile()
           
 EZ2DGL getEZ2DGL()
           
 int[][] getSelections()
           
 boolean isDirty()
           
 void popName()
           
 void pushName(int i)
           
 void removeDisplayList(int displayListID)
           
 void setBackgroundColor(int color)
           
 void setForegroundColor(int color)
           
 void setFrame(MapViewFrame newFrame)
           
 void setPointStyle(int style)
           
 void setPointStyle(PointStyle style)
           
 void setPolygonStyle(PolygonStyle style)
           
 void setPolylineStyle(int style)
           
 void setPolylineStyle(PolylineStyle style)
           
 void setRenderMode(int newMode)
           
 void setTextStyle(int style)
           
 void setTextStyle(TextStyle style)
           
 int startDisplayList(long key)
           
 int startDisplayList(java.lang.Object key)
           
 void startDrawing()
           
 void startTile(RoverBytes bytes)
          Sets up the transformations for the coordinates that are coming in.
 void stopDrawing()
           
 
Methods inherited from class com.partnersoft.maps.render.AbstractDrawingSurface
isDisplayListSupported, setMapSet, setPrinting, setRenderQuality, setRenderScaleRegion, setSelectionPixel, setShowInvisibleGraphics
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GLDrawingSurface

public GLDrawingSurface(EZ2DGL ezgl,
                        int quality,
                        boolean animated)
Method Detail

isDirty

public boolean isDirty()
Specified by:
isDirty in interface DrawingSurface

setRenderMode

public void setRenderMode(int newMode)
Specified by:
setRenderMode in interface DrawingSurface
Overrides:
setRenderMode in class AbstractDrawingSurface

startDrawing

public void startDrawing()
Specified by:
startDrawing in interface DrawingSurface
Specified by:
startDrawing in class AbstractDrawingSurface

startTile

public void startTile(RoverBytes bytes)
Sets up the transformations for the coordinates that are coming in.

Specified by:
startTile in interface DrawingSurface
Parameters:
bytes - everything we need to set up our transformation.

endTile

public void endTile()
Specified by:
endTile in interface DrawingSurface

clear

public void clear()
Specified by:
clear in interface DrawingSurface

stopDrawing

public void stopDrawing()
Specified by:
stopDrawing in interface DrawingSurface
Specified by:
stopDrawing in class AbstractDrawingSurface

setFrame

public void setFrame(MapViewFrame newFrame)
Specified by:
setFrame in interface DrawingSurface
Overrides:
setFrame in class AbstractDrawingSurface

setBackgroundColor

public void setBackgroundColor(int color)
Specified by:
setBackgroundColor in interface DrawingSurface
Overrides:
setBackgroundColor in class AbstractDrawingSurface

setForegroundColor

public void setForegroundColor(int color)
Specified by:
setForegroundColor in interface DrawingSurface
Overrides:
setForegroundColor in class AbstractDrawingSurface

setPolygonStyle

public void setPolygonStyle(PolygonStyle style)
Specified by:
setPolygonStyle in interface DrawingSurface
Overrides:
setPolygonStyle in class AbstractDrawingSurface

setPolylineStyle

public void setPolylineStyle(int style)
Specified by:
setPolylineStyle in interface DrawingSurface
Overrides:
setPolylineStyle in class AbstractDrawingSurface

setPolylineStyle

public void setPolylineStyle(PolylineStyle style)
Specified by:
setPolylineStyle in interface DrawingSurface
Overrides:
setPolylineStyle in class AbstractDrawingSurface

setPointStyle

public void setPointStyle(int style)
Specified by:
setPointStyle in interface DrawingSurface
Overrides:
setPointStyle in class AbstractDrawingSurface

setPointStyle

public void setPointStyle(PointStyle style)
Specified by:
setPointStyle in interface DrawingSurface
Overrides:
setPointStyle in class AbstractDrawingSurface

setTextStyle

public void setTextStyle(int style)
Specified by:
setTextStyle in interface DrawingSurface
Overrides:
setTextStyle in class AbstractDrawingSurface

setTextStyle

public void setTextStyle(TextStyle style)
Specified by:
setTextStyle in interface DrawingSurface
Overrides:
setTextStyle in class AbstractDrawingSurface

drawPolygon

public void drawPolygon(int dataID,
                        DoubleBuffer coords)
Specified by:
drawPolygon in interface DrawingSurface
Specified by:
drawPolygon in class AbstractDrawingSurface

drawPolyline

public void drawPolyline(int dataID,
                         DoubleBuffer coords)
Specified by:
drawPolyline in interface DrawingSurface
Specified by:
drawPolyline in class AbstractDrawingSurface

drawPoint

public void drawPoint(int dataID,
                      double x,
                      double y,
                      int offsetX,
                      int offsetY,
                      int rotation)
Specified by:
drawPoint in interface DrawingSurface
Specified by:
drawPoint in class AbstractDrawingSurface

drawPointColor

public void drawPointColor(int dataID,
                           double x,
                           double y,
                           int offsetX,
                           int offsetY,
                           int rotation,
                           int red,
                           int green,
                           int blue,
                           int alpha)
Specified by:
drawPointColor in interface DrawingSurface

drawText

public void drawText(double x,
                     double y,
                     int offsetX,
                     int offsetY,
                     int rotation,
                     int alignment,
                     java.lang.String text)
Specified by:
drawText in interface DrawingSurface
Specified by:
drawText in class AbstractDrawingSurface

drawRasterImage

public void drawRasterImage(RasterImage image)
Specified by:
drawRasterImage in interface DrawingSurface

drawWheelMenuCenter

public void drawWheelMenuCenter(WheelMenu menu)
Specified by:
drawWheelMenuCenter in interface DrawingSurface

drawWheelMenu

public void drawWheelMenu(WheelMenu menu)
Specified by:
drawWheelMenu in interface DrawingSurface

displayListFor

public int displayListFor(java.lang.Object key)
Specified by:
displayListFor in interface DrawingSurface
Overrides:
displayListFor in class AbstractDrawingSurface

displayListFor

public int displayListFor(long key)
Specified by:
displayListFor in interface DrawingSurface
Overrides:
displayListFor in class AbstractDrawingSurface

startDisplayList

public int startDisplayList(long key)
Specified by:
startDisplayList in interface DrawingSurface
Overrides:
startDisplayList in class AbstractDrawingSurface

startDisplayList

public int startDisplayList(java.lang.Object key)
Specified by:
startDisplayList in interface DrawingSurface
Overrides:
startDisplayList in class AbstractDrawingSurface

endDisplayList

public void endDisplayList()
Specified by:
endDisplayList in interface DrawingSurface
Overrides:
endDisplayList in class AbstractDrawingSurface

drawDisplayList

public void drawDisplayList(int displayListID)
Specified by:
drawDisplayList in interface DrawingSurface
Overrides:
drawDisplayList in class AbstractDrawingSurface

removeDisplayList

public void removeDisplayList(int displayListID)
Specified by:
removeDisplayList in interface DrawingSurface
Overrides:
removeDisplayList in class AbstractDrawingSurface

pushName

public void pushName(int i)
Specified by:
pushName in interface DrawingSurface
Specified by:
pushName in class AbstractDrawingSurface

popName

public void popName()
Specified by:
popName in interface DrawingSurface
Specified by:
popName in class AbstractDrawingSurface

getSelections

public int[][] getSelections()
Specified by:
getSelections in interface DrawingSurface
Specified by:
getSelections in class AbstractDrawingSurface

getEZ2DGL

public EZ2DGL getEZ2DGL()