Changeset a79be34 in opengl-game for vulkan-game.cpp
- Timestamp:
- Dec 19, 2019, 4:37:03 PM (5 years ago)
- Branches:
- feature/imgui-sdl, master, points-test
- Children:
- cd1cb0f
- Parents:
- 60578ce
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
vulkan-game.cpp
r60578ce ra79be34 267 267 // TODO: With the normals, indexing basically becomes pointless since no vertices will have exactly 268 268 // the same data. Add an option to make some pipelines not use indexing 269 /*270 269 shipPipeline.addObject( 270 centerObject<ShipVertex>( 271 271 addObjectIndex<ShipVertex>(shipPipeline.getObjects().size(), 272 272 addVertexNormals<ShipVertex>({ … … 466 466 {{ 1.5f, 0.0f, 0.0f}, {0.0f, 0.0f, 0.3f}}, 467 467 {{ 1.3f, 0.0f, -0.3f}, {0.0f, 0.0f, 0.3f}}, 468 })) , {468 }))), { 469 469 0, 1, 2, 3, 4, 5, 470 470 6, 7, 8, 9, 10, 11, … … 497 497 135, 136, 137, 498 498 }, commandPool, graphicsQueue); 499 */500 501 // z-range is 0 to 1, with +1 pointing into the screen502 shipPipeline.addObject(503 addObjectIndex<ShipVertex>(shipPipeline.getObjects().size(),504 addVertexNormals<ShipVertex>({505 {{ 40.0f, 40.0f, 72.0f}, {0.0f, 0.6f, 0.0f}},506 {{ -40.0f, 40.0f, 80.0f}, {0.0f, 0.6f, 0.0f}},507 {{ -40.0f, -40.0f, 80.0f}, {0.0f, 0.6f, 0.0f}},508 {{ 40.0f, 40.0f, 72.0f}, {0.0f, 0.6f, 0.0f}},509 {{ -40.0f, -40.0f, 80.0f}, {0.0f, 0.6f, 0.0f}},510 {{ 40.0f, -40.0f, 72.0f}, {0.0f, 0.6f, 0.0f}},511 512 {{ 8.0f, 8.0f, 34.0f}, {0.0f, 0.0f, 0.7f}},513 {{ -8.0f, 8.0f, 30.0f}, {0.0f, 0.0f, 0.7f}},514 {{ -8.0f, -8.0f, 30.0f}, {0.0f, 0.0f, 0.7f}},515 {{ 8.0f, 8.0f, 34.0f}, {0.0f, 0.0f, 0.7f}},516 {{ -8.0f, -8.0f, 30.0f}, {0.0f, 0.0f, 0.7f}},517 {{ 8.0f, -8.0f, 34.0f}, {0.0f, 0.0f, 0.7f}},518 })), {519 0, 1, 2, 3, 4, 5,520 6, 7, 8, 9, 10, 11,521 }, commandPool, graphicsQueue);522 499 523 500 shipPipeline.createDescriptorSetLayout(); … … 549 526 550 527 float cam_yaw = 0.0f; 551 float cam_pitch = 0.0f; //-50.0f;528 float cam_pitch = -50.0f; 552 529 553 530 mat4 yaw_mat = rotate(mat4(1.0f), radians(-cam_yaw), vec3(0.0f, 1.0f, 0.0f));
Note:
See TracChangeset
for help on using the changeset viewer.