diff --git a/armorcore/sources/ts/render_path.ts b/armorcore/sources/ts/render_path.ts index 9b2c229b..2c4e8d47 100644 --- a/armorcore/sources/ts/render_path.ts +++ b/armorcore/sources/ts/render_path.ts @@ -9,7 +9,6 @@ type render_target_t = { depth_buffer?: string; // 2D texture mipmaps?: bool; depth?: i32; // 3D texture - is_image?: bool; // Image // Runtime _depth_format?: depth_format_t; _depth_from?: string; @@ -430,15 +429,9 @@ function render_path_create_image(t: render_target_t, depth_format: depth_format return img; } else { // 2D texture - if (t.is_image) { // Image - return image_create(width, height, - t.format != null ? render_path_get_tex_format(t.format) : tex_format_t.RGBA32); - } - else { // Render target - return image_create_render_target(width, height, - t.format != null ? render_path_get_tex_format(t.format) : tex_format_t.RGBA32, - depth_format); - } + return image_create_render_target(width, height, + t.format != null ? render_path_get_tex_format(t.format) : tex_format_t.RGBA32, + depth_format); } } @@ -485,7 +478,6 @@ function render_target_create(): render_target_t { raw.scale = 1.0; raw.mipmaps = false; raw.depth = 1; - raw.is_image = false; raw._depth_from = ""; raw._has_depth = false; return raw; diff --git a/armorcore/sources/ts/scene.ts b/armorcore/sources/ts/scene.ts index 8fcb8157..4455a7db 100644 --- a/armorcore/sources/ts/scene.ts +++ b/armorcore/sources/ts/scene.ts @@ -692,7 +692,6 @@ type shader_const_t = { type tex_unit_t = { name?: string; link?: string; - image_uniform?: bool; // uniform layout(r8) writeonly image3D voxels }; type speaker_data_t = { diff --git a/armorcore/sources/ts/uniforms.ts b/armorcore/sources/ts/uniforms.ts index e957857d..812ed360 100644 --- a/armorcore/sources/ts/uniforms.ts +++ b/armorcore/sources/ts/uniforms.ts @@ -117,12 +117,8 @@ function uniforms_bind_render_target(rt: render_target_t, context: shader_contex for (let j: i32 = 0; j < tus.length; ++j) { // Set texture if (sampler_id == tus[j].name) { - let is_image: bool = tus[j].image_uniform; - if (is_image) { - g4_set_image_tex(context._.tex_units[j], rt._image); // image2D/3D - } - else if (attach_depth) { + if (attach_depth) { g4_set_tex_depth(context._.tex_units[j], rt._image); // sampler2D } else { @@ -134,12 +130,6 @@ function uniforms_bind_render_target(rt: render_target_t, context: shader_contex continue; } - if (is_image) { - // Multiple voxel volumes, always set params - g4_set_tex_3d_params(context._.tex_units[j], tex_addressing_t.CLAMP, tex_addressing_t.CLAMP, tex_addressing_t.CLAMP, tex_filter_t.LINEAR, tex_filter_t.POINT, mip_map_filter_t.LINEAR); - continue; - } - if (rt.mipmaps) { g4_set_tex_params(context._.tex_units[j], tex_addressing_t.CLAMP, tex_addressing_t.CLAMP, tex_filter_t.LINEAR, tex_filter_t.LINEAR, mip_map_filter_t.LINEAR); continue; diff --git a/armorpaint/sources/make_bake.ts b/armorpaint/sources/make_bake.ts index 9d3410bb..be7eaf3f 100644 --- a/armorpaint/sources/make_bake.ts +++ b/armorpaint/sources/make_bake.ts @@ -1,8 +1,6 @@ function make_bake_run(con: node_shader_context_t, vert: node_shader_t, frag: node_shader_t) { - if (context_raw.bake_type == bake_type_t.AO) { // Voxel - } - else if (context_raw.bake_type == bake_type_t.CURVATURE) { + if (context_raw.bake_type == bake_type_t.CURVATURE) { let pass: bool = parser_material_bake_passthrough; let strength: string = pass ? parser_material_bake_passthrough_strength : context_raw.bake_curv_strength + ""; let radius: string = pass ? parser_material_bake_passthrough_radius : context_raw.bake_curv_radius + ""; diff --git a/base/assets/Scene.arm b/base/assets/Scene.arm index 78b2a9cb..66f2a882 100644 Binary files a/base/assets/Scene.arm and b/base/assets/Scene.arm differ diff --git a/base/assets/readme/readme_dxr.txt b/base/assets/readme/readme_dxr.txt deleted file mode 100644 index a5c2cf39..00000000 --- a/base/assets/readme/readme_dxr.txt +++ /dev/null @@ -1,20 +0,0 @@ -! This is an experimental build with hardware accelerated ray-tracing using DXR and Direct3D12 ! - -Supported GPUs: -- NVIDIA RTX 20 Series or better -- AMD RX 6800 XT or better - -Up to date Windows 10/11 and graphics drivers required. - -Learn more: -https://en.wikipedia.org/wiki/DirectX_Raytracing - -This build is only intended for testing ray-tracing features and -may be sub-par in other areas compared to regular builds. - -Currently exposed ray-tracing features: -- Bake Tool - AO -- Bake Tool - Bent Normal -- Bake Tool - Lightmap -- Bake Tool - Thickness -- Viewport Mode - Path-Trace diff --git a/base/assets/readme/readme_vkrt.txt b/base/assets/readme/readme_vkrt.txt deleted file mode 100644 index 19f47f57..00000000 --- a/base/assets/readme/readme_vkrt.txt +++ /dev/null @@ -1,21 +0,0 @@ -! This is an experimental build with hardware accelerated ray-tracing powered by Vulkan Ray Tracing ! - -Supported GPUs: -- NVIDIA RTX 20 Series or better -- AMD RX 6800 XT or better - -Requires Vulkan driver 455.46.04 or newer on NVIDIA cards: -https://developer.nvidia.com/vulkan-driver - -Learn more: -https://www.khronos.org/blog/ray-tracing-in-vulkan - -This build is only intended for testing ray-tracing features and -may be sub-par in other areas compared to regular builds. - -Currently exposed ray-tracing features: -- Bake Tool - AO -- Bake Tool - Bent Normal -- Bake Tool - Lightmap -- Bake Tool - Thickness -- Viewport Mode - Path-Trace diff --git a/base/assets/shader_datas.arm b/base/assets/shader_datas.arm index 3cac2165..01c65fb4 100644 Binary files a/base/assets/shader_datas.arm and b/base/assets/shader_datas.arm differ diff --git a/base/project.js b/base/project.js index 72bb2bc3..7596fe7e 100644 --- a/base/project.js +++ b/base/project.js @@ -92,11 +92,9 @@ if (flags.raytrace) { if (flags.d3d12) { project.add_assets("shaders/raytrace/*.cso", { destination: "data/{name}" }); - project.add_assets("assets/readme/readme_dxr.txt", { destination: "{name}" }); } else if (flags.vulkan) { project.add_assets("shaders/raytrace/*.spirv", { destination: "data/{name}" }); - project.add_assets("assets/readme/readme_vkrt.txt", { destination: "{name}" }); } else if (flags.metal) { project.add_assets("shaders/raytrace/*.metal", { destination: "data/{name}" }); diff --git a/base/sources/node_shader.ts b/base/sources/node_shader.ts index 9f0c2bdb..4d41d8e1 100644 --- a/base/sources/node_shader.ts +++ b/base/sources/node_shader.ts @@ -55,12 +55,11 @@ function node_shader_add_out(raw: node_shader_t, s: string) { function node_shader_add_uniform(raw: node_shader_t, s: string, link: string = null) { let ar: string[] = string_split(s, " "); - // layout(RGBA8) image3D voxels + // layout(RGBA8) sampler2D tex let utype: string = ar[ar.length - 2]; let uname: string = ar[ar.length - 1]; - if (starts_with(utype, "sampler") || starts_with(utype, "image") || starts_with(utype, "uimage")) { - let is_image: bool = (starts_with(utype, "image") || starts_with(utype, "uimage")) ? true : false; - node_shader_context_add_texture_unit(raw.context, utype, uname, link, is_image); + if (starts_with(utype, "sampler")) { + node_shader_context_add_texture_unit(raw.context, utype, uname, link); } else { // Prefer vec4[] for d3d to avoid padding @@ -86,7 +85,7 @@ function node_shader_add_shared_sampler(raw: node_shader_t, s: string) { // layout(RGBA8) sampler2D tex let utype: string = ar[ar.length - 2]; let uname: string = ar[ar.length - 1]; - node_shader_context_add_texture_unit(raw.context, utype, uname, null, false); + node_shader_context_add_texture_unit(raw.context, utype, uname, null); } } diff --git a/base/sources/node_shader_context.ts b/base/sources/node_shader_context.ts index 135e542b..e1f32d92 100644 --- a/base/sources/node_shader_context.ts +++ b/base/sources/node_shader_context.ts @@ -106,7 +106,7 @@ function node_shader_context_add_constant(raw: node_shader_context_t, ctype: str array_push(raw.constants, c); } -function node_shader_context_add_texture_unit(raw: node_shader_context_t, ctype: string, name: string, link: string = null, is_image: bool = false) { +function node_shader_context_add_texture_unit(raw: node_shader_context_t, ctype: string, name: string, link: string = null) { for (let i: i32 = 0; i < raw.tunits.length; ++i) { let c: tex_unit_t = raw.tunits[i]; if (c.name == name) { @@ -118,9 +118,6 @@ function node_shader_context_add_texture_unit(raw: node_shader_context_t, ctype: if (link != null) { c.link = link; } - if (is_image) { - c.image_uniform = is_image; - } array_push(raw.tunits, c); } diff --git a/base/sources/util_clone.ts b/base/sources/util_clone.ts index 357dc7f5..94392710 100644 --- a/base/sources/util_clone.ts +++ b/base/sources/util_clone.ts @@ -183,7 +183,6 @@ function util_clone_tex_units(units: tex_unit_t[]): tex_unit_t[] { let u: tex_unit_t = {}; u.name = units[i].name; u.link = units[i].link; - u.image_uniform = units[i].image_uniform; array_push(r, u); } return r;