45 #include "eng3d/texture.hpp"
46 #include "eng3d/color.hpp"
47 #include "eng3d/shader.hpp"
48 #include "eng3d/map.hpp"
74 return std::vector<Option>{
75 noise,
sdf,
lighting,
city_lights,
parallax,
rivers,
water,
grid,
units,
trees,
compress
81 void update_visibility();
82 void update_city_lights();
88 std::shared_ptr<Eng3D::Texture> river_tex;
90 std::unique_ptr<Eng3D::Texture> tile_sheet;
91 std::unique_ptr<Eng3D::Texture> tile_sheet_nation;
92 std::unique_ptr<Eng3D::Texture> province_opt;
93 std::unique_ptr<Eng3D::Texture> border_sdf;
95 std::unique_ptr<Eng3D::OpenGL::Program> map_shader;
96 std::unique_ptr<Eng3D::OpenGL::Program> sdf_shader;
97 std::unique_ptr<Eng3D::OpenGL::Program> border_gen_shader;
98 std::unique_ptr<Eng3D::OpenGL::Program> output_shader;
100 std::atomic<bool> req_update_vision =
true;
115 return this->province_opt->buffer[id];
119 return ProvinceId(this->terrain_map->buffer.get()[pos.x + pos.y * this->terrain_map->width] & 0xffff);
Option that is passed to the GLSL transpiler for preprocessing the shaders and programming them on th...
uint32_t get_province_opt(const ProvinceId id)
void request_update_visibility()
ProvinceId get_tile_province_id(size_t x, size_t y)
ProvinceId get_tile_province_id(glm::ivec2 pos)
void update_nations(std::vector< ProvinceId > &nations)
void update_options(MapOptions options)
void update_border_sdf(Eng3D::Rect update_area, glm::ivec2 window_size)
Creates the "waving" border around the continent to give it a 19th century map feel Generate a distan...
void draw(const Eng3D::Camera &camera, MapView view_mode)
void update_mapmode(std::vector< ProvinceColor > &province_colors)
Eng3D::OpenGL::Option Option
OpenGL::Framebuffer Framebuffer
std::vector< Option > get_options()