OpenImageIO
|
#include <texture.h>
Public Types | |
enum | Wrap { WrapDefault, WrapBlack, WrapClamp, WrapPeriodic, WrapMirror, WrapLast } |
enum | MipMode { MipModeDefault, MipModeNoMIP, MipModeOneLevel, MipModeTrilinear, MipModeAniso } |
enum | InterpMode { InterpClosest, InterpBilinear, InterpBicubic, InterpSmartBicubic } |
Public Member Functions | |
TextureOptions () | |
TextureOptions (const TextureOpt &opt) | |
Static Public Member Functions | |
static Wrap | decode_wrapmode (const char *name) |
static Wrap | decode_wrapmode (ustring name) |
static void | parse_wrapmodes (const char *wrapmodes, TextureOptions::Wrap &swrapcode, TextureOptions::Wrap &twrapcode) |
Public Attributes | |
int | firstchannel |
First channel of the lookup. | |
int | nchannels |
Number of channels to look up. | |
int | subimage |
Subimage or face ID. | |
ustring | subimagename |
Subimage name. | |
Wrap | swrap |
Wrap mode in the s direction. | |
Wrap | twrap |
Wrap mode in the t direction. | |
MipMode | mipmode |
Mip mode. | |
InterpMode | interpmode |
Interpolation mode. | |
int | anisotropic |
Maximum anisotropic ratio. | |
bool | conservative_filter |
True == over-blur rather than alias. | |
VaryingRef< float > | sblur |
VaryingRef< float > | tblur |
Blur amount. | |
VaryingRef< float > | swidth |
VaryingRef< float > | twidth |
Multiplier for derivatives. | |
VaryingRef< float > | time |
Time. | |
VaryingRef< float > | bias |
Bias. | |
VaryingRef< float > | fill |
Fill value for missing channels. | |
VaryingRef< float > | missingcolor |
Color for missing texture. | |
VaryingRef< int > | samples |
Number of samples. | |
float * | dresultds |
Deriv of the result along s (if not NULL) | |
float * | dresultdt |
Deriv of the result along t (if not NULL) | |
Wrap | rwrap |
Wrap mode in the r direction. | |
VaryingRef< float > | rblur |
Blur amount in the r direction. | |
VaryingRef< float > | rwidth |
Multiplier for derivatives in r direction. | |
float * | dresultdr |
Deriv of the result along r (if not NULL) | |
Friends | |
class | pvt::TextureSystemImpl |
class | TextureOpt |
Encapsulate all the options needed for texture lookups. Making these options all separate parameters to the texture API routines is very ugly and also a big pain whenever we think of new options to add. So instead we collect all those little options into one structure that can just be passed by reference to the texture API routines.
enum TextureOptions::Wrap |
Wrap mode describes what happens when texture coordinates describe a value outside the usual [0,1] range where a texture is defined.
TextureOptions::TextureOptions | ( | ) |
Create a TextureOptions with all fields initialized to reasonable defaults.
TextureOptions::TextureOptions | ( | const TextureOpt & | opt | ) |
Convert a TextureOpt for one point into a TextureOptions with uninform values.
|
inlinestatic |
Utility: Return the Wrap enum corresponding to a wrap name: "default", "black", "clamp", "periodic", "mirror".
|
inlinestatic |
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.
int TextureOptions::anisotropic |
Maximum anisotropic ratio.
VaryingRef<float> TextureOptions::bias |
Bias.
bool TextureOptions::conservative_filter |
True == over-blur rather than alias.
float* TextureOptions::dresultdr |
Deriv of the result along r (if not NULL)
float* TextureOptions::dresultds |
Deriv of the result along s (if not NULL)
float* TextureOptions::dresultdt |
Deriv of the result along t (if not NULL)
VaryingRef<float> TextureOptions::fill |
Fill value for missing channels.
int TextureOptions::firstchannel |
First channel of the lookup.
InterpMode TextureOptions::interpmode |
Interpolation mode.
MipMode TextureOptions::mipmode |
Mip mode.
VaryingRef<float> TextureOptions::missingcolor |
Color for missing texture.
int TextureOptions::nchannels |
Number of channels to look up.
VaryingRef<float> TextureOptions::rblur |
Blur amount in the r direction.
VaryingRef<float> TextureOptions::rwidth |
Multiplier for derivatives in r direction.
Wrap TextureOptions::rwrap |
Wrap mode in the r direction.
VaryingRef<int> TextureOptions::samples |
Number of samples.
int TextureOptions::subimage |
Subimage or face ID.
ustring TextureOptions::subimagename |
Subimage name.
Wrap TextureOptions::swrap |
Wrap mode in the s direction.
VaryingRef<float> TextureOptions::tblur |
Blur amount.
VaryingRef<float> TextureOptions::time |
Time.
VaryingRef<float> TextureOptions::twidth |
Multiplier for derivatives.
Wrap TextureOptions::twrap |
Wrap mode in the t direction.