1
0
Эх сурвалжийг харах

docs/sphinx: Document SRGB changes

jpark37 4 жил өмнө
parent
commit
edbad7e93d

+ 1 - 0
docs/sphinx/graphics.rst

@@ -77,6 +77,7 @@ Then the uniforms are set through the following functions:
 - :c:func:`gs_effect_set_vec3()`
 - :c:func:`gs_effect_set_vec3()`
 - :c:func:`gs_effect_set_vec4()`
 - :c:func:`gs_effect_set_vec4()`
 - :c:func:`gs_effect_set_texture()`
 - :c:func:`gs_effect_set_texture()`
+- :c:func:`gs_effect_set_texture_srgb()`
 
 
 There are two "universal" effect parameters that may be expected of
 There are two "universal" effect parameters that may be expected of
 effects:  **ViewProj**, and **image**.  The **ViewProj** parameter
 effects:  **ViewProj**, and **image**.  The **ViewProj** parameter

+ 9 - 0
docs/sphinx/reference-libobs-graphics-effects.rst

@@ -337,6 +337,15 @@ HLSL format.
 
 
 ---------------------
 ---------------------
 
 
+.. function:: void gs_effect_set_texture_srgb(gs_eparam_t *param, gs_texture_t *val)
+
+   Sets a texture parameter using SRGB view if available.
+
+   :param param: Effect parameter
+   :param val:   Texture
+
+---------------------
+
 .. function:: void gs_effect_set_val(gs_eparam_t *param, const void *val, size_t size)
 .. function:: void gs_effect_set_val(gs_eparam_t *param, const void *val, size_t size)
 
 
    Sets a parameter with data manually.
    Sets a parameter with data manually.

+ 3 - 0
docs/sphinx/reference-libobs-graphics-graphics.rst

@@ -42,6 +42,9 @@ Graphics Enumerations
    - GS_DXT1        - Compressed DXT1
    - GS_DXT1        - Compressed DXT1
    - GS_DXT3        - Compressed DXT3
    - GS_DXT3        - Compressed DXT3
    - GS_DXT5        - Compressed DXT5
    - GS_DXT5        - Compressed DXT5
+   - GS_RGBA_UNORM  - RGBA, 8 bits per channel, no SRGB aliasing
+   - GS_BGRX_UNORM  - BGRX, 8 bits per channel, no SRGB aliasing
+   - GS_BGRA_UNORM  - BGRA, 8 bits per channel, no SRGB aliasing
 
 
 .. type:: enum gs_zstencil_format
 .. type:: enum gs_zstencil_format