6#ifndef MATERIALX_GLTEXTUREHANDLER_H
7#define MATERIALX_GLTEXTUREHANDLER_H
16MATERIALX_NAMESPACE_BEGIN
57 int& glType,
int& glFormat,
int& glInternalFormat);
64 int getNextAvailableTextureLocation();
67 std::vector<unsigned int> _boundTextureLocations;
70MATERIALX_NAMESPACE_END
std::shared_ptr< class GLTextureHandler > GLTextureHandlerPtr
Shared pointer to an OpenGL texture handler.
Definition: GLTextureHandler.h:19
shared_ptr< Image > ImagePtr
A shared pointer to an image.
Definition: Image.h:23
Image handler interfaces.
std::shared_ptr< ImageLoader > ImageLoaderPtr
Shared pointer to an ImageLoader.
Definition: ImageHandler.h:35
std::shared_ptr< ImageHandler > ImageHandlerPtr
Shared pointer to an ImageHandler.
Definition: ImageHandler.h:32
Macros for declaring imported and exported symbols.
An OpenGL texture handler class.
Definition: GLTextureHandler.h:24
bool unbindImage(ImagePtr image) override
Unbind an image.
int getBoundTextureLocation(unsigned int resourceId)
Return the bound texture location for a given resource.
bool bindImage(ImagePtr image, const ImageSamplingProperties &samplingProperties) override
Bind an image.
bool createRenderResources(ImagePtr image, bool generateMipMaps, bool useAsRenderTarget=false) override
Create rendering resources for the given image.
static int mapAddressModeToGL(ImageSamplingProperties::AddressMode addressModeEnum)
Utility to map an address mode enumeration to an OpenGL address mode.
static void mapTextureFormatToGL(Image::BaseType baseType, unsigned int channelCount, bool srgb, int &glType, int &glFormat, int &glInternalFormat)
Utility to map generic texture properties to OpenGL texture formats.
static int mapFilterTypeToGL(ImageSamplingProperties::FilterType filterTypeEnum, bool enableMipmaps)
Utility to map a filter type enumeration to an OpenGL filter type.
void releaseRenderResources(ImagePtr image=nullptr) override
Release rendering resources for the given image, or for all cached images if no image pointer is spec...
Base image handler class.
Definition: ImageHandler.h:164
Interface to describe sampling properties for images.
Definition: ImageHandler.h:43
FilterType
Filter type options.
Definition: ImageHandler.h:73
AddressMode
Address mode options.
Definition: ImageHandler.h:57