Package org.openrndr.draw

Types

Link copied to clipboard
expect interface ArrayCubemap

Array of Cubemap, all with the same ColorType, ColorFormat and other properties. Typically, used for efficient reflection probes, lighting and shadowing systems. This is a common interface to be implemented in various target languages.

actual interface ArrayCubemap
actual interface ArrayCubemap
Link copied to clipboard
class ArrayCubemapAttachment(    val index: Int,     val name: String?,     val arrayCubemap: ArrayCubemap,     val side: CubemapSide,     val layer: Int,     val level: Int) : ColorAttachment
Link copied to clipboard
class ArrayCubemapImageBinding(    val arrayCubemap: ArrayCubemap,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
expect abstract class ArrayTexture
actual abstract class ArrayTexture
actual abstract class ArrayTexture
Link copied to clipboard
class ArrayTextureAttachment(    val index: Int,     val name: String?,     val arrayTexture: ArrayTexture,     val layer: Int,     val level: Int) : ColorAttachment
Link copied to clipboard
class ArrayTextureImageBinding(    val arrayTexture: ArrayTexture,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
class ArrayTextureLayerImageBinding(    val arrayTexture: ArrayTexture,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
interface AtomicCounterBuffer
Link copied to clipboard
open class BatchBuilder(val drawer: Drawer)
Link copied to clipboard
enum BlendMode : Enum<BlendMode>

Used for controlling how pixels are blended together. The different modes can be used to simulate different kinds of effects like transparency, adding light, subtracting color and others.

Link copied to clipboard
enum BufferMemberType : Enum<BufferMemberType>
Link copied to clipboard
sealed class BufferMultisample

Buffer multisample options

Link copied to clipboard
expect abstract class BufferTexture
actual abstract class BufferTexture
actual abstract class BufferTexture
Link copied to clipboard
enum BufferTextureFileFormat : Enum<BufferTextureFileFormat>
Link copied to clipboard
class BufferTextureImageBinding(val bufferTexture: BufferTexture, imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
expect abstract class BufferTextureShadow
actual abstract class BufferTextureShadow
actual abstract class BufferTextureShadow
Link copied to clipboard
expect abstract class BufferWriter
actual abstract class BufferWriter
actual abstract class BufferWriter
Link copied to clipboard
expect interface BufferWriterStd430
actual interface BufferWriterStd430
actual interface BufferWriterStd430
Link copied to clipboard
class ChannelMask(    val red: Boolean,     val green: Boolean,     val blue: Boolean,     val alpha: Boolean)
Link copied to clipboard
data class CharacterPair(val left: Char, val right: Char)
Link copied to clipboard
class CircleBatch(val geometry: VertexBuffer, val drawStyle: VertexBuffer)

Stored circle batch

Link copied to clipboard
class CircleBatchBuilder(val drawer: Drawer) : BatchBuilder

Builder for stored circle batches

Link copied to clipboard
sealed class ColorAttachment

Color attachment for RenderTarget.

Link copied to clipboard
expect abstract class ColorBuffer
actual abstract class ColorBuffer
actual abstract class ColorBuffer

representation for simple images stored on GPU memory

Link copied to clipboard
class ColorBufferAttachment(    val index: Int,     val name: String?,     val colorBuffer: ColorBuffer,     val level: Int) : ColorAttachment
Link copied to clipboard
class ColorBufferImageBinding(    val colorBuffer: ColorBuffer,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
data class ColorBufferProxy(    val url: String,     val loader: ColorBufferLoader,     val persistent: Boolean)
Link copied to clipboard
interface ColorBufferShadow
Link copied to clipboard
enum ColorFormat : Enum<ColorFormat>

Color format enumeration

Link copied to clipboard
enum ColorSampling : Enum<ColorSampling>

Color sampling enumeration

Link copied to clipboard
enum ColorType : Enum<ColorType>

Color type enumeration

Link copied to clipboard
interface ComputeShader : ShaderImageBindings
Link copied to clipboard
expect interface Cubemap
actual interface Cubemap
actual interface Cubemap
Link copied to clipboard
class CubemapAttachment(    val index: Int,     val name: String?,     val cubemap: Cubemap,     val side: CubemapSide,     val level: Int) : ColorAttachment
Link copied to clipboard
class CubemapImageBinding(    val cubemap: Cubemap,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
class CubemapLayerImageBinding(    val cubemap: Cubemap,     val side: CubemapSide,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
enum CubemapSide : Enum<CubemapSide>
Link copied to clipboard
enum CullTestPass : Enum<CullTestPass>

Cull test pass condition enumeration

Link copied to clipboard
class Cursor(var x: Double = 0.0, var y: Double = 0.0)
Link copied to clipboard
interface DepthBuffer
Link copied to clipboard
enum DepthFormat : Enum<DepthFormat>

Depth format enumeration

Link copied to clipboard
enum DepthTestPass : Enum<DepthTestPass>

Depth test pass condition enumeration

Link copied to clipboard
data class DrawContext(    val model: Matrix44,     val view: Matrix44,     val projection: Matrix44,     val width: Int,     val height: Int,     val contentScale: Double,     val modelViewScalingFactor: Double)
Link copied to clipboard
class Drawer(val driver: Driver)

The Drawer

Link copied to clipboard
enum DrawPrimitive : Enum<DrawPrimitive>

Draw primitive type enumeration

Link copied to clipboard
enum DrawQuality : Enum<DrawQuality>

Specifies if to optimize drawing for quality or performance.

Link copied to clipboard
data class DrawStyle(    var clip: Rectangle? = null,     var fill: ColorRGBa? = ColorRGBa.WHITE,     var stroke: ColorRGBa? = ColorRGBa.BLACK,     var lineCap: LineCap = LineCap.BUTT,     var lineJoin: LineJoin = LineJoin.MITER,     var strokeWeight: Double = 1.0,     var smooth: Boolean = true,     var miterLimit: Double = 4.0,     var quality: DrawQuality = DrawQuality.QUALITY,     var depthTestPass: DepthTestPass = DepthTestPass.ALWAYS,     var depthWrite: Boolean = false,     var blendMode: BlendMode = BlendMode.OVER,     var cullTestPass: CullTestPass = CullTestPass.ALWAYS,     var channelWriteMask: ChannelMask = ChannelMask(red = true, green = true, blue = true, alpha = true),     var alphaToCoverage: Boolean = false,     var shadeStyle: ShadeStyle? = null,     var fontMap: FontMap? = null,     var kerning: KernMode = KernMode.METRIC,     var textSetting: TextSettingMode = TextSettingMode.PIXEL,     var stencil: StencilStyle = StencilStyle(),     var frontStencil: StencilStyle = stencil,     var backStencil: StencilStyle = stencil,     var colorMatrix: Matrix55 = Matrix55.IDENTITY)

A data class that controls the look of drawing operations including stroke and fill color, stroke weight and more.

Link copied to clipboard
interface DrawThread
Link copied to clipboard
open class Filter(shader: Shader? = null, watcher: ShaderWatcher? = null)

Filter base class. Renders "full-screen" quads.

Link copied to clipboard
class FontImageMap(    val texture: ColorBuffer,     val map: Map<Char, IntRectangle>,     val glyphMetrics: Map<Char, GlyphMetrics>,     val size: Double,     val contentScale: Double,     val ascenderLength: Double,     val descenderLength: Double,     val height: Double,     val leading: Double,     val name: String) : FontMap

A type of FontMap which keeps characters pre-rendered in a ColorBuffer texture at a specific font size.

Link copied to clipboard
data class FontImageMapDescriptor(    val fontUrl: String,     val size: Double,     val alphabet: Set<Char>,     val contentScale: Double)
Link copied to clipboard
abstract class FontMap

Holds properties common to both vector-based and image-based FontMaps.

Link copied to clipboard
abstract class FontVectorMap : FontMap

A type of FontMap which keeps characters stored as vector data. Good for displaying very large text and for displaying text at different scales, but in general less performant than FontImageMap because it is not pre-rendered.

Link copied to clipboard
data class GlyphMetrics(    val advanceWidth: Double,     val leftSideBearing: Double,     val xBitmapShift: Double,     val yBitmapShift: Double)
Link copied to clipboard
enum ImageAccess : Enum<ImageAccess>
Link copied to clipboard
sealed class ImageBinding
Link copied to clipboard
enum ImageFileFormat : Enum<ImageFileFormat>

File format used while saving to file

Link copied to clipboard
expect interface IndexBuffer
actual interface IndexBuffer
actual interface IndexBuffer
Link copied to clipboard
enum IndexType : Enum<IndexType>
Link copied to clipboard
enum KernMode : Enum<KernMode>
Link copied to clipboard
class LayeredArrayCubemapAttachment(    val index: Int,     val name: String?,     val arrayCubemap: ArrayCubemap,     val level: Int) : ColorAttachment
Link copied to clipboard
class LayeredArrayTextureAttachment(    val index: Int,     val name: String?,     val arrayTexture: ArrayTexture,     val level: Int) : ColorAttachment
Link copied to clipboard
class LayeredCubemapAttachment(    val index: Int,     val name: String?,     val cubemap: Cubemap,     val level: Int) : ColorAttachment
Link copied to clipboard
class LayeredVolumeTextureAttachment(    val index: Int,     val name: String?,     val volumeTexture: VolumeTexture,     val level: Int) : ColorAttachment
Link copied to clipboard
enum LineCap : Enum<LineCap>

Line cap enumeration

Link copied to clipboard
enum LineJoin : Enum<LineJoin>

Line join enumeration

Link copied to clipboard
enum MagnifyingFilter : Enum<MagnifyingFilter>

Texture filters for magnification

Link copied to clipboard
enum MinifyingFilter : Enum<MinifyingFilter>

Texture filters used for minification

Link copied to clipboard
class ObservableHashmap<K, V>(val b: MutableMap<K, V>, val onChange: () -> Unit) : MutableMap<K, V>
Link copied to clipboard
class PointBatch(val geometry: VertexBuffer, val drawStyle: VertexBuffer)
Link copied to clipboard
class PointBatchBuilder(val drawer: Drawer) : BatchBuilder
Link copied to clipboard
class RectangleBatch(val geometry: VertexBuffer, val drawStyle: VertexBuffer)
Link copied to clipboard
class RectangleBatchBuilder(val drawer: Drawer) : BatchBuilder
Link copied to clipboard
interface RenderTarget
Link copied to clipboard
class RenderTargetBuilder(renderTarget: RenderTarget)
Link copied to clipboard
class RenderToken(    val token: String,     val x: Double,     val y: Double,     val width: Double,     val tracking: Double)
Link copied to clipboard
class ResizableColorBuffer(    width: Int,     height: Int,     contentScale: Double = 1.0,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     multisample: BufferMultisample = BufferMultisample.Disabled,     levels: Int = 1,     session: Session? = Session.active)
Link copied to clipboard
class ResizableRenderTarget(    width: Int,     height: Int,     contentScale: Double = 1.0,     multisample: BufferMultisample = BufferMultisample.Disabled,     session: Session?,     val builder: RenderTargetBuilder.() -> Unit)
Link copied to clipboard
class Session(val parent: Session?)

Session

Link copied to clipboard
class SessionStatistics(    val renderTargets: Int,     val colorBuffers: Int,     val depthBuffers: Int,     val bufferTextures: Int,     val indexBuffers: Int,     val vertexBuffers: Int,     val shaders: Int,     val cubemaps: Int,     val arrayTextures: Int,     val computeShaders: Int,     val atomicCounterBuffers: Int,     val arrayCubemaps: Int,     val shaderStorageBuffers: Int)

Session statistics

Link copied to clipboard
interface Shader : ShaderImageBindings
Link copied to clipboard
interface ShaderImageBindings
Link copied to clipboard
expect interface ShaderStorageBuffer
actual interface ShaderStorageBuffer
actual interface ShaderStorageBuffer
Link copied to clipboard
interface ShaderStorageBufferShadow
Link copied to clipboard
interface ShaderStorageElement
Link copied to clipboard
class ShaderStorageFormat
Link copied to clipboard
data class ShaderStorageMember(    val member: String,     val type: BufferMemberType,     val arraySize: Int = 1,     var offset: Int = 0,     var padding: Int = 0) : ShaderStorageElement
Link copied to clipboard
data class ShaderStorageStruct(    val structName: String,     val member: String,     val members: List<ShaderStorageMember>,     val arraySize: Int = 1,     var offset: Int = 0) : ShaderStorageElement
Link copied to clipboard
enum ShaderType : Enum<ShaderType>
Link copied to clipboard
expect class ShaderWatcher
actual class ShaderWatcher
actual class ShaderWatcher
Link copied to clipboard
class ShaderWatcherBuilder
Link copied to clipboard
data class ShadeStructure(    var uniforms: String? = null,     var attributes: String? = null,     var buffers: String? = null,     var vertexTransform: String? = null,     var geometryTransform: String? = null,     var fragmentTransform: String? = null,     var vertexPreamble: String? = null,     var geometryPreamble: String? = null,     var fragmentPreamble: String? = null,     var outputs: String? = null,     var varyingOut: String? = null,     var varyingIn: String? = null,     var varyingBridge: String? = null,     var suppressDefaultOutput: Boolean = false)
Link copied to clipboard
open class ShadeStyle : ShadeStyleParameters
Link copied to clipboard
class ShadeStyleFilter(val shadeStyle: ShadeStyle) : Filter, ShadeStyleParameters

A Filter that uses the ShadeStyle interface and language

Link copied to clipboard
expect class ShadeStyleGLSL

A collection of granules, or template functions for writing stylable shaders in GLSL. ShadeStyleGLSL is used in OPENRNDR's shader generators but is exposed to the user such that they too can write shader generators.

actual class ShadeStyleGLSL

A collection of granules, or template functions for writing stylable shaders in GLSL. ShadeStyleGLSL is used in OPENRNDR's shader generators but is exposed to the user such that they too can write shader generators.

actual class ShadeStyleGLSL

A collection of granules, or template functions for writing stylable shaders in GLSL. ShadeStyleGLSL is used in OPENRNDR's shader generators but is exposed to the user such that they too can write shader generators.

Link copied to clipboard
abstract class ShadeStyleManager(val name: String)
Link copied to clipboard
data class ShadeStyleOutput(    val attachment: Int,     val format: ColorFormat = ColorFormat.RGBa,     val type: ColorType = ColorType.FLOAT32)
Link copied to clipboard
interface ShadeStyleParameters
Link copied to clipboard
enum StencilOperation : Enum<StencilOperation>
Link copied to clipboard
class StencilStyle
Link copied to clipboard
enum StencilTest : Enum<StencilTest>
Link copied to clipboard
enum TextSettingMode : Enum<TextSettingMode>
Link copied to clipboard
enum TransformTarget : Enum<TransformTarget>
Link copied to clipboard
interface UniformBlock
Link copied to clipboard
data class UniformBlockLayout(val sizeInBytes: Int, val entries: Map<String, UniformDescription>)
Link copied to clipboard
data class UniformDescription(    val name: String,     val type: UniformType,     val size: Int,     val offset: Int,     val stride: Int)
Link copied to clipboard
enum UniformType : Enum<UniformType>
Link copied to clipboard
expect abstract class VertexBuffer
actual abstract class VertexBuffer
actual abstract class VertexBuffer
Link copied to clipboard
interface VertexBufferShadow
Link copied to clipboard
data class VertexElement(    val attribute: String,     val offset: Int,     val type: VertexElementType,     val arraySize: Int)
Link copied to clipboard
enum VertexElementType : Enum<VertexElementType>

Vertex element type enumeration

Link copied to clipboard
class VertexFormat

VertexBuffer Layout describes how data is organized in the VertexBuffer

Link copied to clipboard
expect interface VolumeTexture
actual interface VolumeTexture
actual interface VolumeTexture
Link copied to clipboard
class VolumeTextureAttachment(    val index: Int,     val name: String?,     val volumeTexture: VolumeTexture,     val layer: Int,     val level: Int) : ColorAttachment
Link copied to clipboard
class VolumeTextureImageBinding(    val volumeTexture: VolumeTexture,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
class VolumeTextureLayerImageBinding(    val volumeTexture: VolumeTexture,     val layer: Int,     val level: Int,     imageAccess: ImageAccess) : ImageBinding
Link copied to clipboard
enum WrapMode : Enum<WrapMode>

Texture wrapping mode

Link copied to clipboard
class Writer(val drawerRef: Drawer?)
Link copied to clipboard
class WriteStyle

Functions

Link copied to clipboard
fun arrayCubemap(    width: Int,     layers: Int,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     levels: Int = 1,     session: Session = Session.active): ArrayCubemap

Creates an array cubemap

Link copied to clipboard
fun arrayTexture(    width: Int,     height: Int,     layers: Int,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     levels: Int = 1,     session: Session = Session.active): ArrayTexture

Creates an array texture

Link copied to clipboard
fun bufferTexture(    elementCount: Int,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.FLOAT32,     session: Session? = Session.active): BufferTexture

create a BufferTexture

Link copied to clipboard
fun Drawer.circleBatch(build: CircleBatchBuilder.() -> Unit): CircleBatch

Create a stored batch of circles

Link copied to clipboard
fun codeFromStream(stream: InputStream): String
Link copied to clipboard
fun codeFromURL(url: URL): String
fun codeFromURL(url: String): String
Link copied to clipboard
fun colorBuffer(    width: Int,     height: Int,     contentScale: Double = 1.0,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     multisample: BufferMultisample = BufferMultisample.Disabled,     levels: Int = 1,     session: Session? = Session.active): ColorBuffer

create a ColorBuffer

Link copied to clipboard
fun constant(color: ColorRGBa, ignoreAlpha: Boolean = true): Matrix55
Link copied to clipboard
fun ColorBuffer.createEquivalent(    width: Int = this.width,     height: Int = this.height,     contentScale: Double = this.contentScale,     format: ColorFormat = this.format,     type: ColorType = this.type,     multisample: BufferMultisample = this.multisample,     levels: Int = this.levels): ColorBuffer

create an equivalent ColorBuffer, with the option to override attributes

Link copied to clipboard
fun cubemap(    width: Int,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     levels: Int = 1,     session: Session? = Session.active): Cubemap
Link copied to clipboard
fun depthBuffer(    width: Int,     height: Int,     format: DepthFormat = DepthFormat.DEPTH24_STENCIL8,     multisample: BufferMultisample): DepthBuffer
Link copied to clipboard
fun drawThread(): DrawThread

creates and starts a DrawThread

Link copied to clipboard
fun filterShaderFromCode(    fragmentShaderCode: String,     name: String,     includeShaderConfiguration: Boolean = true): Shader
Link copied to clipboard
fun filterShaderFromUrl(url: String): Shader
Link copied to clipboard
fun filterWatcherFromUrl(url: String): ShaderWatcher
Link copied to clipboard
fun grayscale(    r: Double = 0.33,     g: Double = 0.33,     b: Double = 0.33): Matrix55
Link copied to clipboard
fun BufferTexture.imageBinding(imageAccess: ImageAccess): BufferTextureImageBinding
fun ArrayCubemap.imageBinding(level: Int = 0, imageAccess: ImageAccess): ArrayCubemapImageBinding
fun ArrayTexture.imageBinding(level: Int = 0, imageAccess: ImageAccess): ArrayTextureImageBinding
fun ColorBuffer.imageBinding(level: Int = 0, imageAccess: ImageAccess): ColorBufferImageBinding
fun Cubemap.imageBinding(level: Int = 0, imageAccess: ImageAccess): CubemapImageBinding
fun VolumeTexture.imageBinding(level: Int = 0, imageAccess: ImageAccess): VolumeTextureImageBinding
Link copied to clipboard
fun imageProxy(    file: File,     queue: Boolean = true,     persistent: Boolean = false): ColorBufferProxy
fun imageProxy(    fileOrUrl: String,     queue: Boolean = true,     persistent: Boolean = false): ColorBufferProxy
Link copied to clipboard
fun indexBuffer(elementCount: Int, type: IndexType): IndexBuffer
Link copied to clipboard
fun ColorBuffer.isEquivalentTo(    other: ColorBuffer,     ignoreWidth: Boolean = false,     ignoreHeight: Boolean = false,     ignoreContentScale: Boolean = false,     ignoreFormat: Boolean = false,     ignoreType: Boolean = false,     ignoreMultisample: Boolean = false,     ignoreLevels: Boolean = false): Boolean

check if this ColorBuffer is equivalent to other

Link copied to clipboard
fun Drawer.isolated(function: Drawer.() -> Unit)

Pushes style, view- and projection matrix, calls function and pops.

Link copied to clipboard
fun Drawer.isolatedWithTarget(target: RenderTarget, function: Drawer.() -> Unit)

Pushes style, view- and projection matrix, sets render target, calls function and pops,

Link copied to clipboard
fun DrawThread.launch(    context: CoroutineContext = this.dispatcher,     start: CoroutineStart = CoroutineStart.DEFAULT,     block: suspend CoroutineScope.() -> Unit): Job

launches a coroutine on the DrawThread

Link copied to clipboard
fun loadBufferTexture(    file: File,     formatHint: BufferTextureFileFormat? = BufferTextureFileFormat.ORB,     session: Session? = Session.active): BufferTexture

load a buffer texture from a file

fun loadBufferTexture(    url: URL,     formatHint: BufferTextureFileFormat? = BufferTextureFileFormat.ORB,     session: Session? = Session.active): BufferTexture

load a BufferTexture from a url

fun loadBufferTexture(    fileOrUrl: String,     formatHint: BufferTextureFileFormat? = BufferTextureFileFormat.ORB,     session: Session? = Session.active): BufferTexture

load a buffer texture from file or url

Link copied to clipboard
fun loadCubemap(    fileOrUrl: String,     formatHint: ImageFileFormat?,     session: Session? = Session.active): Cubemap
Link copied to clipboard
fun loadFont(    fileOrUrl: String,     size: Double,     characterSet: Set<Char> = defaultFontmapCharacterSet,     contentScale: Double = 1.0): FontImageMap
Link copied to clipboard
expect fun loadImage(    fileOrUrl: String,     formatHint: ImageFileFormat? = null,     session: Session? = Session.active): ColorBuffer

load an image from a file or url encoded as String, also accepts base64 encoded data urls

actual fun loadImage(    fileOrUrl: String,     formatHint: ImageFileFormat?,     session: Session?): ColorBuffer

load an image from a file or url encoded as String, also accepts base64 encoded data urls

fun loadImage(    file: File,     formatHint: ImageFileFormat? = null,     session: Session? = Session.active): ColorBuffer

load an image from File

fun loadImage(    url: URL,     formatHint: ImageFileFormat?,     session: Session? = Session.active): ColorBuffer

load an image from an url

actual fun loadImage(    fileOrUrl: String,     formatHint: ImageFileFormat?,     session: Session?): ColorBuffer

load an image from a file or url encoded as String, also accepts base64 encoded data urls

Link copied to clipboard
expect suspend fun loadImageSuspend(    fileOrUrl: String,     formatHint: ImageFileFormat? = null,     session: Session? = Session.active): ColorBuffer
actual suspend fun loadImageSuspend(    fileOrUrl: String,     formatHint: ImageFileFormat?,     session: Session?): ColorBuffer
actual suspend fun loadImageSuspend(    fileOrUrl: String,     formatHint: ImageFileFormat?,     session: Session?): ColorBuffer
Link copied to clipboard
fun <T> persistent(builder: () -> T): T

Mark a GPU resource or code that uses GPU resources as persistent

Link copied to clipboard
fun Drawer.pointBatch(build: PointBatchBuilder.() -> Unit): PointBatch

Create a stored batch of points

Link copied to clipboard
fun Drawer.rectangleBatch(build: RectangleBatchBuilder.() -> Unit): RectangleBatch

Create a stored batch of rectangles

Link copied to clipboard
fun renderTarget(    width: Int,     height: Int,     contentScale: Double = 1.0,     multisample: BufferMultisample = BufferMultisample.Disabled,     session: Session? = Session.active,     builder: RenderTargetBuilder.() -> Unit): RenderTarget

build a RenderTarget

Link copied to clipboard
fun resizableColorBuffer(    width: Int,     height: Int,     contentScale: Double = 1.0,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     multisample: BufferMultisample = BufferMultisample.Disabled,     levels: Int = 1,     session: Session? = Session.active): ResizableColorBuffer
Link copied to clipboard
fun resizableRenderTarget(    width: Int,     height: Int,     contentScale: Double,     multisample: BufferMultisample = BufferMultisample.Disabled,     session: Session? = Session.active,     builder: RenderTargetBuilder.() -> Unit): ResizableRenderTarget
Link copied to clipboard
fun session(code: () -> Unit)

Runs code inside a (short-lived) session

Link copied to clipboard
fun shaderStorageBuffer(format: ShaderStorageFormat): ShaderStorageBuffer
Link copied to clipboard
fun shaderStorageFormat(builder: ShaderStorageFormat.() -> Unit): ShaderStorageFormat
Link copied to clipboard
fun shaderWatcher(init: ShaderWatcherBuilder.() -> Unit): ShaderWatcher
Link copied to clipboard
fun shadeStyle(builder: ShadeStyle.() -> Unit): ShadeStyle
Link copied to clipboard
fun tint(color: ColorRGBa): Matrix55
Link copied to clipboard
fun vertexBuffer(    vertexFormat: VertexFormat,     vertexCount: Int,     session: Session? = Session.active): VertexBuffer

VertexBuffer builder function.

Link copied to clipboard
fun vertexFormat(builder: VertexFormat.() -> Unit): VertexFormat
Link copied to clipboard
fun volumeTexture(    width: Int,     height: Int,     depth: Int,     format: ColorFormat = ColorFormat.RGBa,     type: ColorType = ColorType.UINT8,     levels: Int = 1,     session: Session? = Session.active): VolumeTexture
Link copied to clipboard
fun BufferWriter.write(drawStyle: DrawStyle)
Link copied to clipboard
@JvmName(name = "drawerWriter")
fun <T> Drawer.writer(f: Writer.() -> T): T
fun <T> writer(drawer: Drawer, f: Writer.() -> T): T

Properties

Link copied to clipboard
val circleFormat: VertexFormat
Link copied to clipboard
expect val defaultFontMap: FontImageMap?
actual val defaultFontMap: FontImageMap?
actual val defaultFontMap: FontImageMap?
Link copied to clipboard
val defaultFontmapCharacterSet: Set<Char>
Link copied to clipboard
val drawStyleFormat: VertexFormat
Link copied to clipboard
val invert: Matrix55
Link copied to clipboard
val pointFormat: VertexFormat
Link copied to clipboard
val rectangleFormat: VertexFormat
Link copied to clipboard
expect val useContextBlock: Boolean
actual val useContextBlock: Boolean = false
actual val useContextBlock: Boolean = true
Link copied to clipboard
expect val useStyleBlock: Boolean
actual val useStyleBlock: Boolean = false
actual val useStyleBlock: Boolean = true