pattern

package
v0.37.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 20, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Repeat

func Repeat[T any](element texturing.Texture[T], repeat vector2.Int, targetDimensions vector2.Int) texturing.Texture[T]

Types

type Brick

type Brick struct {
	Rows    int
	Columns int

	Offset float64
	Mortar float64

	Round float64
}

type Circle

type Circle[T any] struct {
	Radius float64
	Fill   T

	InnerBorder          T
	InnerBorderThickness float64

	OuterBorder          T
	OuterBorderThickness float64

	Background T
}

func (Circle[T]) Texture

func (c Circle[T]) Texture(dimensions vector2.Int) texturing.Texture[T]

type CircleNode

type CircleNode[T any] struct {
	Dimensions nodes.Output[vector2.Int]
	Radius     nodes.Output[float64]

	Background nodes.Output[T]
	Fill       nodes.Output[T]

	InnerBorder          nodes.Output[T]
	InnerBorderThickness nodes.Output[float64]

	OuterBorder          nodes.Output[T]
	OuterBorderThickness nodes.Output[float64]
}

func (CircleNode[T]) Texture

func (c CircleNode[T]) Texture(out *nodes.StructOutput[texturing.Texture[T]])

type Grid

type Grid[T any] struct {
	HorizontalLines     int
	VerticalLines       int
	BackgroundValue     T
	LineValue           T
	HorizontalLineWidth float64
	VerticalLineWidth   float64
}

func (Grid[T]) Texture

func (c Grid[T]) Texture(dimensions vector2.Int) texturing.Texture[T]

type GridNode

type GridNode[T any] struct {
	HorizontalLines     nodes.Output[int]
	VerticalLines       nodes.Output[int]
	Dimensions          nodes.Output[vector2.Int]
	BackgroundValue     nodes.Output[T]
	LineValue           nodes.Output[T]
	HorizontalLineWidth nodes.Output[float64]
	VerticalLineWidth   nodes.Output[float64]
}

func (GridNode[T]) Texture

func (gnd GridNode[T]) Texture(out *nodes.StructOutput[texturing.Texture[T]])

type RepeatNode

type RepeatNode[T any] struct {
	Dimensions nodes.Output[vector2.Int]
	Repeat     nodes.Output[vector2.Int]
	Element    nodes.Output[texturing.Texture[T]]
}

func (RepeatNode[T]) Texture

func (gnd RepeatNode[T]) Texture(out *nodes.StructOutput[texturing.Texture[T]])

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL