diff --git a/src/back/glsl/features.rs b/src/back/glsl/features.rs index 6bb5b18888..8a5da1b6e1 100644 --- a/src/back/glsl/features.rs +++ b/src/back/glsl/features.rs @@ -41,8 +41,6 @@ bitflags::bitflags! { const TEXTURE_LEVELS = 1 << 19; /// Image size query const IMAGE_SIZE = 1 << 20; - /// Dual source blending - const DUAL_SOURCE_BLENDING = 1 << 21; } } @@ -106,7 +104,6 @@ impl FeaturesManager { check_feature!(CULL_DISTANCE, 450, 300 /* with extension */); check_feature!(SAMPLE_VARIABLES, 400, 300); check_feature!(DYNAMIC_ARRAY_SIZE, 430, 310); - check_feature!(DUAL_SOURCE_BLENDING, 330, 300 /* with extension */); match version { Version::Embedded { is_webgl: true, .. } => check_feature!(MULTI_VIEW, 140, 300), _ => check_feature!(MULTI_VIEW, 140, 310), @@ -236,10 +233,6 @@ impl FeaturesManager { // https://www.khronos.org/registry/OpenGL/extensions/ARB/ARB_texture_query_levels.txt writeln!(out, "#extension GL_ARB_texture_query_levels : require")?; } - if self.0.contains(Features::DUAL_SOURCE_BLENDING) && version.is_es() { - // https://registry.khronos.org/OpenGL/extensions/EXT/EXT_blend_func_extended.txt - writeln!(out, "#extension GL_EXT_blend_func_extended : require")?; - } Ok(()) } @@ -504,7 +497,6 @@ impl<'a, W> Writer<'a, W> { location: _, interpolation, sampling, - second_blend_source, } => { if interpolation == Some(Interpolation::Linear) { self.features.request(Features::NOPERSPECTIVE_QUALIFIER); @@ -512,9 +504,6 @@ impl<'a, W> Writer<'a, W> { if sampling == Some(Sampling::Sample) { self.features.request(Features::SAMPLE_QUALIFIER); } - if second_blend_source { - self.features.request(Features::DUAL_SOURCE_BLENDING); - } } } } diff --git a/src/back/glsl/mod.rs b/src/back/glsl/mod.rs index 4b732a6038..ef5dd0143f 100644 --- a/src/back/glsl/mod.rs +++ b/src/back/glsl/mod.rs @@ -333,12 +333,6 @@ struct VaryingName<'a> { impl fmt::Display for VaryingName<'_> { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { match *self.binding { - crate::Binding::Location { - second_blend_source: true, - .. - } => { - write!(f, "_fs2p_location1",) - } crate::Binding::Location { location, .. } => { let prefix = match (self.stage, self.output) { (ShaderStage::Compute, _) => unreachable!(), @@ -1241,13 +1235,12 @@ impl<'a, W: Write> Writer<'a, W> { Some(binding) => binding, }; - let (location, interpolation, sampling, second_blend_source) = match *binding { + let (location, interpolation, sampling) = match *binding { crate::Binding::Location { location, interpolation, sampling, - second_blend_source, - } => (location, interpolation, sampling, second_blend_source), + } => (location, interpolation, sampling), crate::Binding::BuiltIn(built_in) => { if let crate::BuiltIn::Position { invariant: true } = built_in { match (self.options.version, self.entry_point.stage) { @@ -1288,11 +1281,7 @@ impl<'a, W: Write> Writer<'a, W> { // Write the I/O locations, if allowed if self.options.version.supports_explicit_locations() || !emit_interpolation_and_auxiliary { - if second_blend_source { - write!(self.out, "layout(location = {location}, index = 1) ")?; - } else { - write!(self.out, "layout(location = {location}) ")?; - } + write!(self.out, "layout(location = {location}) ")?; } // Write the interpolation qualifier. @@ -1329,7 +1318,6 @@ impl<'a, W: Write> Writer<'a, W> { location, interpolation: None, sampling: None, - second_blend_source, }, stage: self.entry_point.stage, output, diff --git a/src/back/hlsl/writer.rs b/src/back/hlsl/writer.rs index c37334b60d..4f19126388 100644 --- a/src/back/hlsl/writer.rs +++ b/src/back/hlsl/writer.rs @@ -416,17 +416,7 @@ impl<'a, W: fmt::Write> super::Writer<'a, W> { let builtin_str = builtin.to_hlsl_str()?; write!(self.out, " : {builtin_str}")?; } - crate::Binding::Location { - second_blend_source: true, - .. - } => { - write!(self.out, " : SV_Target1")?; - } - crate::Binding::Location { - location, - second_blend_source: false, - .. - } => { + crate::Binding::Location { location, .. } => { if stage == Some((crate::ShaderStage::Fragment, Io::Output)) { write!(self.out, " : SV_Target{location}")?; } else { diff --git a/src/back/msl/mod.rs b/src/back/msl/mod.rs index 819d48a8fd..78bcc2123b 100644 --- a/src/back/msl/mod.rs +++ b/src/back/msl/mod.rs @@ -82,10 +82,7 @@ pub type EntryPointResourceMap = std::collections::BTreeMap match mode { LocationMode::VertexInput => Ok(ResolvedBinding::Attribute(location)), - LocationMode::FragmentOutput => { - if second_blend_source && self.lang_version < (1, 2) { - return Err(Error::UnsupportedAttribute( - "second_blend_source".to_string(), - )); - } - Ok(ResolvedBinding::Color { - location, - second_blend_source, - }) - } + LocationMode::FragmentOutput => Ok(ResolvedBinding::Color(location)), LocationMode::VertexOutput | LocationMode::FragmentInput => { Ok(ResolvedBinding::User { prefix: if self.spirv_cross_compatibility { @@ -418,16 +404,7 @@ impl ResolvedBinding { write!(out, "{name}")?; } Self::Attribute(index) => write!(out, "attribute({index})")?, - Self::Color { - location, - second_blend_source, - } => { - if second_blend_source { - write!(out, "color({location}) index(1)")? - } else { - write!(out, "color({location})")? - } - } + Self::Color(index) => write!(out, "color({index})")?, Self::User { prefix, index, diff --git a/src/back/spv/writer.rs b/src/back/spv/writer.rs index 41a13cbc19..e6db93602a 100644 --- a/src/back/spv/writer.rs +++ b/src/back/spv/writer.rs @@ -1434,7 +1434,6 @@ impl Writer { location, interpolation, sampling, - second_blend_source, } => { self.decorate(id, Decoration::Location, &[location]); @@ -1474,9 +1473,6 @@ impl Writer { } } } - if second_blend_source { - self.decorate(id, Decoration::Index, &[1]); - } } crate::Binding::BuiltIn(built_in) => { use crate::BuiltIn as Bi; diff --git a/src/back/wgsl/writer.rs b/src/back/wgsl/writer.rs index 43d094ec2e..44dd2a97c0 100644 --- a/src/back/wgsl/writer.rs +++ b/src/back/wgsl/writer.rs @@ -17,7 +17,6 @@ enum Attribute { Invariant, Interpolate(Option, Option), Location(u32), - SecondBlendSource, Stage(ShaderStage), WorkGroupSize([u32; 3]), } @@ -320,7 +319,6 @@ impl Writer { for attribute in attributes { match *attribute { Attribute::Location(id) => write!(self.out, "@location({id}) ")?, - Attribute::SecondBlendSource => write!(self.out, "@second_blend_source ")?, Attribute::BuiltIn(builtin_attrib) => { let builtin = builtin_str(builtin_attrib)?; write!(self.out, "@builtin({builtin}) ")?; @@ -1919,20 +1917,9 @@ fn map_binding_to_attribute(binding: &crate::Binding) -> Vec { location, interpolation, sampling, - second_blend_source: false, } => vec![ Attribute::Location(location), Attribute::Interpolate(interpolation, sampling), ], - crate::Binding::Location { - location, - interpolation, - sampling, - second_blend_source: true, - } => vec![ - Attribute::Location(location), - Attribute::SecondBlendSource, - Attribute::Interpolate(interpolation, sampling), - ], } } diff --git a/src/front/glsl/functions.rs b/src/front/glsl/functions.rs index 7dee023743..f448272583 100644 --- a/src/front/glsl/functions.rs +++ b/src/front/glsl/functions.rs @@ -1294,7 +1294,6 @@ impl Frontend { location, interpolation, sampling: None, - second_blend_source: false, }; location += 1; @@ -1337,7 +1336,6 @@ impl Frontend { location, interpolation, sampling: None, - second_blend_source: false, }; location += 1; binding diff --git a/src/front/glsl/variables.rs b/src/front/glsl/variables.rs index ad0bd7cbd2..a9a403e402 100644 --- a/src/front/glsl/variables.rs +++ b/src/front/glsl/variables.rs @@ -475,7 +475,6 @@ impl Frontend { location, interpolation, sampling, - second_blend_source: false, }, handle, storage, diff --git a/src/front/interpolator.rs b/src/front/interpolator.rs index 0196a2254d..96f5db6ff7 100644 --- a/src/front/interpolator.rs +++ b/src/front/interpolator.rs @@ -43,7 +43,6 @@ impl crate::Binding { location: _, interpolation: ref mut interpolation @ None, ref mut sampling, - second_blend_source: _, } = *self { match ty.scalar_kind() { diff --git a/src/front/spv/mod.rs b/src/front/spv/mod.rs index 36108fdd9b..a210e8c421 100644 --- a/src/front/spv/mod.rs +++ b/src/front/spv/mod.rs @@ -255,7 +255,6 @@ impl Decoration { location, interpolation, sampling, - second_blend_source: false, }), _ => Err(Error::MissingDecoration(spirv::Decoration::Location)), } diff --git a/src/front/wgsl/parse/mod.rs b/src/front/wgsl/parse/mod.rs index 86dd12799d..4a9aafc5f7 100644 --- a/src/front/wgsl/parse/mod.rs +++ b/src/front/wgsl/parse/mod.rs @@ -143,7 +143,6 @@ impl ParsedAttribute { #[derive(Default)] struct BindingParser { location: ParsedAttribute, - second_blend_source: ParsedAttribute, built_in: ParsedAttribute, interpolation: ParsedAttribute, sampling: ParsedAttribute, @@ -183,9 +182,6 @@ impl BindingParser { } lexer.expect(Token::Paren(')'))?; } - "second_blend_source" => { - self.second_blend_source.set(true, name_span)?; - } "invariant" => { self.invariant.set(true, name_span)?; } @@ -212,7 +208,6 @@ impl BindingParser { location, interpolation, sampling, - second_blend_source: self.second_blend_source.value.unwrap_or(false), })) } (None, Some(crate::BuiltIn::Position { .. }), None, None, invariant) => { diff --git a/src/lib.rs b/src/lib.rs index fdea215e33..a1f7ef1654 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -922,8 +922,6 @@ pub enum Binding { /// [`Fragment`]: crate::ShaderStage::Fragment Location { location: u32, - /// Indicates the 2nd input to the blender when dual-source blending. - second_blend_source: bool, interpolation: Option, sampling: Option, }, diff --git a/src/valid/analyzer.rs b/src/valid/analyzer.rs index e4162e15f5..1e75c5af6c 100644 --- a/src/valid/analyzer.rs +++ b/src/valid/analyzer.rs @@ -256,9 +256,6 @@ pub struct FunctionInfo { /// /// [`GlobalVariable`]: crate::GlobalVariable sampling: crate::FastHashSet, - - /// Indicates that the function is using dual source blending. - pub dual_source_blending: bool, } impl FunctionInfo { @@ -1002,7 +999,6 @@ impl ModuleInfo { global_uses: vec![GlobalUse::empty(); module.global_variables.len()].into_boxed_slice(), expressions: vec![ExpressionInfo::new(); fun.expressions.len()].into_boxed_slice(), sampling: crate::FastHashSet::default(), - dual_source_blending: false, }; let resolve_context = ResolveContext::with_locals(module, &fun.local_variables, &fun.arguments); @@ -1112,7 +1108,6 @@ fn uniform_control_flow() { global_uses: vec![GlobalUse::empty(); global_var_arena.len()].into_boxed_slice(), expressions: vec![ExpressionInfo::new(); expressions.len()].into_boxed_slice(), sampling: crate::FastHashSet::default(), - dual_source_blending: false, }; let resolve_context = ResolveContext { constants: &Arena::new(), diff --git a/src/valid/interface.rs b/src/valid/interface.rs index d788a54a34..2e54df2478 100644 --- a/src/valid/interface.rs +++ b/src/valid/interface.rs @@ -61,17 +61,6 @@ pub enum VaryingError { DuplicateBuiltIn(crate::BuiltIn), #[error("Capability {0:?} is not supported")] UnsupportedCapability(Capabilities), - #[error("The attribute {0:?} is only valid as an output for stage {1:?}")] - InvalidInputAttributeInStage(&'static str, crate::ShaderStage), - #[error("The attribute {0:?} is not valid for stage {1:?}")] - InvalidAttributeInStage(&'static str, crate::ShaderStage), - #[error( - "The location index {location} cannot be used together with the attribute {attribute:?}" - )] - InvalidLocationAttributeCombination { - location: u32, - attribute: &'static str, - }, } #[derive(Clone, Debug, thiserror::Error)] @@ -100,10 +89,6 @@ pub enum EntryPointError { InvalidIntegerInterpolation { location: u32 }, #[error(transparent)] Function(#[from] FunctionError), - #[error( - "Invalid locations {location_mask:?} are set while dual source blending. Only location 0 may be set." - )] - InvalidLocationsWhileDualSourceBlending { location_mask: BitSet }, } #[cfg(feature = "validate")] @@ -121,7 +106,6 @@ fn storage_usage(access: crate::StorageAccess) -> GlobalUse { struct VaryingContext<'a> { stage: crate::ShaderStage, output: bool, - second_blend_source: bool, types: &'a UniqueArena, type_info: &'a Vec, location_mask: &'a mut BitSet, @@ -309,7 +293,6 @@ impl VaryingContext<'_> { location, interpolation, sampling, - second_blend_source, } => { // Only IO-shareable types may be stored in locations. if !self.type_info[ty.index()] @@ -318,37 +301,7 @@ impl VaryingContext<'_> { { return Err(VaryingError::NotIOShareableType(ty)); } - - if second_blend_source { - if !self - .capabilities - .contains(Capabilities::DUAL_SOURCE_BLENDING) - { - return Err(VaryingError::UnsupportedCapability( - Capabilities::DUAL_SOURCE_BLENDING, - )); - } - if self.stage != crate::ShaderStage::Fragment { - return Err(VaryingError::InvalidAttributeInStage( - "second_blend_source", - self.stage, - )); - } - if !self.output { - return Err(VaryingError::InvalidInputAttributeInStage( - "second_blend_source", - self.stage, - )); - } - if location != 0 { - return Err(VaryingError::InvalidLocationAttributeCombination { - location, - attribute: "second_blend_source", - }); - } - - self.second_blend_source = true; - } else if !self.location_mask.insert(location as usize) { + if !self.location_mask.insert(location as usize) { #[cfg(feature = "validate")] if self.flags.contains(super::ValidationFlags::BINDINGS) { return Err(VaryingError::BindingCollision { location }); @@ -614,7 +567,7 @@ impl super::Validator { return Err(EntryPointError::UnexpectedWorkgroupSize.with_span()); } - let mut info = self + let info = self .validate_function(&ep.function, module, mod_info, true) .map_err(WithSpan::into_other)?; @@ -640,7 +593,6 @@ impl super::Validator { let mut ctx = VaryingContext { stage: ep.stage, output: false, - second_blend_source: false, types: &module.types, type_info: &self.types, location_mask: &mut self.location_mask, @@ -660,7 +612,6 @@ impl super::Validator { let mut ctx = VaryingContext { stage: ep.stage, output: true, - second_blend_source: false, types: &module.types, type_info: &self.types, location_mask: &mut self.location_mask, @@ -672,18 +623,6 @@ impl super::Validator { }; ctx.validate(fr.ty, fr.binding.as_ref()) .map_err_inner(|e| EntryPointError::Result(e).with_span())?; - #[cfg(feature = "validate")] - if ctx.second_blend_source { - // Only the first location may be used whhen dual source blending - if ctx.location_mask.len() == 1 && ctx.location_mask.contains(0) { - info.dual_source_blending = true; - } else { - return Err(EntryPointError::InvalidLocationsWhileDualSourceBlending { - location_mask: self.location_mask.clone(), - } - .with_span()); - } - } #[cfg(feature = "validate")] if ep.stage == crate::ShaderStage::Vertex diff --git a/src/valid/mod.rs b/src/valid/mod.rs index 5351287725..b04d69b5b4 100644 --- a/src/valid/mod.rs +++ b/src/valid/mod.rs @@ -112,8 +112,6 @@ bitflags::bitflags! { const MULTISAMPLED_SHADING = 0x800; /// Support for ray queries and acceleration structures. const RAY_QUERY = 0x1000; - /// Support for generating two sources for blending from fragement shaders - const DUAL_SOURCE_BLENDING = 0x2000; } } diff --git a/tests/in/dualsource.param.ron b/tests/in/dualsource.param.ron deleted file mode 100644 index 1cf512c6c4..0000000000 --- a/tests/in/dualsource.param.ron +++ /dev/null @@ -1,13 +0,0 @@ -( - god_mode: true, - vertex:[ - ], - fragment:[ - ( - entry_point:"main", - target_profile:"ps_5_1", - ), - ], - compute:[ - ], -) diff --git a/tests/in/dualsource.wgsl b/tests/in/dualsource.wgsl deleted file mode 100644 index e7b658ef7d..0000000000 --- a/tests/in/dualsource.wgsl +++ /dev/null @@ -1,11 +0,0 @@ -/* Simple test for multiple output sources from fragment shaders */ -struct FragmentOutput{ - @location(0) color: vec4, - @location(0) @second_blend_source mask: vec4, -} -@fragment -fn main(@builtin(position) position: vec4) -> FragmentOutput { - var color = vec4(0.4,0.3,0.2,0.1); - var mask = vec4(0.9,0.8,0.7,0.6); - return FragmentOutput(color, mask); -} diff --git a/tests/out/analysis/access.info.ron b/tests/out/analysis/access.info.ron index 03186d9f18..62e898d3c0 100644 --- a/tests/out/analysis/access.info.ron +++ b/tests/out/analysis/access.info.ron @@ -1251,7 +1251,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -2809,7 +2808,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -2849,7 +2847,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -2922,7 +2919,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -2965,7 +2961,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -3055,7 +3050,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ], entry_points: [ @@ -3733,7 +3727,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -4191,7 +4184,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -4296,7 +4288,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ], const_expression_types: [ diff --git a/tests/out/analysis/collatz.info.ron b/tests/out/analysis/collatz.info.ron index 8241bf9a15..c0c222ba48 100644 --- a/tests/out/analysis/collatz.info.ron +++ b/tests/out/analysis/collatz.info.ron @@ -273,7 +273,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ], entry_points: [ @@ -427,7 +426,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ], const_expression_types: [], diff --git a/tests/out/analysis/shadow.info.ron b/tests/out/analysis/shadow.info.ron index 7459466e2e..8af61bff53 100644 --- a/tests/out/analysis/shadow.info.ron +++ b/tests/out/analysis/shadow.info.ron @@ -766,7 +766,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ( flags: ("EXPRESSIONS | BLOCKS | CONTROL_FLOW_UNIFORMITY | STRUCT_LAYOUTS | CONSTANTS | BINDINGS"), @@ -2092,7 +2091,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ], entry_points: [ @@ -2185,7 +2183,6 @@ ), ], sampling: [], - dual_source_blending: false, ), ], const_expression_types: [ diff --git a/tests/out/glsl/dualsource.main.Fragment.glsl b/tests/out/glsl/dualsource.main.Fragment.glsl deleted file mode 100644 index 9ac463c2b3..0000000000 --- a/tests/out/glsl/dualsource.main.Fragment.glsl +++ /dev/null @@ -1,27 +0,0 @@ -#version 310 es -#extension GL_EXT_blend_func_extended : require - -precision highp float; -precision highp int; - -struct FragmentOutput { - vec4 color; - vec4 mask; -}; -layout(location = 0) out vec4 _fs2p_location0; -layout(location = 0, index = 1) out vec4 _fs2p_location1; - -void main() { - vec4 position = gl_FragCoord; - vec4 color = vec4(0.0); - vec4 mask = vec4(0.0); - color = vec4(0.4, 0.3, 0.2, 0.1); - mask = vec4(0.9, 0.8, 0.7, 0.6); - vec4 _e13 = color; - vec4 _e14 = mask; - FragmentOutput _tmp_return = FragmentOutput(_e13, _e14); - _fs2p_location0 = _tmp_return.color; - _fs2p_location1 = _tmp_return.mask; - return; -} - diff --git a/tests/out/hlsl/dualsource.hlsl b/tests/out/hlsl/dualsource.hlsl deleted file mode 100644 index 1d5b53d6f8..0000000000 --- a/tests/out/hlsl/dualsource.hlsl +++ /dev/null @@ -1,29 +0,0 @@ -struct FragmentOutput { - float4 color : SV_Target0; - float4 mask : SV_Target1; -}; - -struct FragmentInput_main { - float4 position_1 : SV_Position; -}; - -FragmentOutput ConstructFragmentOutput(float4 arg0, float4 arg1) { - FragmentOutput ret = (FragmentOutput)0; - ret.color = arg0; - ret.mask = arg1; - return ret; -} - -FragmentOutput main(FragmentInput_main fragmentinput_main) -{ - float4 position = fragmentinput_main.position_1; - float4 color = (float4)0; - float4 mask = (float4)0; - - color = float4(0.4, 0.3, 0.2, 0.1); - mask = float4(0.9, 0.8, 0.7, 0.6); - float4 _expr13 = color; - float4 _expr14 = mask; - const FragmentOutput fragmentoutput = ConstructFragmentOutput(_expr13, _expr14); - return fragmentoutput; -} diff --git a/tests/out/hlsl/dualsource.ron b/tests/out/hlsl/dualsource.ron deleted file mode 100644 index 341a4c528e..0000000000 --- a/tests/out/hlsl/dualsource.ron +++ /dev/null @@ -1,12 +0,0 @@ -( - vertex:[ - ], - fragment:[ - ( - entry_point:"main", - target_profile:"ps_5_1", - ), - ], - compute:[ - ], -) diff --git a/tests/out/ir/access.ron b/tests/out/ir/access.ron index 5cda4104cd..7447249127 100644 --- a/tests/out/ir/access.ron +++ b/tests/out/ir/access.ron @@ -2052,7 +2052,6 @@ ty: 26, binding: Some(Location( location: 0, - second_blend_source: false, interpolation: Some(Perspective), sampling: Some(Center), )), diff --git a/tests/out/ir/shadow.ron b/tests/out/ir/shadow.ron index 9ae5af0003..246657255b 100644 --- a/tests/out/ir/shadow.ron +++ b/tests/out/ir/shadow.ron @@ -1264,7 +1264,6 @@ ty: 2, binding: Some(Location( location: 0, - second_blend_source: false, interpolation: Some(Perspective), sampling: Some(Center), )), @@ -1274,7 +1273,6 @@ ty: 4, binding: Some(Location( location: 1, - second_blend_source: false, interpolation: Some(Perspective), sampling: Some(Center), )), @@ -1284,7 +1282,6 @@ ty: 4, binding: Some(Location( location: 0, - second_blend_source: false, interpolation: None, sampling: None, )), diff --git a/tests/out/msl/dualsource.msl b/tests/out/msl/dualsource.msl deleted file mode 100644 index 92b1909f8b..0000000000 --- a/tests/out/msl/dualsource.msl +++ /dev/null @@ -1,29 +0,0 @@ -// language: metal2.0 -#include -#include - -using metal::uint; - -struct FragmentOutput { - metal::float4 color; - metal::float4 mask; -}; - -struct main_Input { -}; -struct main_Output { - metal::float4 color [[color(0)]]; - metal::float4 mask [[color(0) index(1)]]; -}; -fragment main_Output main_( - metal::float4 position [[position]] -) { - metal::float4 color = {}; - metal::float4 mask = {}; - color = metal::float4(0.4, 0.3, 0.2, 0.1); - mask = metal::float4(0.9, 0.8, 0.7, 0.6); - metal::float4 _e13 = color; - metal::float4 _e14 = mask; - const auto _tmp = FragmentOutput {_e13, _e14}; - return main_Output { _tmp.color, _tmp.mask }; -} diff --git a/tests/out/spv/dualsource.spvasm b/tests/out/spv/dualsource.spvasm deleted file mode 100644 index 0fba6bb269..0000000000 --- a/tests/out/spv/dualsource.spvasm +++ /dev/null @@ -1,55 +0,0 @@ -; SPIR-V -; Version: 1.1 -; Generator: rspirv -; Bound: 35 -OpCapability Shader -%1 = OpExtInstImport "GLSL.std.450" -OpMemoryModel Logical GLSL450 -OpEntryPoint Fragment %17 "main" %11 %14 %16 -OpExecutionMode %17 OriginUpperLeft -OpMemberDecorate %5 0 Offset 0 -OpMemberDecorate %5 1 Offset 16 -OpDecorate %11 BuiltIn FragCoord -OpDecorate %14 Location 0 -OpDecorate %16 Location 0 -OpDecorate %16 Index 1 -%2 = OpTypeVoid -%4 = OpTypeFloat 32 -%3 = OpTypeVector %4 4 -%5 = OpTypeStruct %3 %3 -%7 = OpTypePointer Function %3 -%8 = OpConstantNull %3 -%12 = OpTypePointer Input %3 -%11 = OpVariable %12 Input -%15 = OpTypePointer Output %3 -%14 = OpVariable %15 Output -%16 = OpVariable %15 Output -%18 = OpTypeFunction %2 -%19 = OpConstant %4 0.4 -%20 = OpConstant %4 0.3 -%21 = OpConstant %4 0.2 -%22 = OpConstant %4 0.1 -%23 = OpConstant %4 0.9 -%24 = OpConstant %4 0.8 -%25 = OpConstant %4 0.7 -%26 = OpConstant %4 0.6 -%17 = OpFunction %2 None %18 -%10 = OpLabel -%6 = OpVariable %7 Function %8 -%9 = OpVariable %7 Function %8 -%13 = OpLoad %3 %11 -OpBranch %27 -%27 = OpLabel -%28 = OpCompositeConstruct %3 %19 %20 %21 %22 -OpStore %6 %28 -%29 = OpCompositeConstruct %3 %23 %24 %25 %26 -OpStore %9 %29 -%30 = OpLoad %3 %6 -%31 = OpLoad %3 %9 -%32 = OpCompositeConstruct %5 %30 %31 -%33 = OpCompositeExtract %3 %32 0 -OpStore %14 %33 -%34 = OpCompositeExtract %3 %32 1 -OpStore %16 %34 -OpReturn -OpFunctionEnd \ No newline at end of file diff --git a/tests/out/wgsl/dualsource.wgsl b/tests/out/wgsl/dualsource.wgsl deleted file mode 100644 index d7cc4cbfdc..0000000000 --- a/tests/out/wgsl/dualsource.wgsl +++ /dev/null @@ -1,16 +0,0 @@ -struct FragmentOutput { - @location(0) color: vec4, - @location(0) @second_blend_source mask: vec4, -} - -@fragment -fn main(@builtin(position) position: vec4) -> FragmentOutput { - var color: vec4; - var mask: vec4; - - color = vec4(0.4, 0.3, 0.2, 0.1); - mask = vec4(0.9, 0.8, 0.7, 0.6); - let _e13 = color; - let _e14 = mask; - return FragmentOutput(_e13, _e14); -} diff --git a/tests/snapshots.rs b/tests/snapshots.rs index a2e03679b2..e1e1144139 100644 --- a/tests/snapshots.rs +++ b/tests/snapshots.rs @@ -512,10 +512,6 @@ fn convert_wgsl() { "fragment-output", Targets::SPIRV | Targets::METAL | Targets::GLSL | Targets::HLSL | Targets::WGSL, ), - ( - "dualsource", - Targets::SPIRV | Targets::METAL | Targets::GLSL | Targets::HLSL | Targets::WGSL, - ), ("functions-webgl", Targets::GLSL), ( "interpolate",