Documentation ¶
Overview ¶
OpenColorIO bindings - http://opencolorio.org/developers/api/OpenColorIO.html
Example ¶
Usage Example: Compositing plugin that converts from “log” to “lin”
// Arbitrary source of image data // // ColorData is a []float32 containing the pixel values. // Could be in various formats: // R,G,B,R,G,B,... // 3 Channels // R,G,B,A,R,G,B,A,... // 4 Channels // var imageData ColorData = getExampleImage() // Get the global OpenColorIO config // This will auto-initialize (using $OCIO) on first use cfg, err := CurrentConfig() if err != nil { panic(err.Error()) } // Get the processor corresponding to this transform. processor, err := cfg.Processor(ROLE_COMPOSITING_LOG, ROLE_SCENE_LINEAR) if err != nil { panic(err.Error()) } // Wrap the image in a light-weight ImageDesc, // providing the width, height, and number of color channels // that imageData represents. imgDesc := NewPackedImageDesc(imageData, 512, 256, 3) // Apply the color transformation (in place) err = processor.Apply(imgDesc) if err != nil { panic(err.Error()) }
Output:
Index ¶
- Variables
- func ClearAllCaches()
- func SetCurrentConfig(config *Config) error
- func SetLoggingLevel(level LoggingLevelType)
- func Version() string
- func VersionHex() int
- type BitDepth
- type ColorData
- type ColorSpace
- func (c *ColorSpace) BitDepth() BitDepth
- func (c *ColorSpace) Description() string
- func (c *ColorSpace) Destroy()
- func (c *ColorSpace) EditableCopy() *ColorSpace
- func (c *ColorSpace) EqualityGroup() string
- func (c *ColorSpace) Family() string
- func (c *ColorSpace) Name() string
- func (c *ColorSpace) SetBitDepth(bitDepth BitDepth)
- func (c *ColorSpace) SetDescription(description string)
- func (c *ColorSpace) SetEqualityGroup(group string)
- func (c *ColorSpace) SetFamily(family string)
- func (c *ColorSpace) SetName(name string)
- func (c *ColorSpace) String() string
- type Config
- func (c *Config) ActiveDisplays() string
- func (c *Config) ActiveViews() string
- func (c *Config) AddColorSpace(cs *ColorSpace) error
- func (c *Config) AddDisplay(display, view, colorSpace, looks string) error
- func (c *Config) CacheID() (string, error)
- func (c *Config) CacheIDWithContext(context *Context) (string, error)
- func (c *Config) ClearColorSpaces() error
- func (c *Config) ClearDisplays()
- func (c *Config) ColorSpace(name string) (*ColorSpace, error)
- func (c *Config) ColorSpaceNameByIndex(index int) (string, error)
- func (c *Config) CurrentContext() (*Context, error)
- func (c *Config) DefaultDisplay() string
- func (c *Config) DefaultView(display string) string
- func (c *Config) Description() (string, error)
- func (c *Config) Destroy()
- func (c *Config) Display(index int) string
- func (c *Config) DisplayColorSpaceName(display, view string) string
- func (c *Config) DisplayLooks(display, view string) string
- func (c *Config) EditableCopy() *Config
- func (c *Config) HasRole(role string) bool
- func (c *Config) IndexForColorSpace(name string) (int, error)
- func (c *Config) IsStrictParsingEnabled() bool
- func (c *Config) NumColorSpaces() int
- func (c *Config) NumDisplays() int
- func (c *Config) NumRoles() int
- func (c *Config) NumViews(display string) int
- func (c *Config) ParseColorSpaceFromString(str string) (string, error)
- func (c *Config) Processor(args ...interface{}) (*Processor, error)
- func (c *Config) ProcessorCtxTransformDir(ctx *Context, tx Transform, dir TransformDirection) (*Processor, error)
- func (c *Config) ProcessorTransform(tx Transform) (*Processor, error)
- func (c *Config) ProcessorTransformDir(tx Transform, dir TransformDirection) (*Processor, error)
- func (c *Config) RoleName(index int) (string, error)
- func (c *Config) SanityCheck() error
- func (c *Config) SearchPath() (string, error)
- func (c *Config) Serialize() (string, error)
- func (c *Config) SetActiveDisplays(displays string) error
- func (c *Config) SetActiveViews(views string) error
- func (c *Config) SetRole(role, colorSpaceName string) error
- func (c *Config) SetStrictParsingEnabled(enabled bool) error
- func (c *Config) View(display string, index int) string
- func (c *Config) WorkingDir() (string, error)
- type Context
- func (c *Context) CacheID() (string, error)
- func (c *Context) Destroy()
- func (c *Context) EditableCopy() *Context
- func (c *Context) EnvironmentMode() EnvironmentMode
- func (c *Context) LoadEnvironment()
- func (c *Context) ResolveFileLocation(filename string) (string, error)
- func (c *Context) ResolveStringVar(val string) string
- func (c *Context) SearchPath() string
- func (c *Context) SetEnvironmentMode(mode EnvironmentMode)
- func (c *Context) SetSearchPath(path string)
- func (c *Context) SetStringVar(name, value string)
- func (c *Context) SetWorkingDir(dirname string)
- func (c *Context) StringVar(name string) string
- func (c *Context) WorkingDir() string
- type DisplayTransform
- func (tx *DisplayTransform) Destroy()
- func (tx *DisplayTransform) Direction() TransformDirection
- func (tx *DisplayTransform) Display() string
- func (tx *DisplayTransform) EditableCopy() *DisplayTransform
- func (tx *DisplayTransform) InputColorSpace() string
- func (tx *DisplayTransform) LooksOverride() string
- func (tx *DisplayTransform) LooksOverrideEnabled() bool
- func (tx *DisplayTransform) SetDirection(dir TransformDirection)
- func (tx *DisplayTransform) SetDisplay(name string)
- func (tx *DisplayTransform) SetInputColorSpace(cs string)
- func (tx *DisplayTransform) SetLooksOverride(looks string)
- func (tx *DisplayTransform) SetLooksOverrideEnabled(enabled bool)
- func (tx *DisplayTransform) SetView(name string)
- func (tx *DisplayTransform) View() string
- type EnvironmentMode
- type ErrMissingFile
- type ImageDescriptor
- type InterpType
- type LoggingLevelType
- type PackedImageDesc
- type Processor
- type ProcessorMetadata
- func (p *ProcessorMetadata) AddFile(fileName string)
- func (p *ProcessorMetadata) AddLook(lookName string)
- func (p *ProcessorMetadata) Destroy()
- func (p *ProcessorMetadata) File(index int) string
- func (p *ProcessorMetadata) Files() []string
- func (p *ProcessorMetadata) Look(index int) string
- func (p *ProcessorMetadata) NumFiles() int
- func (p *ProcessorMetadata) NumLooks() int
- type Transform
- type TransformDirection
Examples ¶
Constants ¶
This section is empty.
Variables ¶
var ( ROLE_DEFAULT = C.GoString(C.ROLE_DEFAULT) ROLE_REFERENCE = C.GoString(C.ROLE_REFERENCE) ROLE_DATA = C.GoString(C.ROLE_DATA) ROLE_COLOR_PICKING = C.GoString(C.ROLE_COLOR_PICKING) ROLE_SCENE_LINEAR = C.GoString(C.ROLE_SCENE_LINEAR) ROLE_COMPOSITING_LOG = C.GoString(C.ROLE_COMPOSITING_LOG) ROLE_COLOR_TIMING = C.GoString(C.ROLE_COLOR_TIMING) ROLE_TEXTURE_PAINT = C.GoString(C.ROLE_TEXTURE_PAINT) ROLE_MATTE_PAINT = C.GoString(C.ROLE_MATTE_PAINT) )
Functions ¶
func ClearAllCaches ¶
func ClearAllCaches()
OpenColorIO, during normal usage, tends to cache certain information (such as the contents of LUTs on disk, intermediate results, etc.). Calling this function will flush all such information. Under normal usage, this is not necessary, but it can be helpful in particular instances, such as designing OCIO profiles, and wanting to re-read luts without restarting.
func SetCurrentConfig ¶
Set the current configuration. This will then store a copy of the specified config.
func Version ¶
func Version() string
Get the version number for the library, as a dot-delimited string (e.g., “1.0.0”). This is also available at compile time as OCIO_VERSION.
func VersionHex ¶
func VersionHex() int
Get the version number for the library, as a single 4-byte hex number (e.g., 0x01050200 for “1.5.2”), to be used for numeric comparisons. This is also available at compile time as OCIO_VERSION_HEX.
Types ¶
type BitDepth ¶
type BitDepth int
const ( BIT_DEPTH_UNKNOWN BitDepth = C.BIT_DEPTH_UNKNOWN BIT_DEPTH_UINT8 BitDepth = C.BIT_DEPTH_UINT8 BIT_DEPTH_UINT10 BitDepth = C.BIT_DEPTH_UINT10 BIT_DEPTH_UINT12 BitDepth = C.BIT_DEPTH_UINT12 BIT_DEPTH_UINT14 BitDepth = C.BIT_DEPTH_UINT14 BIT_DEPTH_UINT16 BitDepth = C.BIT_DEPTH_UINT16 BIT_DEPTH_UINT32 BitDepth = C.BIT_DEPTH_UINT32 BIT_DEPTH_F16 BitDepth = C.BIT_DEPTH_F16 BIT_DEPTH_F32 BitDepth = C.BIT_DEPTH_F32 )
type ColorData ¶
type ColorData []float32
A ColorData meant to hold floating point pixel data in forms: * RGBRGB... * RGBARGBA...
type ColorSpace ¶
type ColorSpace struct {
// contains filtered or unexported fields
}
The ColorSpace is the state of an image with respect to colorimetry and color encoding. Transforming images between different ColorSpaces is the primary motivation for this library.
While a complete discussion of colorspaces is beyond the scope of documentation, traditional uses would be to have ColorSpaces corresponding to: physical capture devices (known cameras, scanners), and internal ‘convenience’ spaces (such as scene linear, logarithmic).
ColorSpaces are specific to a particular image precision (float32, uint8, etc.), and the set of ColorSpaces that provide equivalent mappings (at different precisions) are referred to as a ‘family’.
func (*ColorSpace) BitDepth ¶
func (c *ColorSpace) BitDepth() BitDepth
func (*ColorSpace) Description ¶
func (c *ColorSpace) Description() string
func (*ColorSpace) Destroy ¶ added in v1.0.2
func (c *ColorSpace) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*ColorSpace) EditableCopy ¶
func (c *ColorSpace) EditableCopy() *ColorSpace
Create a new editable copy of this ColorSpace
func (*ColorSpace) EqualityGroup ¶
func (c *ColorSpace) EqualityGroup() string
Get the ColorSpace group name (used for equality comparisons) This allows no-op transforms between different colorspaces. If an equalityGroup is not defined (an empty string), it will be considered unique (i.e., it will not compare as equal to other ColorSpaces with an empty equality group). This is often, though not always, set to the same value as ‘family’.
func (*ColorSpace) Family ¶
func (c *ColorSpace) Family() string
func (*ColorSpace) Name ¶
func (c *ColorSpace) Name() string
func (*ColorSpace) SetBitDepth ¶
func (c *ColorSpace) SetBitDepth(bitDepth BitDepth)
func (*ColorSpace) SetDescription ¶
func (c *ColorSpace) SetDescription(description string)
func (*ColorSpace) SetEqualityGroup ¶
func (c *ColorSpace) SetEqualityGroup(group string)
func (*ColorSpace) SetFamily ¶
func (c *ColorSpace) SetFamily(family string)
func (*ColorSpace) SetName ¶
func (c *ColorSpace) SetName(name string)
func (*ColorSpace) String ¶
func (c *ColorSpace) String() string
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
A Config defines all the colorspaces available at runtime.
func ConfigCreateFromData ¶
Create a Config from a valid yaml string
func ConfigCreateFromEnv ¶
Create a Config by checking the OCIO environment variable
func ConfigCreateFromFile ¶
Create a Config from an existing yaml Config file
func CurrentConfig ¶
Get the current configuration. If a current config had not yet been set, it will be automatically initialized from the environment.
func (*Config) ActiveDisplays ¶
func (*Config) ActiveViews ¶
func (*Config) AddColorSpace ¶
func (c *Config) AddColorSpace(cs *ColorSpace) error
If another color space is already registered with the same name, this will overwrite it. This stores a copy of the specified color space.
func (*Config) AddDisplay ¶
For the (display,view) combination, specify which colorSpace and look to use. If a look is not desired, then just pass an empty string
func (*Config) CacheID ¶
This will produce a hash of the all colorspace definitions, etc. All external references, such as files used in FileTransforms, etc., will be incorporated into the cacheID. While the contents of the files are not read, the file system is queried for relavent information (mtime, inode) so that the Config’s cacheID will change when the underlying luts are updated.
The current Context will be used.
func (*Config) CacheIDWithContext ¶
This will produce a hash of the all colorspace definitions, etc. All external references, such as files used in FileTransforms, etc., will be incorporated into the cacheID. While the contents of the files are not read, the file system is queried for relavent information (mtime, inode) so that the Config’s cacheID will change when the underlying luts are updated.
If a nil context is provided, file references will not be taken into account (this is essentially a hash of Config.Serialize).
func (*Config) ClearColorSpaces ¶
func (*Config) ClearDisplays ¶
func (c *Config) ClearDisplays()
func (*Config) ColorSpace ¶
func (c *Config) ColorSpace(name string) (*ColorSpace, error)
This will return null if the specified name is not found. Accepts either a color space OR role name. (Colorspace names take precedence over roles.)
func (*Config) ColorSpaceNameByIndex ¶
This will null if an invalid index is specified
func (*Config) CurrentContext ¶
func (*Config) DefaultDisplay ¶
func (*Config) DefaultView ¶
func (*Config) Description ¶
func (*Config) Destroy ¶ added in v1.0.2
func (c *Config) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*Config) DisplayColorSpaceName ¶
func (*Config) DisplayLooks ¶
Looks is a potentially comma (or colon) delimited list of lookNames, Where +/- prefixes are optionally allowed to denote forward/inverse look specification. (And forward is assumed in the absense of either)
func (*Config) EditableCopy ¶
Create a new editable copy of this Config
func (*Config) IndexForColorSpace ¶
Accepts either a color space OR role name. (Colorspace names take precedence over roles.)
func (*Config) IsStrictParsingEnabled ¶
func (*Config) NumColorSpaces ¶
func (*Config) NumDisplays ¶
func (*Config) ParseColorSpaceFromString ¶
Given the specified string, get the longest, right-most, colorspace substring that appears.
* If strict parsing is enabled, and no color space is found, return an empty string. * If strict parsing is disabled, return ROLE_DEFAULT (if defined). * If the default role is not defined, return an empty string.
func (*Config) Processor ¶
Convert from inputColorSpace to outputColorSpace
There are 4 ways this method may be called:
config.Processor(ctx *Context, src *ColorSpace, dst *ColorSpace) config.Processor(ctx *Context, src string, dst string) config.Processor(src *ColorSpace, dst *ColorSpace) config.Processor(src string, dst string)
String names can be colorspace name, role name, or a combination of both.
This may provide higher fidelity than anticipated due to internal optimizations. For example, if the inputColorspace and the outputColorSpace are members of the same family, no conversion will be applied, even though strictly speaking quantization should be added
func (*Config) ProcessorCtxTransformDir ¶
func (c *Config) ProcessorCtxTransformDir( ctx *Context, tx Transform, dir TransformDirection) (*Processor, error)
Get the processor for the specified transform, using a specific Context instead of the current Config context, and a transform direction.
Not often needed, but will allow for the re-use of atomic OCIO functionality (such as to apply an individual LUT file).
func (*Config) ProcessorTransform ¶
Get the processor for the specified transform, using the current Config context.
Not often needed, but will allow for the re-use of atomic OCIO functionality (such as to apply an individual LUT file).
func (*Config) ProcessorTransformDir ¶
func (c *Config) ProcessorTransformDir(tx Transform, dir TransformDirection) (*Processor, error)
Get the processor for the specified transform, and a transform direction, using the current Config context.
Not often needed, but will allow for the re-use of atomic OCIO functionality (such as to apply an individual LUT file).
func (*Config) RoleName ¶
Get the role name at index, this will return values like ‘scene_linear’, ‘compositing_log’. Return empty string if index is out of range.
func (*Config) SanityCheck ¶
This will return a non-nil error if the config is malformed. The most common error occurs when references are made to colorspaces that do not exist.
func (*Config) SearchPath ¶
Given a lut src name, where should we find it?
func (*Config) SetActiveDisplays ¶
Comma-delimited list of display names.
func (*Config) SetActiveViews ¶
Comma-delimited list of view names.
func (*Config) SetStrictParsingEnabled ¶
func (*Config) WorkingDir ¶
Given a lut src name, where should we find it?
type Context ¶
type Context struct {
// contains filtered or unexported fields
}
func (*Context) Destroy ¶ added in v1.0.2
func (c *Context) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*Context) EditableCopy ¶
Create a new editable copy of this Context
func (*Context) EnvironmentMode ¶ added in v1.0.1
func (c *Context) EnvironmentMode() EnvironmentMode
func (*Context) LoadEnvironment ¶
func (c *Context) LoadEnvironment()
Seed all string vars with the current environment.
func (*Context) ResolveFileLocation ¶
Do a file lookup. Evaluate all variables (as needed). Also, walk the full search path until the file is found. If the filename cannot be found, an error will be returned.
func (*Context) ResolveStringVar ¶
Do a file lookup. Evaluate the specified variable (as needed).
func (*Context) SearchPath ¶
func (*Context) SetEnvironmentMode ¶ added in v1.0.1
func (c *Context) SetEnvironmentMode(mode EnvironmentMode)
func (*Context) SetSearchPath ¶
func (*Context) SetStringVar ¶
func (*Context) SetWorkingDir ¶
func (*Context) WorkingDir ¶
type DisplayTransform ¶
type DisplayTransform struct {
// contains filtered or unexported fields
}
func NewDisplayTransform ¶
func NewDisplayTransform() *DisplayTransform
Create a new empty DisplayTransform
func (*DisplayTransform) Destroy ¶ added in v1.0.2
func (tx *DisplayTransform) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*DisplayTransform) Direction ¶
func (tx *DisplayTransform) Direction() TransformDirection
func (*DisplayTransform) Display ¶
func (tx *DisplayTransform) Display() string
Display returns the output display transform.
func (*DisplayTransform) EditableCopy ¶
func (tx *DisplayTransform) EditableCopy() *DisplayTransform
Create a new editable copy of this DisplayTransform
func (*DisplayTransform) InputColorSpace ¶
func (tx *DisplayTransform) InputColorSpace() string
InputColorSpace returns the incoming color space
func (*DisplayTransform) LooksOverride ¶
func (tx *DisplayTransform) LooksOverride() string
func (*DisplayTransform) LooksOverrideEnabled ¶
func (tx *DisplayTransform) LooksOverrideEnabled() bool
func (*DisplayTransform) SetDirection ¶
func (tx *DisplayTransform) SetDirection(dir TransformDirection)
func (*DisplayTransform) SetDisplay ¶
func (tx *DisplayTransform) SetDisplay(name string)
SetDisplay sets the output display transform. This is controlled by the specification of (display, view).
func (*DisplayTransform) SetInputColorSpace ¶
func (tx *DisplayTransform) SetInputColorSpace(cs string)
SetInputColorSpace sets the incoming color space
func (*DisplayTransform) SetLooksOverride ¶
func (tx *DisplayTransform) SetLooksOverride(looks string)
A user can optionally override the looks that are, by default, used with the expected display / view combination. A common use case for this functionality is in an image viewing app, where per-shot looks are supported. If for some reason a per-shot look is not defined for the current Context, the Config.Processor() function will not succeed by default. Thus, with this mechanism the viewing app could override to looks = "", and this will allow image display to continue (though hopefully) the interface would reflect this fallback option).
Looks is a potentially comma (or colon) delimited list of lookNames, where +/- prefixes are optionally allowed to denote forward/inverse look specification (And forward is assumed in the absence of either).
func (*DisplayTransform) SetLooksOverrideEnabled ¶
func (tx *DisplayTransform) SetLooksOverrideEnabled(enabled bool)
SetLooksOverrideEnabled specifies whether the lookOverride should be used or not. This is a separate flag, as it's often useful to override "looks" to an empty string
func (*DisplayTransform) SetView ¶
func (tx *DisplayTransform) SetView(name string)
SetView: Specify which view transform to use
func (*DisplayTransform) View ¶
func (tx *DisplayTransform) View() string
View returns the view transform to use
type EnvironmentMode ¶
type EnvironmentMode int
const ( ENVIRONMENT_UNKNOWN EnvironmentMode = C.ENV_ENVIRONMENT_UNKNOWN ENVIRONMENT_LOAD_PREDEFINED EnvironmentMode = C.ENV_ENVIRONMENT_LOAD_PREDEFINED ENVIRONMENT_LOAD_ALL EnvironmentMode = C.ENV_ENVIRONMENT_LOAD_ALL )
type ErrMissingFile ¶
type ErrMissingFile struct {
// contains filtered or unexported fields
}
An exception class for errors detected at runtime, thrown when OCIO cannot find a file that is expected to exist. This is provided as a custom type to distinguish cases where one wants to continue looking for missing files, but wants to properly fail for other error conditions.
func (ErrMissingFile) Error ¶
func (e ErrMissingFile) Error() string
type ImageDescriptor ¶
type ImageDescriptor interface {
// contains filtered or unexported methods
}
type InterpType ¶
type InterpType int
const ( INTERP_UNKNOWN InterpType = C.INTERP_UNKNOWN INTERP_NEAREST InterpType = C.INTERP_NEAREST INTERP_LINEAR InterpType = C.INTERP_LINEAR INTERP_TETRAHEDRAL InterpType = C.INTERP_TETRAHEDRAL INTERP_BEST InterpType = C.INTERP_BEST )
type LoggingLevelType ¶
type LoggingLevelType int
const ( LOGGING_LEVEL_NONE LoggingLevelType = C.LOGGING_LEVEL_NONE LOGGING_LEVEL_WARNING LoggingLevelType = C.LOGGING_LEVEL_WARNING LOGGING_LEVEL_INFO LoggingLevelType = C.LOGGING_LEVEL_INFO LOGGING_LEVEL_DEBUG LoggingLevelType = C.LOGGING_LEVEL_DEBUG LOGGING_LEVEL_UNKNOWN LoggingLevelType = C.LOGGING_LEVEL_UNKNOWN )
func LoggingLevel ¶
func LoggingLevel() LoggingLevelType
Get the global logging level. You can override this at runtime using the OCIO_LOGGING_LEVEL environment variable. The client application that sets this should use SetLoggingLevel(), and not the environment variable. The default value is INFO.
Returns on of the LOGGING_LEVEL_* const values
type PackedImageDesc ¶
type PackedImageDesc struct {
// contains filtered or unexported fields
}
This is a light-weight wrapper around an image, that provides a context for pixel access
func NewPackedImageDesc ¶
func NewPackedImageDesc(rgb ColorData, width, height, numChannels int) *PackedImageDesc
Create a PackedImageDesc wrapper for some raw rgb data Pass a []float32 slice of image data: rgbrgbrgb, etc. The number of channels must be greater than or equal to 3 If a 4th channel is specified, it is assumed to be alpha information. Channels > 4 will be ignored.
func (*PackedImageDesc) Data ¶
func (p *PackedImageDesc) Data() ColorData
Return the current state of the image data, potentially modified if color transformations have been applied.
func (*PackedImageDesc) Destroy ¶ added in v1.0.2
func (p *PackedImageDesc) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*PackedImageDesc) NumChannels ¶
func (p *PackedImageDesc) NumChannels() int
Number of color channels in the image
type Processor ¶
type Processor struct {
// contains filtered or unexported fields
}
func (*Processor) CpuCacheID ¶
func (*Processor) Destroy ¶ added in v1.0.2
func (p *Processor) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*Processor) HasChannelCrosstalk ¶
does the processor represent an image transformation that introduces crosstalk between the image channels
func (*Processor) Metadata ¶
func (p *Processor) Metadata() *ProcessorMetadata
type ProcessorMetadata ¶
type ProcessorMetadata struct {
// contains filtered or unexported fields
}
This class contains meta information about the process that generated this processor. The results of these functions do not impact the pixel processing.
func NewProcessorMetadata ¶
func NewProcessorMetadata() *ProcessorMetadata
Create a new empty ProcessorMetadata
func (*ProcessorMetadata) AddFile ¶
func (p *ProcessorMetadata) AddFile(fileName string)
func (*ProcessorMetadata) AddLook ¶
func (p *ProcessorMetadata) AddLook(lookName string)
func (*ProcessorMetadata) Destroy ¶ added in v1.0.2
func (p *ProcessorMetadata) Destroy()
Destroy immediately frees resources for this instance instead of waiting for garbage collection finalizer to run at some point later
func (*ProcessorMetadata) File ¶
func (p *ProcessorMetadata) File(index int) string
func (*ProcessorMetadata) Files ¶ added in v1.0.1
func (p *ProcessorMetadata) Files() []string
Files is a helper to return a slice of the file paths, using NumFiles and File(index)
func (*ProcessorMetadata) Look ¶
func (p *ProcessorMetadata) Look(index int) string
func (*ProcessorMetadata) NumFiles ¶
func (p *ProcessorMetadata) NumFiles() int
func (*ProcessorMetadata) NumLooks ¶
func (p *ProcessorMetadata) NumLooks() int
type Transform ¶
type Transform interface {
// contains filtered or unexported methods
}
Transform interface represents the different types of concrete transform types that can be passed into API calls
type TransformDirection ¶
type TransformDirection int
const ( TRANSFORM_DIR_UNKNOWN TransformDirection = C.TRANSFORM_DIR_UNKNOWN TRANSFORM_DIR_FORWARD TransformDirection = C.TRANSFORM_DIR_FORWARD TRANSFORM_DIR_INVERSE TransformDirection = C.TRANSFORM_DIR_INVERSE )