Fixed frame buffer image.
This commit is contained in:
Родитель
5edeea64a9
Коммит
d7f2ec9386
|
@ -11,18 +11,18 @@
|
|||
#ifndef __cplusplus
|
||||
|
||||
#if BGFX_SHADER_LANGUAGE_GLSL
|
||||
# define __UAV_REG_0 4
|
||||
# define __UAV_REG_1 5
|
||||
# define __UAV_REG_2 6
|
||||
# define __UAV_REG_3 7
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_0(_name, _format) IMAGE2D_RW(_name, _format, 4)
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_1(_name, _format) IMAGE2D_RW(_name, _format, 5)
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_2(_name, _format) IMAGE2D_RW(_name, _format, 6)
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_3(_name, _format) IMAGE2D_RW(_name, _format, 7)
|
||||
#else
|
||||
# define __UAV_REG_0 16
|
||||
# define __UAV_REG_1 17
|
||||
# define __UAV_REG_2 18
|
||||
# define __UAV_REG_3 19
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_0(_name, _format) IMAGE2D_RW(_name, _format, 16)
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_1(_name, _format) IMAGE2D_RW(_name, _format, 17)
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_2(_name, _format) IMAGE2D_RW(_name, _format, 18)
|
||||
# define FRAMEBUFFER_IMAGE2D_RW_3(_name, _format) IMAGE2D_RW(_name, _format, 19)
|
||||
#endif // BGFX_SHADER_LANGUAGE_GLSL
|
||||
|
||||
#define FRAMEBUFFER_IMAGE2D_RW(_name, _format, _reg) IMAGE2D_RW(_name, _format, __UAV_REG_ ## _reg)
|
||||
#define FRAMEBUFFER_IMAGE2D_RW(_name, _format, _reg) FRAMEBUFFER_IMAGE2D_RW_ ## _reg(_name, _format)
|
||||
|
||||
#if BGFX_SHADER_LANGUAGE_GLSL
|
||||
|
||||
|
|
|
@ -36,7 +36,10 @@
|
|||
# define ARRAY_END() }
|
||||
#endif // BGFX_SHADER_LANGUAGE_GLSL
|
||||
|
||||
#if BGFX_SHADER_LANGUAGE_HLSL || BGFX_SHADER_LANGUAGE_PSSL || BGFX_SHADER_LANGUAGE_SPIRV || BGFX_SHADER_LANGUAGE_METAL
|
||||
#if BGFX_SHADER_LANGUAGE_HLSL \
|
||||
|| BGFX_SHADER_LANGUAGE_PSSL \
|
||||
|| BGFX_SHADER_LANGUAGE_SPIRV \
|
||||
|| BGFX_SHADER_LANGUAGE_METAL
|
||||
# define CONST(_x) static const _x
|
||||
# define dFdx(_x) ddx(_x)
|
||||
# define dFdy(_y) ddy(-_y)
|
||||
|
|
Загрузка…
Ссылка в новой задаче