@@ -215,6 +215,7 @@ struct Decoration {
215215 name : Option < String > ,
216216 built_in : Option < spirv:: Word > ,
217217 location : Option < spirv:: Word > ,
218+ index : Option < spirv:: Word > ,
218219 desc_set : Option < spirv:: Word > ,
219220 desc_index : Option < spirv:: Word > ,
220221 specialization_constant_id : Option < spirv:: Word > ,
@@ -256,6 +257,18 @@ impl Decoration {
256257 invariant,
257258 ..
258259 } => Ok ( crate :: Binding :: BuiltIn ( map_builtin ( built_in, invariant) ?) ) ,
260+ Decoration {
261+ built_in : None ,
262+ location : Some ( location) ,
263+ index : Some ( index) ,
264+ ..
265+ } => Ok ( crate :: Binding :: Location {
266+ location,
267+ interpolation : None ,
268+ sampling : None ,
269+ blend_src : Some ( index) ,
270+ per_primitive : false ,
271+ } ) ,
259272 Decoration {
260273 built_in : None ,
261274 location : Some ( location) ,
@@ -746,6 +759,10 @@ impl<I: Iterator<Item = u32>> Frontend<I> {
746759 inst. expect ( base_words + 2 ) ?;
747760 dec. location = Some ( self . next ( ) ?) ;
748761 }
762+ spirv:: Decoration :: Index => {
763+ inst. expect ( base_words + 2 ) ?;
764+ dec. index = Some ( self . next ( ) ?) ;
765+ }
749766 spirv:: Decoration :: DescriptorSet => {
750767 inst. expect ( base_words + 2 ) ?;
751768 dec. desc_set = Some ( self . next ( ) ?) ;
0 commit comments