⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 drawarrays.html

📁 计算机图形学~想必是很多人需要的~在此共享一下
💻 HTML
字号:
<HTML><BODY><PRE>     <STRONG>NAME</STRONG>	  <STRONG>glDrawArrays</STRONG> - render	primitives from	array data     <STRONG>C</STRONG> <STRONG>SPECIFICATION</STRONG>	  void <STRONG>glDrawArrays</STRONG>( GLenum <EM>mode</EM>,			     GLint <EM>first</EM>,			     GLsizei <EM>count</EM> )     <STRONG>PARAMETERS</STRONG>	  <EM>mode</EM>	 Specifies what	kind of	primitives to render.		 Symbolic constants <STRONG>GL_POINTS</STRONG>, <STRONG>GL_LINE_STRIP</STRONG>,		 <STRONG>GL_LINE_LOOP</STRONG>, <STRONG>GL_LINES</STRONG>, <STRONG>GL_TRIANGLE_STRIP</STRONG>,		 <STRONG>GL_TRIANGLE_FAN</STRONG>, <STRONG>GL_TRIANGLES</STRONG>,	<STRONG>GL_QUAD_STRIP</STRONG>,		 <STRONG>GL_QUADS</STRONG>, and <STRONG>GL_POLYGON</STRONG> are accepted.	  <EM>first</EM>	 Specifies the starting	index in the enabled arrays.	  <EM>count</EM>	 Specifies the number of indices to be rendered.     <STRONG>DESCRIPTION</STRONG>	  <STRONG>glDrawArrays</STRONG> specifies multiple geometric primitives with	  very few subroutine calls. Instead of	calling	a GL procedure	  to pass each individual vertex, normal, texture coordinate,	  edge flag, or	color, you can prespecify separate arrays of	  vertexes, normals, and colors	and use	them to	construct a	  sequence of primitives with a	single call to <STRONG>glDrawArrays</STRONG>.	  When <STRONG>glDrawArrays</STRONG> is called, it uses <EM>count</EM> sequential	  elements from	each enabled array to construct	a sequence of	  geometric primitives,	beginning with element <EM>first</EM>. <EM>mode</EM>	  specifies what kind of primitives are	constructed, and how	  the array elements construct those primitives. If	  <STRONG>GL_VERTEX_ARRAY</STRONG> is not enabled, no geometric primitives are	  generated.	  Vertex attributes that are modified by <STRONG>glDrawArrays</STRONG> have an	  unspecified value after <STRONG>glDrawArrays</STRONG> returns.	For example,	  if <STRONG>GL_COLOR_ARRAY</STRONG> is enabled,	the value of the current color	  is undefined after <STRONG>glDrawArrays</STRONG> executes. Attributes that	  aren't modified remain well defined.     <STRONG>NOTES</STRONG>	  <STRONG>glDrawArrays</STRONG> is available only if the	GL version is 1.1 or	  greater.	  <STRONG>glDrawArrays</STRONG> is included in display lists. If	<STRONG>glDrawArrays</STRONG>	  is entered into a display list, the necessary	array data	  (determined by the array pointers and	enables) is also	  entered into the display list. Because the array pointers	  and enables are client-side state, their values affect	  display lists	when the lists are created, not	when the lists	  are executed.     <STRONG>ERRORS</STRONG>	  <STRONG>GL_INVALID_ENUM</STRONG> is generated if <EM>mode</EM> is not an accepted	  value.	  <STRONG>GL_INVALID_VALUE</STRONG> is generated	if <EM>count</EM> is negative.	  <STRONG>GL_INVALID_OPERATION</STRONG> is generated if <STRONG>glDrawArrays</STRONG> is	  executed between the execution of <STRONG>glBegin</STRONG> and	the	  corresponding	<STRONG>glEnd</STRONG>.     <STRONG>SEE</STRONG> <STRONG>ALSO</STRONG>	  <STRONG>glArrayElement</STRONG>, <STRONG>glColorPointer</STRONG>, <STRONG>glDrawElements</STRONG>,	  <STRONG>glEdgeFlagPointer</STRONG>,	  <STRONG>glGetPointerv</STRONG>, <STRONG>glIndexPointer</STRONG>, <STRONG>glInterleavedArrays</STRONG>,	  <STRONG>glNormalPointer</STRONG>,	  <STRONG>glTexCoordPointer</STRONG>, <STRONG>glVertexPointer</STRONG></PRE></BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -