shader-slang / slang

Making it easier to work with shaders
MIT License
2.05k stars 177 forks source link

Add case to `emitVectorReshape` for when using a `vector<M, N>` type with `T` value #4419

Closed ArielG-NV closed 3 months ago

ArielG-NV commented 3 months ago

fixes: #4411

  1. Add logic to handle vector<> type, scalar value in emitVectorReshape
    • construct a vector based on the input type either a vec1 to vecn. Any elements beyond index 0 are a default value for the "vector<> type, scalar value" case
  2. Add test