rend2img

package
v0.0.0-...-f9d76ff Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DrawCompositePoints

func DrawCompositePoints(inpVec [][]types.Vector2d, col [4]byte) (*image.RGBA, error)

DrawCompositePoints takes a composite shape and draws it.

func DrawFillCompositePoints

func DrawFillCompositePoints(inpVec [][]types.Vector2d, col [4]byte) (*image.RGBA, error)

DrawFillCompositePoints takes a composite and draws a filled one

func DrawFillCompositeShape

func DrawFillCompositeShape(shape types.RenderableComposite, col [4]byte) (*image.RGBA, error)

DrawFillCompositeShape takes a renderable shape and draws a filled version

func DrawPoints

func DrawPoints(inp []types.Vector2d, col [4]byte) *image.RGBA

DrawPoints draws the points provided as an image.

func FillShape

func FillShape(img *image.RGBA, col [4]byte)

FillShape uses even-odd rule to fill a space within colored points. It screws up on shapes with insets, but technically they're no longer One shape so that is expected behavior.

func ScanLineFill

func ScanLineFill(img *image.RGBA, startX int, endX int, y int, col [4]byte)

ScanLineFill assumes X and Y are valid and does some kind of messy pointer manipulations in order to reduce the amount of work required to fill the image.

Types

This section is empty.

Directories

Path Synopsis
testapps

Jump to

Keyboard shortcuts

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