LoginSignup
2
2

More than 3 years have passed since last update.

ShaderGraphの結果をComputeShaderで使う方法

Posted at

Graphics.Blit を介すことで、ShaderGraphの結果をComputeShaderで使うことができます。

ShaderGraphで書いたシェーダーを使うmaterialを用意し

//  結果をdstのテクスチャに書き出す
Graphics.Blit(src, dst, material);
//  dstテクスチャをComputeShaderに渡す
MyComputeShader.SetTexture(0, "_Texture", dst);
2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2