Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Compute shader StructuredBuffer vs Buffer

Discussion in 'Shaders' started by TheCelt, Oct 4, 2019.

  1. TheCelt

    TheCelt

    Joined:
    Feb 27, 2013
    Posts:
    741
    Whats the difference between StructuredBuffer and Buffer ? I know structured buffers can take a generic type of struct that the user defines, but what else is different?

    For me when i use Buffer i get a different result of Structured buffer.

    Yet i am using <float2> and <float4> which is not user defined structs so both buffers should work identically unless i am misunderstanding something about the two?