projects
/
demo
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
backup - needs fixing
[demo]
/
src
/
gfxapi.cc
diff --git
a/src/gfxapi.cc
b/src/gfxapi.cc
index
2987a59
..
2dead6f
100644
(file)
--- a/
src/gfxapi.cc
+++ b/
src/gfxapi.cc
@@
-7,6
+7,7
@@
#include "opengl/texture-gl.h"
#include "opengl/shader-gl.h"
#include "opengl/texture-gl.h"
#include "opengl/shader-gl.h"
+#include "vulkan/shader-vk.h"
#include "vulkan/mesh-vk.h"
#include "vulkan/texture-vk.h"
#include "vulkan/mesh-vk.h"
#include "vulkan/texture-vk.h"
@@
-16,7
+17,11
@@
void (*gfx_clear)(float r, float g, float b);
void (*gfx_viewport)(int x, int y, int width, int height);
void (*gfx_zbuffer)(bool enable);
void (*gfx_cull_face)(Gfx_cull_face cf);
void (*gfx_viewport)(int x, int y, int width, int height);
void (*gfx_zbuffer)(bool enable);
void (*gfx_cull_face)(Gfx_cull_face cf);
-
+void (*gfx_reshape)(int width, int height);
+void (*gfx_wireframe)(bool enable);
+void (*gfx_swapbuffers)();
+void (*gfx_begin_drawing)();
+void (*gfx_end_drawing)();
bool gfx_init(Gfx_API api)
{
bool gfx_init(Gfx_API api)
{
@@
-76,8
+81,7
@@
ShaderProgram *gfx_create_shader_program()
case GFX_GL:
return new ShaderProgramGL;
case GFX_VK:
case GFX_GL:
return new ShaderProgramGL;
case GFX_VK:
- // return new ShaderProgramVK;
- return 0;
+ return new ShaderProgramVK;
}
return 0;
}
}
return 0;
}
@@
-88,8
+92,7
@@
Shader *gfx_create_shader()
case GFX_GL:
return new ShaderGL;
case GFX_VK:
case GFX_GL:
return new ShaderGL;
case GFX_VK:
- // return new ShaderVK;
- return 0;
+ return new ShaderVK;
}
return 0;
}
}
return 0;
}
@@
-103,4
+106,4
@@
char *gfx_get_shader_path()
return (char *)"vk_shaders";
}
return (char *)"";
return (char *)"vk_shaders";
}
return (char *)"";
-}
\ No newline at end of file
+}