Fix D2D1 generator error when checking for simple inputs
このコミットが含まれているのは:
1 親
e1d823a833
コミット
f7612b587e
3ファイル変更
+9
-9
検索条件に一致するファイルはありません
+2
-7
@@ -43,16 +43,11 @@ partial class ID2D1ShaderGenerator
|
||||
/// Extracts the metadata definition for the current shader.
|
||||
/// </summary>
|
||||
/// <param name="structDeclarationSymbol">The input <see cref="INamedTypeSymbol"/> instance to process.</param>
|
||||
/// <param name="inputCount">The number of inputs for the shader.</param>
|
||||
/// <returns>Whether the shader only has simple inputs.</returns>
|
||||
public static bool IsSimpleInputShader(INamedTypeSymbol structDeclarationSymbol)
|
||||
public static bool IsSimpleInputShader(INamedTypeSymbol structDeclarationSymbol, int inputCount)
|
||||
{
|
||||
if (!structDeclarationSymbol.TryGetAttributeWithFullMetadataName("ComputeSharp.D2D1.D2DInputCountAttribute", out AttributeData? inputCountAttribute))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// Build a map of all simple inputs (unmarked inputs default to being complex)
|
||||
int inputCount = (int)inputCountAttribute!.ConstructorArguments[0].Value!;
|
||||
bool[] simpleInputsMap = new bool[inputCount];
|
||||
|
||||
foreach (AttributeData attributeData in structDeclarationSymbol.GetAttributes())
|
||||
|
||||
新しいイシューから参照
ユーザーをブロックする