20 #ifndef VTFLIB_VTFFILE_H
21 #define VTFLIB_VTFFILE_H
39 typedef struct tagSVTFImageFormatInfo
61 typedef struct tagSVTFCreateOptions
141 vlUInt uiThumbnailBufferSize;
142 vlByte *lpThumbnailImageData;
289 vlBool Save(
vlVoid *lpData, vlSize uiBufferSize, vlSize &uiSize)
const;
304 vlVoid ComputeResources();
307 vlBool Load(IO::Readers::IReader *Reader,
vlBool bHeaderOnly);
308 vlBool Save(IO::Writers::IWriter *Writer)
const;
319 vlBool GetHasImage()
const;
321 vlUInt GetMajorVersion()
const;
322 vlUInt GetMinorVersion()
const;
329 vlUInt GetFrameCount()
const;
330 vlUInt GetFaceCount()
const;
331 vlUInt GetMipmapCount()
const;
333 vlUInt GetStartFrame()
const;
419 vlBool GetHasThumbnail()
const;
421 vlUInt GetThumbnailWidth()
const;
422 vlUInt GetThumbnailHeight()
const;
432 vlByte *GetThumbnailData()
const;
446 vlBool GetSupportsResources()
const;
448 vlUInt GetResourceCount()
const;
512 vlBool GenerateThumbnail();
541 vlBool GenerateSphereMap();
545 vlBool ComputeReflectivity();
694 static vlBool ConvertToNormalMap(
const vlByte *lpSourceRGBA8888,
vlByte *lpDestRGBA8888,
vlUInt uiWidth,
vlUInt uiHeight,
VTFKernelFilter KernelFilter = KERNEL_FILTER_3X3,
VTFHeightConversionMethod HeightConversionMethod = HEIGHT_CONVERSION_METHOD_AVERAGE_RGB,
VTFNormalAlphaResult NormalAlphaResult = NORMAL_ALPHA_RESULT_WHITE,
vlByte bMinimumZ = 0,
vlSingle sScale = 2.0f,
vlBool bWrap = vlFalse,
vlBool bInvertX = vlFalse,
vlBool bInvertY = vlFalse,
vlBool bInvertZ = vlFalse);
vlUInt uiResizeClampHeight
Maximum height to re-size to.
Definition: VTFFile.h:87
unsigned char vlByte
Single unsigned byte.
Definition: stdafx.h:52
vlBool bGammaCorrection
Gamma correct input image.
Definition: VTFFile.h:89
VTFSharpenFilter MipmapSharpenFilter
MIP map sharpen filter.
Definition: VTFFile.h:73
vlBool bNormalMap
Convert input image to a normal map.
Definition: VTFFile.h:92
vlBool bResizeClamp
Clamp re-size size.
Definition: VTFFile.h:85
VTFMipmapFilter ResizeFilter
Re-size filter.
Definition: VTFFile.h:80
vlSingle sNormalScale
Normal map scale.
Definition: VTFFile.h:97
char vlChar
Single signed character.
Definition: stdafx.h:51
vlBool bMipmaps
Generate MIPmaps. (Space is always allocated.)
Definition: VTFFile.h:71
vlByte bNormalMinimumZ
Minimum normal Z value.
Definition: VTFFile.h:96
vlSingle sBumpScale
Output image bump scale.
Definition: VTFFile.h:68
VTFKernelFilter KernelFilter
Normal map generation kernel.
Definition: VTFFile.h:93
vlBool bNormalInvertZ
Invert the normal Z component.
Definition: VTFFile.h:101
vlUInt uiStartFrame
Output image start frame.
Definition: VTFFile.h:67
unsigned int vlUInt
Unsigned integer value.
Definition: stdafx.h:56
vlBool bNormalInvertX
Invert the normal X component.
Definition: VTFFile.h:99
VTFResizeMethod ResizeMethod
New size compution method.
Definition: VTFFile.h:79
vlBool bThumbnail
Generate thumbnail image.
Definition: VTFFile.h:75
Application framework header plus VTFLib custom data types.
vlUInt uiResizeWidth
New width after re-size if method is RESIZE_SET.
Definition: VTFFile.h:82
VTFImageFormat ImageFormat
Output image output storage format.
Definition: VTFFile.h:64
void vlVoid
Void value.
Definition: stdafx.h:61
VTFMipmapFilter MipmapFilter
MIP map re-size filter.
Definition: VTFFile.h:72
VTF Creation options struct.
Definition: VTFFile.h:61
VTF File access/creation class.
Definition: VTFFile.h:132
vlSingle sGammaCorrection
Gamma correction to apply.
Definition: VTFFile.h:90
vlBool bNormalWrap
Wrap the normal map.
Definition: VTFFile.h:98
vlUInt uiResizeClampWidth
Maximum width to re-size to.
Definition: VTFFile.h:86
VTFHeightConversionMethod HeightConversionMethod
Method or determining height from input image during normal map creation.
Definition: VTFFile.h:94
vlUInt uiFlags
Output image header flags.
Definition: VTFFile.h:66
VTFSharpenFilter ResizeSharpenFilter
Sharpen filter.
Definition: VTFFile.h:81
vlBool bSphereMap
Generate a sphere map for six faced environment maps.
Definition: VTFFile.h:103
vlBool bNormalInvertY
Invert the normal Y component.
Definition: VTFFile.h:100
unsigned char vlBool
Boolean value 0/1.
Definition: stdafx.h:50
vlUInt uiResizeHeight
New height after re-size if method is RESIZE_SET.
Definition: VTFFile.h:83
vlBool bResize
Resize the input image.
Definition: VTFFile.h:78
float vlSingle
Floating point number.
Definition: stdafx.h:59
VTFNormalAlphaResult NormalAlphaResult
How to handle output image alpha channel, post normal map creation.
Definition: VTFFile.h:95
vlBool bReflectivity
Compute image reflectivity.
Definition: VTFFile.h:76