public class Canvas3d
extends com.google.gwt.user.client.ui.FocusWidget
| Constructor and Description |
|---|
Canvas3d(Canvas3dAttributes attribs)
Initialize a canvas3d of the given size.
|
| Modifier and Type | Method and Description |
|---|---|
com.google.gwt.event.shared.HandlerRegistration |
addWebGLContextLostEventListener(Context3dLostHandler handler) |
com.google.gwt.dom.client.CanvasElement |
getCanvas()
Gets the canvas element.
|
WebGLRenderingContext |
getGL()
Gets the WebGL context.
|
int |
getHeight()
Gets the height of the canvas3d.
|
int |
getWidth()
Gets the width of the canvas3d.
|
void |
setHeight(int height)
Sets the height of the canvas3d.
|
void |
setSize(int width,
int height)
Resizes the canvas3d.
|
void |
setWidth(int width)
Sets the width of the canvas3d.
|
addBlurHandler, addClickHandler, addClickListener, addDoubleClickHandler, addDragEndHandler, addDragEnterHandler, addDragHandler, addDragLeaveHandler, addDragOverHandler, addDragStartHandler, addDropHandler, addFocusHandler, addFocusListener, addGestureChangeHandler, addGestureEndHandler, addGestureStartHandler, addKeyboardListener, addKeyDownHandler, addKeyPressHandler, addKeyUpHandler, addMouseDownHandler, addMouseListener, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseUpHandler, addMouseWheelHandler, addMouseWheelListener, addTouchCancelHandler, addTouchEndHandler, addTouchMoveHandler, addTouchStartHandler, getTabIndex, isEnabled, removeClickListener, removeFocusListener, removeKeyboardListener, removeMouseListener, removeMouseWheelListener, setAccessKey, setEnabled, setFocus, setTabIndexaddAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, fireEvent, getLayoutData, getParent, isAttached, onBrowserEvent, removeFromParent, setLayoutData, sinkEvents, unsinkEventsaddStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleName, getStylePrimaryName, getTitle, isVisible, isVisible, removeStyleDependentName, removeStyleName, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toStringpublic Canvas3d(Canvas3dAttributes attribs) throws java.lang.Exception
attribs - GL
Canvas attributes, represented in Canvas3dAttributes.Canvas3dExceptionjava.lang.Exceptionpublic int getWidth()
public int getHeight()
public void setSize(int width,
int height)
width - the new width of the canvas3d.height - the new height of the canvas3d.public void setWidth(int width)
width - the new width of the canvas3d.public void setHeight(int height)
height - the new height of the canvas3d.public com.google.gwt.dom.client.CanvasElement getCanvas()
public WebGLRenderingContext getGL()
public com.google.gwt.event.shared.HandlerRegistration addWebGLContextLostEventListener(Context3dLostHandler handler)