import BasicGLProvider from 'parsegraph-compileprogram/src/BasicGLProvider.ts'
BasicGLProvider
Constructor Summary
Public Constructor | ||
public |
|
Member Summary
Private Members | ||
private |
|
|
private |
_canvas: * |
|
private |
_container: * |
|
private |
|
|
private |
|
|
private |
_gl: * |
|
private |
_id: * |
|
private |
_shaders: {} |
Method Summary
Public Methods | ||
public |
backgroundColor(): Color |
|
public |
|
|
public |
canvas(): HTMLCanvasElement |
|
public |
container(): HTMLElement |
|
public |
|
|
public |
getSize(sizeOut: Rect) |
|
public |
|
|
public |
gl(): WebGLRenderingContext |
|
public |
height(): * |
|
public |
|
|
public |
onContextChanged(isLost: boolean): undefined |
|
public |
Renders this provider's content, resizing the canvas to its container. The default implementation only sets the WebGL's clear color to the background but does not clear the canvas. |
|
public |
|
|
public |
setBackground(color: undefined, args: Array): undefined |
|
public |
setExplicitSize(w: number, h: number): undefined |
|
public |
|
|
public |
|
Public Constructors
public constructor() source
Private Members
private _backgroundColor: * source
private _canvas: * source
private _container: * source
private _explicitHeight: * source
private _explicitWidth: * source
private _gl: * source
private _id: * source
private _shaders: {} source
Public Methods
public container(): HTMLElement source
Return:
HTMLElement | Returns the container that holds the canvas for this graph. |
public getSize(sizeOut: Rect) source
Params:
Name | Type | Attribute | Description |
sizeOut | Rect |
public onContextChanged(isLost: boolean): undefined source
Params:
Name | Type | Attribute | Description |
isLost | boolean |
public render(): boolean source
Renders this provider's content, resizing the canvas to its container.
The default implementation only sets the WebGL's clear color to the background but does not clear the canvas.