Readability changes
This commit is contained in:
parent
867d62edd4
commit
2a1575c5cc
2 changed files with 5 additions and 3 deletions
|
@ -319,8 +319,10 @@ void DoFPass::createPipeline() {
|
|||
}
|
||||
|
||||
void DoFPass::createBokehImage() {
|
||||
int width, height, channels;
|
||||
int width = 0, height = 0, channels = 0;
|
||||
stbi_uc* pixels = stbi_load("data/bokeh.png", &width, &height, &channels, STBI_rgb_alpha);
|
||||
if(pixels == nullptr)
|
||||
return; // haha what
|
||||
|
||||
VkImageCreateInfo imageCreateInfo = {};
|
||||
imageCreateInfo.sType = VK_STRUCTURE_TYPE_IMAGE_CREATE_INFO;
|
||||
|
|
|
@ -152,7 +152,7 @@ Cinematic* loadCinematic(const char* path) {
|
|||
nlohmann::json json;
|
||||
file >> json;
|
||||
|
||||
Cinematic* cinematic = new Cinematic();
|
||||
auto cinematic = new Cinematic();
|
||||
for(auto shotObject : json["shots"]) {
|
||||
Shot* shot = new Shot();
|
||||
shot->start = shotObject["start"];
|
||||
|
@ -166,7 +166,7 @@ Cinematic* loadCinematic(const char* path) {
|
|||
}
|
||||
|
||||
for(auto animationObject : shotObject["animations"]) {
|
||||
Animation* animation = new Animation();
|
||||
auto animation = new Animation();
|
||||
for(auto mesh : shot->meshes) {
|
||||
if(mesh->name == animationObject["target"])
|
||||
animation->target = mesh;
|
||||
|
|
Reference in a new issue