Package jto.processing.sketch.mapper
Class AbstractSketch
- java.lang.Object
- 
- jto.processing.sketch.mapper.AbstractSketch
 
- 
- 
Field SummaryFields Modifier and Type Field Description protected booleanautoGeneratedprotected processing.core.PGraphicsgraphicsthe PGraphics instance that this sketch will use to draw objects.protected processing.core.PAppletparentThe parent processing sketch of this sketch.
 - 
Constructor SummaryConstructors Constructor Description AbstractSketch(processing.core.PApplet parent, int width, int height)Constructor this creates a PGraphics object with the size provided in the parameters and the renderer specified byPConstants.OPENGL.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)StringgetName()Returns the name of the sketch.processing.core.PGraphicsgetPGraphics()Return the PGraphics associated with this sketch.inthashCode()booleanisAutoGenerated()voidsetAutoGenerated(boolean autoGenerated)Set the autoGenerated property.- 
Methods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface jto.processing.sketch.mapper.Sketchdraw, keyEvent, mouseEvent, setup
 
- 
 
- 
- 
- 
Field Detail- 
graphicsprotected final processing.core.PGraphics graphics the PGraphics instance that this sketch will use to draw objects.
 - 
parentprotected final processing.core.PApplet parent The parent processing sketch of this sketch. Can be used for PApplet methods.
 - 
autoGeneratedprotected boolean autoGenerated 
 
- 
 - 
Constructor Detail- 
AbstractSketchpublic AbstractSketch(processing.core.PApplet parent, int width, int height)Constructor this creates a PGraphics object with the size provided in the parameters and the renderer specified byPConstants.OPENGL.- Parameters:
- parent- the parent- PApplet.
- width- the width of the sketch in pixels.
- height- the height of the sketch in pixels.
 
 
- 
 - 
Method Detail- 
getNamepublic String getName() Description copied from interface:SketchReturns the name of the sketch. This is what will show up in the UI dropdown. Implement this to return custom labels if desired.
 - 
getPGraphicspublic processing.core.PGraphics getPGraphics() Description copied from interface:SketchReturn the PGraphics associated with this sketch.- Specified by:
- getPGraphicsin interface- Sketch
- Returns:
- the graphics object associated with this sketch.
 
 - 
isAutoGeneratedpublic boolean isAutoGenerated() - Specified by:
- isAutoGeneratedin interface- Sketch
- Returns:
- true if this sketch was auto-generated by SketchMapper.
 
 - 
setAutoGeneratedpublic void setAutoGenerated(boolean autoGenerated) Description copied from interface:SketchSet the autoGenerated property.- Specified by:
- setAutoGeneratedin interface- Sketch
- Parameters:
- autoGenerated- the autogenerated property
 
 
- 
 
-