HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Tex Namespace Reference

Typedefs

typedef simd::VecType< float,
OIIO_TEXTURE_SIMD_BATCH_WIDTH >
::type 
FloatWide
 A type alias for a SIMD vector of floats with the batch width. More...
 
typedef simd::VecType< int,
OIIO_TEXTURE_SIMD_BATCH_WIDTH >
::type 
IntWide
 A type alias for a SIMD vector of ints with the batch width. More...
 
typedef uint64_t RunMask
 

Enumerations

enum  Wrap {
  Wrap::Default, Wrap::Black, Wrap::Clamp, Wrap::Periodic,
  Wrap::Mirror, Wrap::PeriodicPow2, Wrap::PeriodicSharedBorder, Wrap::Last
}
 
enum  MipMode {
  MipMode::Default, MipMode::NoMIP, MipMode::OneLevel, MipMode::Trilinear,
  MipMode::Aniso, MipMode::StochasticTrilinear, MipMode::StochasticAniso
}
 
enum  InterpMode { InterpMode::Closest, InterpMode::Bilinear, InterpMode::Bicubic, InterpMode::SmartBicubic }
 

Functions

OIIO_API Wrap decode_wrapmode (const char *name)
 
OIIO_API Wrap decode_wrapmode (ustring name)
 
OIIO_API Wrap decode_wrapmode (ustringhash name)
 
OIIO_API void parse_wrapmodes (const char *wrapmodes, Wrap &swrapcode, Wrap &twrapcode)
 

Variables

OIIO_INLINE_CONSTEXPR int BatchWidth = OIIO_TEXTURE_SIMD_BATCH_WIDTH
 
OIIO_INLINE_CONSTEXPR int BatchAlign = BatchWidth * sizeof(float)
 
OIIO_INLINE_CONSTEXPR RunMask RunMaskOn = 0xffff
 

Typedef Documentation

A type alias for a SIMD vector of floats with the batch width.

Definition at line 141 of file texture.h.

A type alias for a SIMD vector of ints with the batch width.

Definition at line 144 of file texture.h.

typedef uint64_t Tex::RunMask

RunMask is defined to be an integer large enough to hold at least BatchWidth bits. The least significant bit corresponds to the first (i.e., [0]) position of all batch arrays. For each position i in the batch, the bit identified by (1 << i) controls whether that position will be computed.

Definition at line 151 of file texture.h.

Enumeration Type Documentation

enum Tex::InterpMode
strong

Interp mode determines how we sample within a mipmap level

Enumerator
Closest 

Force closest texel.

Bilinear 

Force bilinear lookup within a mip level.

Bicubic 

Force cubic lookup within a mip level.

SmartBicubic 

Bicubic when magnifying, else bilinear.

Definition at line 120 of file texture.h.

enum Tex::MipMode
strong

Mip mode determines if/how we use mipmaps

Enumerator
Default 

Default high-quality lookup.

NoMIP 

Just use highest-res image, no MIP mapping.

OneLevel 

Use just one mipmap level.

Trilinear 

Use two MIPmap levels (trilinear)

Aniso 

Use two MIPmap levels w/ anisotropic.

StochasticTrilinear 

DEPRECATED Stochastic trilinear.

StochasticAniso 

DEPRECATED Stochastic anisotropic.

Definition at line 108 of file texture.h.

enum Tex::Wrap
strong

Wrap mode describes what happens when texture coordinates describe a value outside the usual [0,1] range where a texture is defined.

Enumerator
Default 

Use the default found in the file.

Black 

Black outside [0..1].

Clamp 

Clamp to [0..1].

Periodic 

Periodic mod 1.

Mirror 

Mirror the image.

PeriodicPow2 

Periodic, but only for powers of 2!!!

PeriodicSharedBorder 

Periodic with shared border (env)

Last 

Mark the end – don't use this!

Definition at line 82 of file texture.h.

Function Documentation

OIIO_API Wrap Tex::decode_wrapmode ( const char *  name)

Utility: Return the Wrap enum corresponding to a wrap name: "default", "black", "clamp", "periodic", "mirror".

OIIO_API Wrap Tex::decode_wrapmode ( ustring  name)
OIIO_API Wrap Tex::decode_wrapmode ( ustringhash  name)
OIIO_API void Tex::parse_wrapmodes ( const char *  wrapmodes,
Wrap &  swrapcode,
Wrap &  twrapcode 
)

Utility: Parse a single wrap mode (e.g., "periodic") or a comma-separated wrap modes string (e.g., "black,clamp") into separate Wrap enums for s and t.

Variable Documentation

OIIO_INLINE_CONSTEXPR int Tex::BatchAlign = BatchWidth * sizeof(float)

Definition at line 138 of file texture.h.

OIIO_INLINE_CONSTEXPR int Tex::BatchWidth = OIIO_TEXTURE_SIMD_BATCH_WIDTH

The SIMD width for batched texturing operations. This is fixed within any release of OpenImageIO, but may change from release to release and also may be overridden at build time. A typical batch size is 16.

Definition at line 137 of file texture.h.

OIIO_INLINE_CONSTEXPR RunMask Tex::RunMaskOn = 0xffff

Definition at line 161 of file texture.h.