diff options
author | Christoph Bumiller <[email protected]> | 2011-05-02 23:55:05 +0200 |
---|---|---|
committer | Christoph Bumiller <[email protected]> | 2011-05-03 00:02:36 +0200 |
commit | 220abb7adf61872ddfb5b250be8085ee0fc2416d (patch) | |
tree | 26b33db1abbf7cfa00bf094f2723f12d86e9858b /src/gallium/drivers | |
parent | f986a6560f3ee9a79b89e9409e3a9ac52b53315c (diff) |
nv50,nvc0: advertise GL_FIXED vertex buffers as supported
We'll handle them like f64 vertex buffers, by falling back to
copying vertex data to the command buffer through translate.
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r-- | src/gallium/drivers/nv50/nv50_formats.c | 18 | ||||
-rw-r--r-- | src/gallium/drivers/nvc0/nvc0_formats.c | 18 |
2 files changed, 36 insertions, 0 deletions
diff --git a/src/gallium/drivers/nv50/nv50_formats.c b/src/gallium/drivers/nv50/nv50_formats.c index c65189d0671..96ed9a7d6d4 100644 --- a/src/gallium/drivers/nv50/nv50_formats.c +++ b/src/gallium/drivers/nv50/nv50_formats.c @@ -571,4 +571,22 @@ const struct nv50_format nv50_format_table[PIPE_FORMAT_COUNT] = [PIPE_FORMAT_A8B8G8R8_UNORM] = { 0, B_(C3, C2, C1, C0, UNORM, UNORM, UNORM, UNORM, 8_8_8_8, 0), SAMPLER_VIEW }, + + /* FIXED FORMATS - hw doesn't support these, convert on vbo push for now */ + + [PIPE_FORMAT_R32G32B32A32_FIXED] = { 0, + B_(C0, C1, C2, C3, FLOAT, FLOAT, FLOAT, FLOAT, 32_32_32_32, 0), + VERTEX_BUFFER }, + + [PIPE_FORMAT_R32G32B32_FIXED] = { 0, + B_(C0, C1, C2, ONE_FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, 32_32_32, 0), + VERTEX_BUFFER }, + + [PIPE_FORMAT_R32G32_FIXED] = { 0, + B_(C0, C1, ZERO, ONE_FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, 32_32, 0), + VERTEX_BUFFER }, + + [PIPE_FORMAT_R32_FIXED] = { 0, + B_(C0, ZERO, ZERO, ONE_FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, 32, 0), + VERTEX_BUFFER }, }; diff --git a/src/gallium/drivers/nvc0/nvc0_formats.c b/src/gallium/drivers/nvc0/nvc0_formats.c index 678e9b563ee..81077a7fa80 100644 --- a/src/gallium/drivers/nvc0/nvc0_formats.c +++ b/src/gallium/drivers/nvc0/nvc0_formats.c @@ -576,4 +576,22 @@ const struct nvc0_format nvc0_format_table[PIPE_FORMAT_COUNT] = [PIPE_FORMAT_A8B8G8R8_UNORM] = { 0, B_(C3, C2, C1, C0, UNORM, UNORM, UNORM, UNORM, 8_8_8_8, 0), SAMPLER_VIEW }, + + /* FIXED FORMATS - hw doesn't support these, convert on vbo push for now */ + + [PIPE_FORMAT_R32G32B32A32_FIXED] = { 0, + B_(C0, C1, C2, C3, FLOAT, FLOAT, FLOAT, FLOAT, 32_32_32_32, 0), + VERTEX_BUFFER }, + + [PIPE_FORMAT_R32G32B32_FIXED] = { 0, + B_(C0, C1, C2, ONE_FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, 32_32_32, 0), + VERTEX_BUFFER }, + + [PIPE_FORMAT_R32G32_FIXED] = { 0, + B_(C0, C1, ZERO, ONE_FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, 32_32, 0), + VERTEX_BUFFER }, + + [PIPE_FORMAT_R32_FIXED] = { 0, + B_(C0, ZERO, ZERO, ONE_FLOAT, FLOAT, FLOAT, FLOAT, FLOAT, 32, 0), + VERTEX_BUFFER }, }; |