phz

package
v1.2.13 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package ctb handle input and output of Chitubox DLP/LCD printables

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Formatter

type Formatter struct {
	*pflag.FlagSet

	EncryptionSeed uint32
}

func NewFormatter

func NewFormatter(suffix string) (pf *Formatter)

func (*Formatter) Decode

func (pf *Formatter) Decode(file uv3dp.Reader, filesize int64) (printable uv3dp.Printable, err error)

func (*Formatter) Encode

func (pf *Formatter) Encode(writer uv3dp.Writer, printable uv3dp.Printable) (err error)

Save a uv3dp.Printable in CBD DLP format

type Keyring

type Keyring struct {
	Init uint32
	Key  uint32
	// contains filtered or unexported fields
}

func NewKeyring

func NewKeyring(seed uint32, slice uint32) (kr *Keyring)

Key encoding provided by: https://github.com/cbiffle/catibo/blob/master/doc/phz.adoc

func (*Keyring) Next

func (kr *Keyring) Next() (k byte)

func (*Keyring) Read

func (kr *Keyring) Read(buff []byte) (size int, err error)

type Print

type Print struct {
	uv3dp.Print
	// contains filtered or unexported fields
}

func (*Print) LayerExposure

func (phz *Print) LayerExposure(index int) (exposure uv3dp.Exposure)

func (*Print) LayerImage

func (phz *Print) LayerImage(index int) (layerImage *image.Gray)

Layer gets a layer - we decode from the RLE on-the fly

func (*Print) LayerZ

func (phz *Print) LayerZ(index int) (z float32)

Jump to

Keyboard shortcuts

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