Regen docs.
This commit is contained in:
+72
-1
@@ -7,4 +7,75 @@ of the device's 3D rendering pipeline.
|
||||
Methods
|
||||
-------
|
||||
|
||||
XXX
|
||||
CSO State
|
||||
^^^^^^^^^
|
||||
|
||||
All CSO state is created, bound, and destroyed, with triplets of methods that
|
||||
all follow a specific naming scheme. For example, ``create_blend_state``,
|
||||
``bind_blend_state``, and ``destroy_blend_state``.
|
||||
|
||||
CSO objects handled by the context object:
|
||||
|
||||
* :ref:`Blend`: ``*_blend_state``
|
||||
* :ref:`Sampler`: These are special; they can be bound to either vertex or
|
||||
fragment samplers, and they are bound in groups.
|
||||
``bind_fragment_sampler_states``, ``bind_vertex_sampler_states``
|
||||
* :ref:`Rasterizer`: ``*_rasterizer_state``
|
||||
* :ref:`Depth, Stencil, & Alpha`: ``*_depth_stencil_alpha_state``
|
||||
* :ref:`Shader`: These have two sets of methods. ``*_fs_state`` is for
|
||||
fragment shaders, and ``*_vs_state`` is for vertex shaders.
|
||||
|
||||
Non-CSO State
|
||||
^^^^^^^^^^^^^
|
||||
|
||||
These pieces of state are too small, variable, and/or trivial to have CSO
|
||||
objects. They all follow simple, one-method binding calls, e.g.
|
||||
``set_edgeflags``.
|
||||
|
||||
* ``set_edgeflags``
|
||||
* ``set_blend_color``
|
||||
* ``set_clip_state``
|
||||
* ``set_constant_buffer``
|
||||
* ``set_framebuffer_state``
|
||||
* ``set_polygon_stipple``
|
||||
* ``set_scissor_state``
|
||||
* ``set_viewport_state``
|
||||
* ``set_fragment_sampler_textures``
|
||||
* ``set_vertex_sampler_textures``
|
||||
* ``set_vertex_buffers``
|
||||
* ``set_vertex_elements``
|
||||
|
||||
Queries
|
||||
^^^^^^^
|
||||
|
||||
Queries can be created with ``create_query`` and deleted with
|
||||
``destroy_query``. To enable a query, use ``begin_query``, and when finished,
|
||||
use ``end_query`` to stop the query. Finally, ``get_query_result`` is used
|
||||
to retrieve the results.
|
||||
|
||||
VBO Drawing
|
||||
^^^^^^^^^^^
|
||||
|
||||
``draw_arrays``
|
||||
|
||||
``draw_elements``
|
||||
|
||||
``draw_range_elements``
|
||||
|
||||
``flush``
|
||||
|
||||
Surface Drawing
|
||||
^^^^^^^^^^^^^^^
|
||||
|
||||
These methods emulate classic blitter controls. They are not guaranteed to be
|
||||
available; if they are set to NULL, then they are not present.
|
||||
|
||||
``surface_fill`` performs a fill operation on a section of a surface.
|
||||
|
||||
``surface_copy`` blits a region of a surface to a region of another surface,
|
||||
provided that both surfaces are the same format. The source and destination
|
||||
may be the same surface, and overlapping blits are permitted.
|
||||
|
||||
``clear`` initializes entire buffers to an RGBA, depth, or stencil value,
|
||||
depending on the formats of the buffers. Use ``set_framebuffer_state`` to
|
||||
specify the buffers to clear.
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
.. _blend:
|
||||
|
||||
Blend
|
||||
=====
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
.. _depth,stencil,&alpha:
|
||||
|
||||
Depth, Stencil, & Alpha
|
||||
=======================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
.. _rasterizer:
|
||||
|
||||
Rasterizer
|
||||
==========
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
.. _sampler:
|
||||
|
||||
Sampler
|
||||
=======
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
.. _shader:
|
||||
|
||||
Shader
|
||||
======
|
||||
|
||||
|
||||
+31
-1
@@ -6,4 +6,34 @@ A screen is an object representing the context-independent part of a device.
|
||||
Methods
|
||||
-------
|
||||
|
||||
XXX
|
||||
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.
|
||||
|
||||
texture_create
|
||||
^^^^^^^^^^^^^^
|
||||
|
||||
Given a template of texture setup, create a BO-backed texture.
|
||||
|
||||
+71
-2
@@ -51,7 +51,69 @@
|
||||
of the device’s 3D rendering pipeline.</p>
|
||||
<div class="section" id="methods">
|
||||
<h2>Methods<a class="headerlink" href="#methods" title="Permalink to this headline">¶</a></h2>
|
||||
<p>XXX</p>
|
||||
<div class="section" id="cso-state">
|
||||
<h3>CSO State<a class="headerlink" href="#cso-state" title="Permalink to this headline">¶</a></h3>
|
||||
<p>All CSO state is created, bound, and destroyed, with triplets of methods that
|
||||
all follow a specific naming scheme. For example, <tt class="docutils literal"><span class="pre">create_blend_state</span></tt>,
|
||||
<tt class="docutils literal"><span class="pre">bind_blend_state</span></tt>, and <tt class="docutils literal"><span class="pre">destroy_blend_state</span></tt>.</p>
|
||||
<p>CSO objects handled by the context object:</p>
|
||||
<ul class="simple">
|
||||
<li><a class="reference external" href="cso/blend.html#blend"><em>Blend</em></a>: <tt class="docutils literal"><span class="pre">*_blend_state</span></tt></li>
|
||||
<li><a class="reference external" href="cso/sampler.html#sampler"><em>Sampler</em></a>: These are special; they can be bound to either vertex or
|
||||
fragment samplers, and they are bound in groups.
|
||||
<tt class="docutils literal"><span class="pre">bind_fragment_sampler_states</span></tt>, <tt class="docutils literal"><span class="pre">bind_vertex_sampler_states</span></tt></li>
|
||||
<li><a class="reference external" href="cso/rasterizer.html#rasterizer"><em>Rasterizer</em></a>: <tt class="docutils literal"><span class="pre">*_rasterizer_state</span></tt></li>
|
||||
<li><a class="reference external" href="cso/dsa.html#depth-stencil-alpha"><em>Depth, Stencil, & Alpha</em></a>: <tt class="docutils literal"><span class="pre">*_depth_stencil_alpha_state</span></tt></li>
|
||||
<li><a class="reference external" href="cso/shader.html#shader"><em>Shader</em></a>: These have two sets of methods. <tt class="docutils literal"><span class="pre">*_fs_state</span></tt> is for
|
||||
fragment shaders, and <tt class="docutils literal"><span class="pre">*_vs_state</span></tt> is for vertex shaders.</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="non-cso-state">
|
||||
<h3>Non-CSO State<a class="headerlink" href="#non-cso-state" title="Permalink to this headline">¶</a></h3>
|
||||
<p>These pieces of state are too small, variable, and/or trivial to have CSO
|
||||
objects. They all follow simple, one-method binding calls, e.g.
|
||||
<tt class="docutils literal"><span class="pre">set_edgeflags</span></tt>.</p>
|
||||
<ul class="simple">
|
||||
<li><tt class="docutils literal"><span class="pre">set_edgeflags</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_blend_color</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_clip_state</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_constant_buffer</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_framebuffer_state</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_polygon_stipple</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_scissor_state</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_viewport_state</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_fragment_sampler_textures</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_vertex_sampler_textures</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_vertex_buffers</span></tt></li>
|
||||
<li><tt class="docutils literal"><span class="pre">set_vertex_elements</span></tt></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="queries">
|
||||
<h3>Queries<a class="headerlink" href="#queries" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Queries can be created with <tt class="docutils literal"><span class="pre">create_query</span></tt> and deleted with
|
||||
<tt class="docutils literal"><span class="pre">destroy_query</span></tt>. To enable a query, use <tt class="docutils literal"><span class="pre">begin_query</span></tt>, and when finished,
|
||||
use <tt class="docutils literal"><span class="pre">end_query</span></tt> to stop the query. Finally, <tt class="docutils literal"><span class="pre">get_query_result</span></tt> is used
|
||||
to retrieve the results.</p>
|
||||
</div>
|
||||
<div class="section" id="vbo-drawing">
|
||||
<h3>VBO Drawing<a class="headerlink" href="#vbo-drawing" title="Permalink to this headline">¶</a></h3>
|
||||
<p><tt class="docutils literal"><span class="pre">draw_arrays</span></tt></p>
|
||||
<p><tt class="docutils literal"><span class="pre">draw_elements</span></tt></p>
|
||||
<p><tt class="docutils literal"><span class="pre">draw_range_elements</span></tt></p>
|
||||
<p><tt class="docutils literal"><span class="pre">flush</span></tt></p>
|
||||
</div>
|
||||
<div class="section" id="surface-drawing">
|
||||
<h3>Surface Drawing<a class="headerlink" href="#surface-drawing" title="Permalink to this headline">¶</a></h3>
|
||||
<p>These methods emulate classic blitter controls. They are not guaranteed to be
|
||||
available; if they are set to NULL, then they are not present.</p>
|
||||
<p><tt class="docutils literal"><span class="pre">surface_fill</span></tt> performs a fill operation on a section of a surface.</p>
|
||||
<p><tt class="docutils literal"><span class="pre">surface_copy</span></tt> blits a region of a surface to a region of another surface,
|
||||
provided that both surfaces are the same format. The source and destination
|
||||
may be the same surface, and overlapping blits are permitted.</p>
|
||||
<p><tt class="docutils literal"><span class="pre">clear</span></tt> initializes entire buffers to an RGBA, depth, or stencil value,
|
||||
depending on the formats of the buffers. Use <tt class="docutils literal"><span class="pre">set_framebuffer_state</span></tt> to
|
||||
specify the buffers to clear.</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -64,7 +126,14 @@ of the device’s 3D rendering pipeline.</p>
|
||||
<h3><a href="index.html">Table Of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference external" href="">Context</a><ul>
|
||||
<li><a class="reference external" href="#methods">Methods</a></li>
|
||||
<li><a class="reference external" href="#methods">Methods</a><ul>
|
||||
<li><a class="reference external" href="#cso-state">CSO State</a></li>
|
||||
<li><a class="reference external" href="#non-cso-state">Non-CSO State</a></li>
|
||||
<li><a class="reference external" href="#queries">Queries</a></li>
|
||||
<li><a class="reference external" href="#vbo-drawing">VBO Drawing</a></li>
|
||||
<li><a class="reference external" href="#surface-drawing">Surface Drawing</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
+1
-1
@@ -48,7 +48,7 @@
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="blend">
|
||||
<h1>Blend<a class="headerlink" href="#blend" title="Permalink to this headline">¶</a></h1>
|
||||
<span id="id1"></span><h1>Blend<a class="headerlink" href="#blend" title="Permalink to this headline">¶</a></h1>
|
||||
<p>This state controls blending of the final fragments into the target rendering
|
||||
buffers.</p>
|
||||
<p>XXX it is unresolved what behavior should result if blend_enable is off.</p>
|
||||
|
||||
+1
-1
@@ -48,7 +48,7 @@
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="depth-stencil-alpha">
|
||||
<h1>Depth, Stencil, & Alpha<a class="headerlink" href="#depth-stencil-alpha" title="Permalink to this headline">¶</a></h1>
|
||||
<span id="id1"></span><h1>Depth, Stencil, & Alpha<a class="headerlink" href="#depth-stencil-alpha" title="Permalink to this headline">¶</a></h1>
|
||||
<p>These three states control the depth, stencil, and alpha tests, used to
|
||||
discard fragments that have passed through the fragment shader.</p>
|
||||
<p>Traditionally, these three tests have been clumped together in hardware, so
|
||||
|
||||
+1
-1
@@ -48,7 +48,7 @@
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="rasterizer">
|
||||
<h1>Rasterizer<a class="headerlink" href="#rasterizer" title="Permalink to this headline">¶</a></h1>
|
||||
<span id="id1"></span><h1>Rasterizer<a class="headerlink" href="#rasterizer" title="Permalink to this headline">¶</a></h1>
|
||||
<p>The rasterizer is the main chunk of state controlling how vertices are
|
||||
interpolated into fragments.</p>
|
||||
<div class="section" id="members">
|
||||
|
||||
+1
-1
@@ -48,7 +48,7 @@
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="sampler">
|
||||
<h1>Sampler<a class="headerlink" href="#sampler" title="Permalink to this headline">¶</a></h1>
|
||||
<span id="id1"></span><h1>Sampler<a class="headerlink" href="#sampler" title="Permalink to this headline">¶</a></h1>
|
||||
<p>Texture units have many options for selecting texels from loaded textures;
|
||||
this state controls an individual texture unit’s texel-sampling settings.</p>
|
||||
<p>Texture coordinates are always treated as four-dimensional, and referred to
|
||||
|
||||
+1
-1
@@ -44,7 +44,7 @@
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="shader">
|
||||
<h1>Shader<a class="headerlink" href="#shader" title="Permalink to this headline">¶</a></h1>
|
||||
<span id="id1"></span><h1>Shader<a class="headerlink" href="#shader" title="Permalink to this headline">¶</a></h1>
|
||||
<p>One of the two types of shaders supported by Gallium.</p>
|
||||
<div class="section" id="members">
|
||||
<h2>Members<a class="headerlink" href="#members" title="Permalink to this headline">¶</a></h2>
|
||||
|
||||
+34
-2
@@ -50,7 +50,31 @@
|
||||
<p>A screen is an object representing the context-independent part of a device.</p>
|
||||
<div class="section" id="methods">
|
||||
<h2>Methods<a class="headerlink" href="#methods" title="Permalink to this headline">¶</a></h2>
|
||||
<p>XXX</p>
|
||||
<p>XXX moar; got bored</p>
|
||||
<div class="section" id="get-name">
|
||||
<h3>get_name<a class="headerlink" href="#get-name" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Returns an identifying name for the screen.</p>
|
||||
</div>
|
||||
<div class="section" id="get-vendor">
|
||||
<h3>get_vendor<a class="headerlink" href="#get-vendor" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Returns the screen vendor.</p>
|
||||
</div>
|
||||
<div class="section" id="get-param">
|
||||
<h3>get_param<a class="headerlink" href="#get-param" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Get an integer/boolean screen parameter.</p>
|
||||
</div>
|
||||
<div class="section" id="get-paramf">
|
||||
<h3>get_paramf<a class="headerlink" href="#get-paramf" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Get a floating-point screen parameter.</p>
|
||||
</div>
|
||||
<div class="section" id="is-format-supported">
|
||||
<h3>is_format_supported<a class="headerlink" href="#is-format-supported" title="Permalink to this headline">¶</a></h3>
|
||||
<p>See if a format can be used in a specific manner.</p>
|
||||
</div>
|
||||
<div class="section" id="texture-create">
|
||||
<h3>texture_create<a class="headerlink" href="#texture-create" title="Permalink to this headline">¶</a></h3>
|
||||
<p>Given a template of texture setup, create a BO-backed texture.</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -63,7 +87,15 @@
|
||||
<h3><a href="index.html">Table Of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference external" href="">Screen</a><ul>
|
||||
<li><a class="reference external" href="#methods">Methods</a></li>
|
||||
<li><a class="reference external" href="#methods">Methods</a><ul>
|
||||
<li><a class="reference external" href="#get-name">get_name</a></li>
|
||||
<li><a class="reference external" href="#get-vendor">get_vendor</a></li>
|
||||
<li><a class="reference external" href="#get-param">get_param</a></li>
|
||||
<li><a class="reference external" href="#get-paramf">get_paramf</a></li>
|
||||
<li><a class="reference external" href="#is-format-supported">is_format_supported</a></li>
|
||||
<li><a class="reference external" href="#texture-create">texture_create</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user