diff options
author | José Fonseca <[email protected]> | 2008-07-19 12:04:37 +0900 |
---|---|---|
committer | José Fonseca <[email protected]> | 2008-07-19 12:32:29 +0900 |
commit | 8aafc03b260ab8923f1b373f7effa75bcdb40a72 (patch) | |
tree | 0274cc6cad2d6993ba8ea3fdd34c49254c532d47 /src/gallium/state_trackers/python/tests | |
parent | ff26c50153b3a348b35843262ceb27062ab37214 (diff) |
gallium: Finer grained is_format_supported.
Diffstat (limited to 'src/gallium/state_trackers/python/tests')
-rw-r--r-- | src/gallium/state_trackers/python/tests/texture.py | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/gallium/state_trackers/python/tests/texture.py b/src/gallium/state_trackers/python/tests/texture.py index 16ad78c8aa8..b2ca9f416f5 100644 --- a/src/gallium/state_trackers/python/tests/texture.py +++ b/src/gallium/state_trackers/python/tests/texture.py @@ -136,7 +136,7 @@ class TextureTest(TestCase): level = self.level zslice = self.zslice - if not dev.is_format_supported(format, PIPE_TEXTURE): + if not dev.is_format_supported(format, PIPE_TEXTURE_2D, PIPE_TEXTURE_USAGE_SAMPLER, 0): raise TestSkip ctx = self.dev.context_create() @@ -199,6 +199,7 @@ class TextureTest(TestCase): height = height, depth = depth, last_level = last_level, + tex_usage = PIPE_TEXTURE_USAGE_SAMPLER, ) expected_rgba = FloatArray(height*width*4) @@ -212,10 +213,12 @@ class TextureTest(TestCase): ctx.set_sampler_texture(0, texture) # framebuffer - cbuf_tex = dev.texture_create(PIPE_FORMAT_A8R8G8B8_UNORM, - width, - height, - usage = PIPE_TEXTURE_USAGE_RENDER_TARGET) + cbuf_tex = dev.texture_create( + PIPE_FORMAT_A8R8G8B8_UNORM, + width, + height, + tex_usage = PIPE_TEXTURE_USAGE_RENDER_TARGET, + ) cbuf = cbuf_tex.get_surface(usage = PIPE_BUFFER_USAGE_GPU_WRITE|PIPE_BUFFER_USAGE_GPU_READ) fb = Framebuffer() |