Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/gpu/intern/gpu_material_library.h')
-rw-r--r--source/blender/gpu/intern/gpu_material_library.h27
1 files changed, 9 insertions, 18 deletions
diff --git a/source/blender/gpu/intern/gpu_material_library.h b/source/blender/gpu/intern/gpu_material_library.h
index 96e1a265c72..ffc2228a49b 100644
--- a/source/blender/gpu/intern/gpu_material_library.h
+++ b/source/blender/gpu/intern/gpu_material_library.h
@@ -10,16 +10,15 @@
#include "GPU_material.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#define MAX_FUNCTION_NAME 64
#define MAX_PARAMETER 36
struct GSet;
-typedef struct GPUMaterialLibrary {
- char *code;
- struct GPUMaterialLibrary *dependencies[8];
-} GPUMaterialLibrary;
-
typedef enum {
FUNCTION_QUAL_IN,
FUNCTION_QUAL_OUT,
@@ -31,20 +30,12 @@ typedef struct GPUFunction {
eGPUType paramtype[MAX_PARAMETER];
GPUFunctionQual paramqual[MAX_PARAMETER];
int totparam;
- GPUMaterialLibrary *library;
+ /* TOOD(@fclem): Clean that void pointer. */
+ void *source; /* GPUSource */
} GPUFunction;
-/* Module */
-
-void gpu_material_library_init(void);
-void gpu_material_library_exit(void);
-
-/* Code Generation */
-
GPUFunction *gpu_material_library_use_function(struct GSet *used_libraries, const char *name);
-char *gpu_material_library_generate_code(struct GSet *used_libraries, const char *frag_lib);
-
-/* Code Parsing */
-const char *gpu_str_skip_token(const char *str, char *token, int max);
-const char *gpu_data_type_to_string(eGPUType type);
+#ifdef __cplusplus
+}
+#endif