1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-06 12:20:30 +00:00

Use C++11 raw literals for shader code to improve readability

In files that have lots of branching, `\t` was replaced with a
tab character instead.
This commit is contained in:
Hugo Locurcio
2021-07-19 08:06:51 +02:00
parent b76dfde329
commit abc38b8d66
17 changed files with 1146 additions and 1040 deletions

View File

@@ -9388,7 +9388,13 @@ RendererStorageRD::RendererStorageRD() {
// default material and shader for particles shader
particles_shader.default_shader = shader_allocate();
shader_initialize(particles_shader.default_shader);
shader_set_code(particles_shader.default_shader, "shader_type particles; void process() { COLOR = vec4(1.0); } \n");
shader_set_code(particles_shader.default_shader, R"(
shader_type particles;
void process() {
COLOR = vec4(1.0);
}
)");
particles_shader.default_material = material_allocate();
material_initialize(particles_shader.default_material);
material_set_shader(particles_shader.default_material, particles_shader.default_shader);