Vulkan2D
2D renderer written in C using Vulkan and SDL2
Shader.h
Go to the documentation of this file.
1 #pragma once
5 #include "VK2D/Structs.h"
6 #include "VK2D/Constants.h"
7 
8 #ifdef __cplusplus
9 extern "C" {
10 #endif
11 
24 VK2DShader vk2dShaderLoad(const char *vertexShader, const char *fragmentShader, uint32_t uniformBufferSize);
25 
40 VK2DShader vk2dShaderFrom(uint8_t *vertexShaderBuffer, int vertexShaderBufferSize, uint8_t *fragmentShaderBuffer, int fragmentShaderBufferSize, uint32_t uniformBufferSize);
41 
44 void vk2dShaderFree(VK2DShader shader);
45 
46 #ifdef __cplusplus
47 }
48 #endif
void vk2dShaderFree(VK2DShader shader)
Frees a shader from memory.
VK2DShader vk2dShaderLoad(const char *vertexShader, const char *fragmentShader, uint32_t uniformBufferSize)
Creates a shader you can use to render textures.
VK2DShader vk2dShaderFrom(uint8_t *vertexShaderBuffer, int vertexShaderBufferSize, uint8_t *fragmentShaderBuffer, int fragmentShaderBufferSize, uint32_t uniformBufferSize)
Creates a shader you can use to render textures from an in-memory buffer.
Forward declares struct typedefs.