buffer

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2024 License: LGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImageBuffer

type ImageBuffer struct {
	// contains filtered or unexported fields
}

func NewImageBuffer

func NewImageBuffer() *ImageBuffer

func NewImageBufferByHandle

func NewImageBufferByHandle(handle unsafe.Pointer) *ImageBuffer

func (*ImageBuffer) Clear

func (i *ImageBuffer) Clear() bool

func (*ImageBuffer) Destroy

func (i *ImageBuffer) Destroy()

func (*ImageBuffer) GetByEncoded

func (i *ImageBuffer) GetByEncoded() (image.Image, error)

GetByEncoded retrieves the decoded image from the buffer. It returns the decoded image and an error if the operation was unsuccessful.

func (*ImageBuffer) GetByRawData

func (i *ImageBuffer) GetByRawData() (image.Image, error)

GetByRawData retrieves the image from raw data stored in the buffer.

func (*ImageBuffer) Handle

func (i *ImageBuffer) Handle() unsafe.Pointer

func (*ImageBuffer) IsEmpty

func (i *ImageBuffer) IsEmpty() bool

func (*ImageBuffer) SetEncoded

func (i *ImageBuffer) SetEncoded(img image.Image) error

SetEncoded encodes the given image and sets it in the buffer. It takes an image.Image as input and returns an error if the operation was unsuccessful.

func (*ImageBuffer) SetRawData

func (i *ImageBuffer) SetRawData(img image.Image) error

SetRawData converts an image.Image to raw data and sets it in the buffer.

type ImageListBuffer

type ImageListBuffer struct {
	// contains filtered or unexported fields
}

func NewImageListBuffer

func NewImageListBuffer() *ImageListBuffer

func NewImageListBufferByHandle

func NewImageListBufferByHandle(handle unsafe.Pointer) *ImageListBuffer

func (*ImageListBuffer) Append

func (il *ImageListBuffer) Append(value ImageBuffer) bool

func (*ImageListBuffer) Clear

func (il *ImageListBuffer) Clear() bool

func (*ImageListBuffer) Destroy

func (il *ImageListBuffer) Destroy()

func (*ImageListBuffer) Get

func (il *ImageListBuffer) Get(index uint64) (image.Image, error)

func (*ImageListBuffer) GetAll

func (il *ImageListBuffer) GetAll() ([]image.Image, error)

func (*ImageListBuffer) Handle

func (il *ImageListBuffer) Handle() unsafe.Pointer

func (*ImageListBuffer) IsEmpty

func (il *ImageListBuffer) IsEmpty() bool

func (*ImageListBuffer) Remove

func (il *ImageListBuffer) Remove(index uint64) bool

func (*ImageListBuffer) Size

func (il *ImageListBuffer) Size() uint64

type Rect

type Rect [4]int32

func (*Rect) GetH

func (r *Rect) GetH() int32

func (*Rect) GetW

func (r *Rect) GetW() int32

func (*Rect) GetX

func (r *Rect) GetX() int32

func (*Rect) GetY

func (r *Rect) GetY() int32

func (*Rect) SetH

func (r *Rect) SetH(value int32)

func (*Rect) SetW

func (r *Rect) SetW(value int32)

func (*Rect) SetX

func (r *Rect) SetX(value int32)

func (*Rect) SetY

func (r *Rect) SetY(value int32)

type RectBuffer

type RectBuffer struct {
	// contains filtered or unexported fields
}

func NewRectBuffer

func NewRectBuffer() *RectBuffer

func NewRectBufferByHandle

func NewRectBufferByHandle(handle unsafe.Pointer) *RectBuffer

func (*RectBuffer) Destroy

func (r *RectBuffer) Destroy()

func (*RectBuffer) Get

func (r *RectBuffer) Get() Rect

func (*RectBuffer) GetH

func (r *RectBuffer) GetH() int32

func (*RectBuffer) GetW

func (r *RectBuffer) GetW() int32

func (*RectBuffer) GetX

func (r *RectBuffer) GetX() int32

func (*RectBuffer) GetY

func (r *RectBuffer) GetY() int32

func (*RectBuffer) Handle

func (r *RectBuffer) Handle() unsafe.Pointer

func (*RectBuffer) Set

func (r *RectBuffer) Set(rect Rect) bool

func (*RectBuffer) SetH

func (r *RectBuffer) SetH(value int32) bool

func (*RectBuffer) SetW

func (r *RectBuffer) SetW(value int32) bool

func (*RectBuffer) SetX

func (r *RectBuffer) SetX(value int32) bool

func (*RectBuffer) SetY

func (r *RectBuffer) SetY(value int32) bool

type StringBuffer

type StringBuffer struct {
	// contains filtered or unexported fields
}

func NewStringBuffer

func NewStringBuffer() *StringBuffer

func NewStringBufferByHandle

func NewStringBufferByHandle(handle unsafe.Pointer) *StringBuffer

func (*StringBuffer) Clear

func (s *StringBuffer) Clear() bool

func (*StringBuffer) Destroy

func (s *StringBuffer) Destroy()

func (*StringBuffer) Get

func (s *StringBuffer) Get() string

func (*StringBuffer) Handle

func (s *StringBuffer) Handle() unsafe.Pointer

func (*StringBuffer) IsEmpty

func (s *StringBuffer) IsEmpty() bool

func (*StringBuffer) Set

func (s *StringBuffer) Set(str string) bool

func (*StringBuffer) SetWithSize

func (s *StringBuffer) SetWithSize(str string, size uint64) bool

func (*StringBuffer) Size

func (s *StringBuffer) Size() uint64

type StringListBuffer

type StringListBuffer struct {
	// contains filtered or unexported fields
}

func NewStringListBuffer

func NewStringListBuffer() *StringListBuffer

func NewStringListBufferByHandle

func NewStringListBufferByHandle(handle unsafe.Pointer) *StringListBuffer

func (*StringListBuffer) Append

func (sl *StringListBuffer) Append(value StringBuffer) bool

func (*StringListBuffer) Clear

func (sl *StringListBuffer) Clear() bool

func (*StringListBuffer) Destroy

func (sl *StringListBuffer) Destroy()

func (*StringListBuffer) Get

func (sl *StringListBuffer) Get(index uint64) string

func (*StringListBuffer) GetAll

func (sl *StringListBuffer) GetAll() []string

func (*StringListBuffer) IsEmpty

func (sl *StringListBuffer) IsEmpty() bool

func (*StringListBuffer) Remove

func (sl *StringListBuffer) Remove(index uint64) bool

func (*StringListBuffer) Size

func (sl *StringListBuffer) Size() uint64

Jump to

Keyboard shortcuts

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