no clue :) just to push it foo master
authorEleni Maria Stea <estea@igalia.com>
Thu, 21 Mar 2019 21:00:14 +0000 (23:00 +0200)
committerEleni Maria Stea <estea@igalia.com>
Thu, 21 Mar 2019 21:00:14 +0000 (23:00 +0200)
src/main.cc

index affeff7..aeb57a6 100644 (file)
@@ -72,6 +72,7 @@ static TerrainParams p;
 static Texture *skybox_tex;
 static Texture *irradiance_tex;
 static Texture *terrain_tex;
+static Texture *dirt_tex;
 static Material terrain_mat;
 static Renderer *terrain_rend;
 
@@ -136,7 +137,13 @@ static bool init(Gfx_API api)
 
        terrain_tex = gfx_create_texture();
        if(!terrain_tex->load("data/grass.jpeg")) {
-               fprintf(stderr, "Failed to load ground texture.\n");
+               fprintf(stderr, "Failed to load ground grass texture.\n");
+               return false;
+       }
+
+       dirt_tex = gfx_create_texture();
+       if(!dirt_tex->load("data/dirt.jpg")) {
+               fprintf(stderr, "Failed to load ground dirt texture.\n");
                return false;
        }