diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2011-08-04 13:47:40 +0400 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2011-08-04 13:47:40 +0400 |
commit | f3c40df5e334f8a1f106fe71e44c8035ddcac7b1 (patch) | |
tree | ed265dd58d06c3d63bea71cde3b160a65bf28ac3 /doc/python_api/rst/bgl.rst | |
parent | 0578d55f1ef700b96ae8a8c33c1f8b54a200c7d9 (diff) |
rst API doc fixes: literalincluding bge.texture and bge.constraints examples + bgl fixes
Diffstat (limited to 'doc/python_api/rst/bgl.rst')
-rw-r--r-- | doc/python_api/rst/bgl.rst | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/doc/python_api/rst/bgl.rst b/doc/python_api/rst/bgl.rst index 236bfafb295..5f3158bf5dd 100644 --- a/doc/python_api/rst/bgl.rst +++ b/doc/python_api/rst/bgl.rst @@ -15,7 +15,7 @@ collections of tutorials. The "red book": "I{OpenGL Programming Guide: The Official Guide to Learning OpenGL}" and the online NeHe tutorials are two of the best resources. -..note:: +.. note:: You can use the :class:`Image` type to load and set textures. See :class:`Image.gl_load` and :class:`Image.gl_load`, for example. @@ -1386,7 +1386,7 @@ OpenGL}" and the online NeHe tutorials are two of the best resources. bgl.glGetFloatv(bgl.GL_MODELVIEW_MATRIX, view_matrix) f = 1.0 / view_matrix[0] - # Instead of the usual glRasterPos2i(xval, yval) + # Instead of the usual glRasterPos2i(xval, yval) bgl.glRasterPos2f(xval * f, yval * f) @@ -1848,10 +1848,13 @@ class Buffer: .. code-block:: python import bgl + myByteBuffer = bgl.Buffer(bgl.GL_BYTE, [32, 32]) bgl.glGetPolygonStipple(myByteBuffer) + print(myByteBuffer.dimensions) print(myByteBuffer.to_list()) + sliceBuffer = myByteBuffer[0:16] print(sliceBuffer) |