Browse Source

Doc++

* Workarounds for unsupported features in OpenGL ES.
 * Initial values for some states.
pull/279/head
Vladimír Vondruš 14 years ago
parent
commit
092d2fc897
  1. 16
      src/Mesh.h

16
src/Mesh.h

@ -58,11 +58,13 @@ class MAGNUM_EXPORT Mesh {
* @brief Polygon mode * @brief Polygon mode
* *
* @see setPolygonMode() * @see setPolygonMode()
* @requires_gl * @requires_gl OpenGL ES behaves always like
* <tt>PolygonMode::%Fill</tt>. See setPrimitive() for possible
* workaround.
*/ */
enum class PolygonMode: GLenum { enum class PolygonMode: GLenum {
/** /**
* Interior of the polygon is filled. * Interior of the polygon is filled (default).
*/ */
Fill = GL_FILL, Fill = GL_FILL,
@ -83,8 +85,9 @@ class MAGNUM_EXPORT Mesh {
/** /**
* @brief Set polygon drawing mode * @brief Set polygon drawing mode
* *
* Initial value is PolygonMode::Fill. * Initial value is `PolygonMode::%Fill`.
* @requires_gl * @requires_gl OpenGL ES behaves always like the default. See
* setPrimitive() for possible workaround.
*/ */
inline static void setPolygonMode(PolygonMode mode) { inline static void setPolygonMode(PolygonMode mode) {
glPolygonMode(GL_FRONT_AND_BACK, static_cast<GLenum>(mode)); glPolygonMode(GL_FRONT_AND_BACK, static_cast<GLenum>(mode));
@ -104,6 +107,7 @@ class MAGNUM_EXPORT Mesh {
/** /**
* @brief Set point size * @brief Set point size
* *
* Initial value is `1.0f`.
* @see setProgramPointSize() * @see setProgramPointSize()
* @requires_gl Set directly in vertex shader using @c gl_PointSize * @requires_gl Set directly in vertex shader using @c gl_PointSize
* builtin variable. * builtin variable.
@ -116,9 +120,9 @@ class MAGNUM_EXPORT Mesh {
* @brief Enable/disable programmable point size * @brief Enable/disable programmable point size
* *
* If enabled, the point size is taken from vertex/geometry shader * If enabled, the point size is taken from vertex/geometry shader
* builtin `gl_PointSize`. * builtin `gl_PointSize`. Initially disabled on desktop OpenGL.
* @see setPointSize() * @see setPointSize()
* @requires_gl Always enabled. * @requires_gl Always enabled on OpenGL ES.
*/ */
inline static void setProgramPointSize(bool enabled) { inline static void setProgramPointSize(bool enabled) {
enabled ? glEnable(GL_PROGRAM_POINT_SIZE) : glDisable(GL_PROGRAM_POINT_SIZE); enabled ? glEnable(GL_PROGRAM_POINT_SIZE) : glDisable(GL_PROGRAM_POINT_SIZE);

Loading…
Cancel
Save