index buffer
This commit is contained in:
parent
523852da08
commit
ebacb9540c
2 changed files with 10 additions and 32 deletions
26
main.cpp
26
main.cpp
|
|
@ -10,28 +10,6 @@ typedef VulkanShader<"test2.spirv", "main", VK_SHADER_STAGE_FRAGMENT_BIT, 0, {}>
|
|||
typedef VulkanPipeline<MeshShader, FragmentShader> Pipeline;
|
||||
|
||||
int main() {
|
||||
// WindowWaylandWayland window("test", 128, 128);
|
||||
// UiElement test(
|
||||
// 0.5, //anchorX
|
||||
// 0.5, //anchorY
|
||||
// 2, //bufferWidth
|
||||
// 1, //bufferHeight
|
||||
// std::uint32_t(30), //absoluteSizeX
|
||||
// std::uint32_t(30), //absoluteSizeY
|
||||
// 0.5, //anchorOffsetX
|
||||
// 0.5, //anchorOffsetY
|
||||
// 0, //z
|
||||
// false //ignoreScaling
|
||||
// );
|
||||
// window.scale = 1;
|
||||
// test.buffer = {{255, 0, 0 ,255}, {0, 255, 0 ,255}};
|
||||
// window.elements.AddComponent(&test);
|
||||
// window.Start();
|
||||
// while(true) {
|
||||
|
||||
// }
|
||||
|
||||
//WriteDescriptor(0, VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, 0, &uniformBuffer.descriptor);
|
||||
VulkanDevice::CreateDevice();
|
||||
MeshShader::CreateShader();
|
||||
FragmentShader::CreateShader();
|
||||
|
|
@ -50,8 +28,8 @@ int main() {
|
|||
mesh.verticies.value[2] = {1.0f, 1.0f, 0.0f, 1.0f};
|
||||
|
||||
mesh.indicies.value[0] = 0;
|
||||
mesh.indicies.value[0] = 1;
|
||||
mesh.indicies.value[0] = 2;
|
||||
mesh.indicies.value[1] = 1;
|
||||
mesh.indicies.value[2] = 2;
|
||||
test.WriteDescriptor(0, VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, 1, &mesh.verticies.descriptor);
|
||||
test.WriteDescriptor(0, VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, 2, &mesh.indicies.descriptor);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue