mirror of
https://github.com/love2d/love.git
synced 2026-08-16 08:11:02 +02:00
Add Depth compare / shadow sampler support. Officially this is only supported in glsl3 shaders.
- Add Texture:setDepthSampleMode(comparemode). Only works on textures with depth pixel formats. A texture with the depth sample mode set will only work with a depth sampler. - Add DepthImage, DepthArrayImage, and DepthCubeImage sampler keywords to glsl3. --HG-- branch : minor
This commit is contained in:
@@ -115,10 +115,15 @@ bool getConstant(const char *in, PixelFormat &out);
|
||||
bool isPixelFormatCompressed(PixelFormat format);
|
||||
|
||||
/**
|
||||
* Gets whether the specified pixel format is a depth/stencil type.
|
||||
* Gets whether the specified pixel format is a depth or stencil type.
|
||||
**/
|
||||
bool isPixelFormatDepthStencil(PixelFormat format);
|
||||
|
||||
/**
|
||||
* Gets whether the specified pixel format is a depth type.
|
||||
**/
|
||||
bool isPixelFormatDepth(PixelFormat format);
|
||||
|
||||
/**
|
||||
* Gets the size in bytes of the specified pixel format.
|
||||
* NOTE: Currently returns 0 for compressed formats.
|
||||
|
||||
Reference in New Issue
Block a user