[cells-cvs] CVS update: cell-cultures/cl-opengl/gl-constants.lisp cell-cultures/cl-opengl/glu-functions.lisp cell-cultures/cl-opengl/glut-extras.lisp cell-cultures/cl-opengl/nehe-14.lisp cell-cultures/cl-opengl/ogl-macros.lisp cell-cultures/cl-opengl/ogl-utils.lisp

Kenny Tilton ktilton at common-lisp.net
Fri Oct 15 03:38:02 UTC 2004


Update of /project/cells/cvsroot/cell-cultures/cl-opengl
In directory common-lisp.net:/tmp/cvs-serv28025/cl-opengl

Modified Files:
	gl-constants.lisp glu-functions.lisp glut-extras.lisp 
	nehe-14.lisp ogl-macros.lisp ogl-utils.lisp 
Log Message:
Re-write of the core layout widgets under the ix-inline class, plus a new OpenGL example, viz., a simple nurb. Looks sweet, btw.
Date: Fri Oct 15 05:37:56 2004
Author: ktilton

Index: cell-cultures/cl-opengl/gl-constants.lisp
diff -u cell-cultures/cl-opengl/gl-constants.lisp:1.1 cell-cultures/cl-opengl/gl-constants.lisp:1.2
--- cell-cultures/cl-opengl/gl-constants.lisp:1.1	Sat Jun 26 20:38:40 2004
+++ cell-cultures/cl-opengl/gl-constants.lisp	Fri Oct 15 05:37:55 2004
@@ -172,8 +172,8 @@
 (dfc gl_t4f_c4f_n3f_v4f                      #x2a2d)
 
 #| matrix mode |#
-(dfc gl_model-view                            #x1700)
-(dfc gl_projection                           #x1701)
+(dfc gl_modelview                     #x1700)
+(dfc gl_projection                     #x1701)
 (dfc gl_texture                              #x1702)
 
 #| display lists |#
@@ -338,10 +338,10 @@
 (dfc gl_matrix_mode                    #x0ba0)
 (dfc gl_normalize                      #x0ba1)
 (dfc gl_viewport                       #x0ba2)
-(dfc gl_model-view_stack_depth          #x0ba3)
+(dfc gl_modelview_stack_depth          #x0ba3)
 (dfc gl_projection_stack_depth         #x0ba4)
 (dfc gl_texture_stack_depth            #x0ba5)
-(dfc gl_model-view_matrix               #x0ba6)
+(dfc gl_modelview_matrix               #x0ba6)
 (dfc gl_projection_matrix              #x0ba7)
 (dfc gl_texture_matrix                 #x0ba8)
 (dfc gl_attrib_stack_depth             #x0bb0)


Index: cell-cultures/cl-opengl/glu-functions.lisp
diff -u cell-cultures/cl-opengl/glu-functions.lisp:1.1 cell-cultures/cl-opengl/glu-functions.lisp:1.2
--- cell-cultures/cl-opengl/glu-functions.lisp:1.1	Sat Jun 26 20:38:41 2004
+++ cell-cultures/cl-opengl/glu-functions.lisp	Fri Oct 15 05:37:55 2004
@@ -22,9 +22,139 @@
 
 (in-package :cl-opengl)
 
+;;; ***           Generic constants               ****/
+
+;;;  Errors: (return value 0 = no error) */
+(dfc GLU_INVALID_ENUM        100900)
+(dfc GLU_INVALID_VALUE       100901)
+(dfc GLU_OUT_OF_MEMORY       100902)
+(dfc GLU_INCOMPATIBLE_GL_VERSION     100903)
+
+;;;  StringName */
+(dfc GLU_VERSION             100800)
+(dfc GLU_EXTENSIONS          100801)
+
+;;;  Boolean */
+(dfc GLU_TRUE                1)
+(dfc GLU_FALSE               0)
+
+
+;;; ***           Quadric constants               ****/
+
+;;;  QuadricNormal */
+(dfc GLU_SMOOTH              100000)
+(dfc GLU_FLAT                100001)
+(dfc GLU_NONE                100002)
+
+;;;  QuadricDrawStyle */
+(dfc GLU_POINT               100010)
+(dfc GLU_LINE                100011)
+(dfc GLU_FILL                100012)
+(dfc GLU_SILHOUETTE          100013)
+
+;;;  QuadricOrientation */
+(dfc GLU_OUTSIDE             100020)
+(dfc GLU_INSIDE              100021)
+
+;;;  Callback types: */
+;;;       GLU_ERROR               100103 */
+
+
+;;; ***           Tesselation constants           ****/
+
+;;(dfc GLU_TESS_MAX_COORD              1.0e150)
+
+;;;  TessProperty */
+(dfc GLU_TESS_WINDING_RULE           100140)
+(dfc GLU_TESS_BOUNDARY_ONLY          100141)
+(dfc GLU_TESS_TOLERANCE              100142)
+
+;;;  TessWinding */
+(dfc GLU_TESS_WINDING_ODD            100130)
+(dfc GLU_TESS_WINDING_NONZERO        100131)
+(dfc GLU_TESS_WINDING_POSITIVE       100132)
+(dfc GLU_TESS_WINDING_NEGATIVE       100133)
+(dfc GLU_TESS_WINDING_ABS_GEQ_TWO    100134)
+
+;;;  TessCallback */
+(dfc GLU_TESS_BEGIN          100100)  ;;;  void (CALLBACK*)(GLenum    type)  */
+(dfc GLU_TESS_VERTEX         100101)  ;;;  void (CALLBACK*)(void      *data) */
+(dfc GLU_TESS_END            100102)  ;;;  void (CALLBACK*)(void)            */
+(dfc GLU_TESS_ERROR          100103)  ;;;  void (CALLBACK*)(GLenum    errno) */
+(dfc GLU_TESS_EDGE_FLAG      100104)  ;;;  void (CALLBACK*)(GLboolean boundaryEdge)  */
+(dfc GLU_TESS_COMBINE        100105)  ;;;  void (CALLBACK*)(GLdouble  coords[3],
+                                      ;;;                      void      *data[4],
+                                      ;;;                      GLfloat   weight[4],
+                                      ;;;                      void      **dataOut)     */
+(dfc GLU_TESS_BEGIN_DATA     100106)  ;;;  void (CALLBACK*)(GLenum    type,  
+                                     ;;;                       void      *polygon_data) */
+(dfc GLU_TESS_VERTEX_DATA    100107)  ;;;  void (CALLBACK*)(void      *data, 
+                                     ;;;                       void      *polygon_data) */
+(dfc GLU_TESS_END_DATA       100108)  ;;;  void (CALLBACK*)(void      *polygon_data) */
+(dfc GLU_TESS_ERROR_DATA     100109)  ;;;  void (CALLBACK*)(GLenum    errno, 
+                                     ;;;                       void      *polygon_data) */
+(dfc GLU_TESS_EDGE_FLAG_DATA 100110)  ;;;  void (CALLBACK*)(GLboolean boundaryEdge,
+                                     ;;;                       void      *polygon_data) */
+(dfc GLU_TESS_COMBINE_DATA   100111)  ;;;  void (CALLBACK*)(GLdouble  coords[3],
+                                     ;;;                       void      *data[4],
+                                     ;;;                       GLfloat   weight[4],
+                                     ;;;                       void      **dataOut,
+                                     ;;;                       void      *polygon_data) */
+
+;;;  TessError */
+(dfc GLU_TESS_ERROR1     100151)
+(dfc GLU_TESS_ERROR2     100152)
+(dfc GLU_TESS_ERROR3     100153)
+(dfc GLU_TESS_ERROR4     100154)
+(dfc GLU_TESS_ERROR5     100155)
+(dfc GLU_TESS_ERROR6     100156)
+(dfc GLU_TESS_ERROR7     100157)
+(dfc GLU_TESS_ERROR8     100158)
+
+(dfc GLU_TESS_MISSING_BEGIN_POLYGON  GLU_TESS_ERROR1)
+(dfc GLU_TESS_MISSING_BEGIN_CONTOUR  GLU_TESS_ERROR2)
+(dfc GLU_TESS_MISSING_END_POLYGON    GLU_TESS_ERROR3)
+(dfc GLU_TESS_MISSING_END_CONTOUR    GLU_TESS_ERROR4)
+(dfc GLU_TESS_COORD_TOO_LARGE        GLU_TESS_ERROR5)
+(dfc GLU_TESS_NEED_COMBINE_CALLBACK  GLU_TESS_ERROR6)
+
+
+;;; ****           NURBS constants                 ****/
+
+;;; NurbsProperty */
+(dfc  GLU_AUTO_LOAD_MATRIX    100200)
+(dfc  GLU_CULLING             100201)
+(dfc  GLU_SAMPLING_TOLERANCE  100203)
+(dfc  GLU_DISPLAY_MODE        100204)
+(dfc  GLU_PARAMETRIC_TOLERANCE        100202)
+(dfc  GLU_SAMPLING_METHOD             100205)
+(dfc  GLU_U_STEP                      100206)
+(dfc  GLU_V_STEP                      100207)
+
+;;; NurbsSampling */
+(dfc  GLU_PATH_LENGTH                 100215)
+(dfc  GLU_PARAMETRIC_ERROR            100216)
+(dfc  GLU_DOMAIN_DISTANCE             100217)
+
+
+;;; NurbsTrim */
+(dfc  GLU_MAP1_TRIM_2         100210)
+(dfc  GLU_MAP1_TRIM_3         100211)
+
+;;; NurbsDisplay */
+
+(dfc  GLU_OUTLINE_POLYGON     100240)
+(dfc  GLU_OUTLINE_PATCH       100241)
+
+;;; NurbsCallback */
+;;;      GLU_ERROR               100103 */
+
+;;; NurbsErrors */
+(dfc  GLU_NURBS_ERROR1        100251)
+(dfc  GLU_NURBS_ERROR37       100287)
+
 
 (defun-ogl (* glubyte)  "gl-util" "gluErrorString" (glenum error))
-;;;(defun-ogl void "gl-util" "gluGetNurbsProperty" (GLUnurbs *nurb GLenum property GLfloat *data))
 ;;;(defun-ogl GLubyte  *"gl-util" "gluGetString" (GLenum name))
 ;;;(defun-ogl void "gl-util" "gluGetTessProperty" (GLUtesselator *tess GLenum which GLdouble *data))
 ;;;(defun-ogl void "gl-util" "gluLoadSamplingMatrices" (GLUnurbs *nurb GLfloat *model GLfloat *perspective GLint *view))
@@ -46,14 +176,27 @@
 (defun-ogl :void "gl-util" "gluLookAt" (gldouble eye-x gldouble eye-y gldouble eye-z 
                                        gldouble center-x gldouble center-y gldouble center-z 
                                        gldouble upx gldouble upy gldouble upz))
-;;;(defun-ogl GLUnurbs *"gl-util" "gluNewNurbsRenderer" ())
+
 (defun-ogl (* :void) "gl-util" "gluNewQuadric" ())
+
 (defun-ogl :void "gl-util" "gluDeleteQuadric" (:void *quadric))
+
+(defun-ogl (* :void) "gl-util" "gluNewNurbsRenderer" ())
+(defun-ogl :void "gl-util" "gluDeleteNurbsRenderer" (:void *nurb))
+(defun-ogl :void "gl-util" "gluBeginSurface" (:void *nurb))
+(defun-ogl :void "gl-util" "gluEndSurface" (:void *nurb))
+(defun-ogl :void "gl-util" "gluBeginCurve" (:void *nurb))
+(defun-ogl :void "gl-util" "gluEndCurve" (:void *nurb))
+(defun-ogl :void "gl-util" "gluBeginTrim" (:void *nurb))
+(defun-ogl :void "gl-util" "gluEndTrim" (:void *nurb))
+
+(defun-ogl :void "gl-util" "gluGetNurbsProperty" (:void *nurb GLenum property GLfloat *data))
+(defun-ogl :void "gl-util" "gluNurbsCurve" (:void *nurb GLint knotCount GLfloat *knots GLint stride GLfloat *control GLint order GLenum type))
+(defun-ogl :void "gl-util" "gluNurbsProperty" (:void *nurb GLenum property GLfloat value))
+(defun-ogl :void "gl-util" "gluNurbsSurface" (:void *nurb GLint sKnotCount GLfloat *sKnots GLint tKnotCount GLfloat *tKnots GLint sStride GLint tStride GLfloat *control GLint sOrder GLint tOrder GLenum type))
+
 ;;;(defun-ogl GLUtesselator *"gl-util" "gluNewTess" ())
 ;;;(defun-ogl void "gl-util" "gluNextContour" (GLUtesselator *tess GLenum type))
-;;;(defun-ogl void "gl-util" "gluNurbsCurve" (GLUnurbs *nurb GLint knotCount GLfloat *knots GLint stride GLfloat *control GLint order GLenum type))
-;;;(defun-ogl void "gl-util" "gluNurbsProperty" (GLUnurbs *nurb GLenum property GLfloat value))
-;;;(defun-ogl void "gl-util" "gluNurbsSurface" (GLUnurbs *nurb GLint sKnotCount GLfloat *sKnots GLint tKnotCount GLfloat *tKnots GLint sStride GLint tStride GLfloat *control GLint sOrder GLint tOrder GLenum type))
 ;;;(defun-ogl :void "gl-util" "gluOrtho2D" (GLdouble left GLdouble right 
 ;;;                                        GLdouble bottom GLdouble top))
 ;;;(defun-ogl void "gl-util" "gluPartialDisk" (GLUquadric *quad GLdouble inner GLdouble outer GLint slices GLint loops GLdouble start GLdouble sweep))


Index: cell-cultures/cl-opengl/glut-extras.lisp
diff -u cell-cultures/cl-opengl/glut-extras.lisp:1.2 cell-cultures/cl-opengl/glut-extras.lisp:1.3
--- cell-cultures/cl-opengl/glut-extras.lisp:1.2	Fri Oct  1 06:01:29 2004
+++ cell-cultures/cl-opengl/glut-extras.lisp	Fri Oct 15 05:37:55 2004
@@ -85,7 +85,7 @@
     (let ((mmi (uffi:deref-array mm '(:array :int) 0)))
       (glgetintegerv
        (cond
-        ((eql mmi gl_model-view) gl_model-view_stack_depth)
+        ((eql mmi gl_modelview) gl_modelview_stack_depth)
         ((eql mmi gl_projection) gl_projection_stack_depth)
         ((eql mmi gl_texture) gl_texture_stack_depth)
         (t (break "bad matrix")))
@@ -99,7 +99,7 @@
     (let ((mmi (uffi:deref-array mm '(:array :int) 0)))
       (unwind-protect
           (cond
-           ((eql mmi gl_model-view) :model-view)
+           ((eql mmi gl_modelview) :model-view)
            ((eql mmi gl_projection) :projection)
            ((eql mmi gl_texture) :texture)
            


Index: cell-cultures/cl-opengl/nehe-14.lisp
diff -u cell-cultures/cl-opengl/nehe-14.lisp:1.1 cell-cultures/cl-opengl/nehe-14.lisp:1.2
--- cell-cultures/cl-opengl/nehe-14.lisp:1.1	Sat Jun 26 20:38:41 2004
+++ cell-cultures/cl-opengl/nehe-14.lisp	Fri Oct 15 05:37:55 2004
@@ -128,7 +128,7 @@
     (glu-perspective 70 1 1 1000)
     (glu-look-at 0d0 0d0 5d0 0d0 0d0 0d0 0d0 1d0 0d0)
     
-    (gl-matrix-mode gl_model-view)
+    (gl-matrix-mode gl_modelview)
     (gl-load-identity)
     
     


Index: cell-cultures/cl-opengl/ogl-macros.lisp
diff -u cell-cultures/cl-opengl/ogl-macros.lisp:1.2 cell-cultures/cl-opengl/ogl-macros.lisp:1.3
--- cell-cultures/cl-opengl/ogl-macros.lisp:1.2	Fri Oct  1 06:01:29 2004
+++ cell-cultures/cl-opengl/ogl-macros.lisp	Fri Oct 15 05:37:55 2004
@@ -50,8 +50,8 @@
     (glec :with-matrix-push)
     (unwind-protect
         (progn
-          (when (eql gl_model-view_matrix mm-pushed)
-            (gl-get-integerv gl_model-view_stack_depth *stack-depth*)
+          (when (eql gl_modelview_matrix mm-pushed)
+            (gl-get-integerv gl_modelview_stack_depth *stack-depth*)
             (glec :get-stack-depth)
             (print `(with-matrix model matrix stack ,(aforef *stack-depth* 0))))
              


Index: cell-cultures/cl-opengl/ogl-utils.lisp
diff -u cell-cultures/cl-opengl/ogl-utils.lisp:1.2 cell-cultures/cl-opengl/ogl-utils.lisp:1.3
--- cell-cultures/cl-opengl/ogl-utils.lisp:1.2	Fri Oct  1 06:01:29 2004
+++ cell-cultures/cl-opengl/ogl-utils.lisp	Fri Oct 15 05:37:55 2004
@@ -47,7 +47,7 @@
 
 (let (gl-s-plane gl-t-plane gl-r-plane gl-q-plane)
   (defun ogl-tex-gen-setup (mode tex-env tex-wrap scale &rest planes)
-    (ukt::trc nil "ogl-tex-gen-setup:" mode tex-env tex-wrap scale planes)
+    ;;(ukt::trc nil "ogl-tex-gen-setup:" mode tex-env tex-wrap scale planes)
     (gl-tex-envf gl_texture_env gl_texture_env_mode tex-env)
     (gl-tex-parameterf gl_texture_2d gl_texture_min_filter gl_linear )
     (gl-tex-parameterf gl_texture_2d gl_texture_mag_filter gl_linear )





More information about the Cells-cvs mailing list