floatimage

package
v0.0.0-...-cc5a67f Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2024 License: CC0-1.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FloatNRGBA

type FloatNRGBA struct {
	// Pix holds the image's pixels, in R, G, B, A order. The pixel at
	// (x, y) starts at Pix[(y-Rect.Min.Y)*Stride + (x-Rect.Min.X)*4].
	Pix []float64
	// Stride is the Pix stride (in bytes) between vertically adjacent pixels.
	Stride int
	// Rect is the image's bounds.
	Rect image.Rectangle
}

FloatNRGBA represents an image made up of FloatNRGBA colour information.

func NewFloatNRGBA

func NewFloatNRGBA(r image.Rectangle) *FloatNRGBA

NewFloatNRGBA returns a new FloatNRGBAImage image with the given bounds.

func (*FloatNRGBA) At

func (f *FloatNRGBA) At(x, y int) color.Color

func (*FloatNRGBA) Bounds

func (f *FloatNRGBA) Bounds() image.Rectangle

func (*FloatNRGBA) ColorModel

func (f *FloatNRGBA) ColorModel() color.Model

func (*FloatNRGBA) FloatNRGBAAt

func (f *FloatNRGBA) FloatNRGBAAt(x, y int) colour.FloatNRGBA

func (*FloatNRGBA) PixOffset

func (f *FloatNRGBA) PixOffset(x, y int) int

PixOffset returns the index of the first element of Pix that corresponds to the pixel at (x, y).

func (*FloatNRGBA) Set

func (f *FloatNRGBA) Set(x, y int, c color.Color)

func (*FloatNRGBA) ToHDR

func (f *FloatNRGBA) ToHDR() (hdr.Image, error)

Jump to

Keyboard shortcuts

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