c# - Is an array valid for vertex element data for programmable graphics pipline? -
Posted here in response to my previous cession:
I have a top structure with an array of unstable point values such as:
public structure vertex {float [] array = new float [4]; Public vertex (float x, float, y, float z, float w) {arrer [0] = x; Array [1] = y; Array [2] = z; Array [3] = w; }}
Can that top structure be sent to a top buffer (using OpenGL or DirectX)? Is there any other byte data in an array or does it contain data for only temporary point values? As I can use this head as a conversion in the declaration (in DirectX), I can send buffer to the top and all that will be sent is a floating point value or what other information will be included in the array which Shader can break program? I'm not a C # programmer, but it looks here that you store an array reference (indicator). In vertex straight, there will be an array of an array indicator of the vertex. A Graphics API demands continuous order.
Try:
Public Configuration Vertex {Public Fixed Float Array [4]; Public vertex (float x, float, y, float z, float w) {arrer [0] = x; Array [1] = y; Array [2] = z; Array [3] = w; }}
Comments
Post a Comment