package scene
import "gioui.org/internal/scene"
Package scene encodes and decodes graphics commands in the format used by the compute renderer.
Index ¶
- Constants
- func DecodeCubic(cmd Command) (from, ctrl0, ctrl1, to f32.Point)
- func DecodeGap(cmd Command) (from, to f32.Point)
- func DecodeLine(cmd Command) (from, to f32.Point)
- func DecodeQuad(cmd Command) (from, ctrl, to f32.Point)
- type Command
- func BeginClip(bbox f32.Rectangle) Command
- func Cubic(start, ctrl0, ctrl1, end f32.Point) Command
- func EndClip(bbox f32.Rectangle) Command
- func FillColor(col color.RGBA) Command
- func FillImage(index int, offset image.Point) Command
- func Gap(start, end f32.Point) Command
- func Line(start, end f32.Point) Command
- func Quad(start, ctrl, end f32.Point) Command
- func SetFillMode(mode FillMode) Command
- func SetLineWidth(width float32) Command
- func Transform(m f32.Affine2D) Command
- func (c Command) Op() Op
- func (c Command) String() string
- type FillMode
- type Op
Constants ¶
const ( FillModeNonzero = 0 FillModeStroke = 1 )
Functions ¶
func DecodeCubic ¶
func DecodeGap ¶
func DecodeLine ¶
func DecodeQuad ¶
Types ¶
type Command ¶
type Command [sceneElemSize / 4]uint32
func BeginClip ¶
func Cubic ¶
func EndClip ¶
func FillColor ¶
func FillImage ¶
func Gap ¶
func Line ¶
func Quad ¶
func SetFillMode ¶
func SetLineWidth ¶
func Transform ¶
func (Command) Op ¶
func (Command) String ¶
type FillMode ¶
type FillMode uint32
FillModes, from setup.h.
type Op ¶
type Op uint32
const ( OpNop Op = iota OpLine OpQuad OpCubic OpFillColor OpLineWidth OpTransform OpBeginClip OpEndClip OpFillImage OpSetFillMode OpGap )
GPU commands from piet/scene.h in package gioui.org/shaders.
Source Files ¶
scene.go
- Version
- v0.8.0 (latest)
- Published
- Jan 14, 2025
- Platform
- linux/amd64
- Imports
- 6 packages
- Last checked
- 12 hours ago –
Tools for package owners.