#pragma once #include #include #include #include /*! \file compute.h \brief Provides support for running compute-shaders. */ #ifdef __cplusplus extern "C" { #endif typedef struct kinc_g5_compute_shader_impl { int a; } kinc_g5_compute_shader_ímpl_t; typedef struct kinc_g5_compute_shader { kinc_g5_compute_shader_ímpl_t impl; } kinc_g5_compute_shader_t; /// /// Initialize a compute-shader from system-specific shader-data. /// /// The shader-object to initialize /// A pointer to system-specific shader-data /// Length of the shader-data in bytes KINC_FUNC void kinc_g5_compute_shader_init(kinc_g5_compute_shader_t *shader, void *source, int length); /// /// Desotry a shader-object /// /// The shader-object to destroy KINC_FUNC void kinc_g5_compute_shader_destroy(kinc_g5_compute_shader_t *shader); /// /// Finds the location of a constant/uniform inside of a shader. /// /// The shader to look into /// The constant/uniform-name to look for /// The found constant-location KINC_FUNC kinc_g5_constant_location_t kinc_g5_compute_shader_get_constant_location(kinc_g5_compute_shader_t *shader, const char *name); /// /// Finds a texture-unit inside of a shader. /// /// The shader to look into /// The texture-name to look for /// The found texture-unit KINC_FUNC kinc_g5_texture_unit_t kinc_compute_g5_shader_get_texture_unit(kinc_g5_compute_shader_t *shader, const char *name); #ifdef __cplusplus } #endif