2009-12-20 15:28:00 -08:00
|
|
|
Screen
|
|
|
|
======
|
|
|
|
|
|
|
|
A screen is an object representing the context-independent part of a device.
|
|
|
|
|
2010-01-18 15:09:30 -08:00
|
|
|
Useful Flags
|
|
|
|
------------
|
|
|
|
|
2010-01-18 16:40:39 -08:00
|
|
|
.. _pipe_texture_usage:
|
|
|
|
|
2010-01-18 15:09:30 -08:00
|
|
|
PIPE_TEXTURE_USAGE
|
|
|
|
^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
These flags determine the possible roles a texture may be used for during its
|
|
|
|
lifetime. Texture usage flags are cumulative and may be combined to create a
|
|
|
|
texture that can be used as multiple things.
|
|
|
|
|
|
|
|
* ``RENDER_TARGET``: A colorbuffer or pixelbuffer.
|
|
|
|
* ``DISPLAY_TARGET``: A sharable buffer that can be given to another process.
|
|
|
|
* ``PRIMARY``: A frontbuffer or scanout buffer.
|
|
|
|
* ``DEPTH_STENCIL``: A depthbuffer, stencilbuffer, or Z buffer. Gallium does
|
|
|
|
not explicitly provide for stencil-only buffers, so any stencilbuffer
|
|
|
|
validated here is implicitly also a depthbuffer.
|
|
|
|
* ``SAMPLER``: A texture that may be sampled from in a fragment or vertex
|
|
|
|
shader.
|
2010-01-18 18:05:55 -08:00
|
|
|
* ``DYNAMIC``: A texture that will be mapped frequently.
|
2010-01-18 15:09:30 -08:00
|
|
|
|
2009-12-20 15:28:00 -08:00
|
|
|
Methods
|
|
|
|
-------
|
|
|
|
|
2009-12-20 19:41:50 -08:00
|
|
|
XXX moar; got bored
|
|
|
|
|
|
|
|
get_name
|
|
|
|
^^^^^^^^
|
|
|
|
|
|
|
|
Returns an identifying name for the screen.
|
|
|
|
|
|
|
|
get_vendor
|
|
|
|
^^^^^^^^^^
|
|
|
|
|
|
|
|
Returns the screen vendor.
|
|
|
|
|
|
|
|
get_param
|
|
|
|
^^^^^^^^^
|
|
|
|
|
|
|
|
Get an integer/boolean screen parameter.
|
|
|
|
|
|
|
|
get_paramf
|
|
|
|
^^^^^^^^^^
|
|
|
|
|
|
|
|
Get a floating-point screen parameter.
|
|
|
|
|
|
|
|
is_format_supported
|
|
|
|
^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
See if a format can be used in a specific manner.
|
|
|
|
|
2010-01-18 16:40:39 -08:00
|
|
|
**usage** is a bitmask of :ref:`PIPE_TEXTURE_USAGE` flags.
|
2010-01-18 15:09:30 -08:00
|
|
|
|
|
|
|
Returns TRUE if all usages can be satisfied.
|
|
|
|
|
2010-01-18 18:05:55 -08:00
|
|
|
.. note::
|
|
|
|
|
|
|
|
``PIPE_TEXTURE_USAGE_DYNAMIC`` is not a valid usage.
|
|
|
|
|
2009-12-20 19:41:50 -08:00
|
|
|
texture_create
|
|
|
|
^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
Given a template of texture setup, create a BO-backed texture.
|