Author: manolo
Date: 2010-04-13 09:10:08 -0700 (Tue, 13 Apr 2010)
New Revision: 7492
Log:
gl_draw.cxx (Mac-specific): for __ppc__ only, back to old gl_draw algo without 
texture.

Modified:
   branches/branch-1.3/src/gl_draw.cxx

Modified: branches/branch-1.3/src/gl_draw.cxx
===================================================================
--- branches/branch-1.3/src/gl_draw.cxx 2010-04-13 14:26:12 UTC (rev 7491)
+++ branches/branch-1.3/src/gl_draw.cxx 2010-04-13 16:10:08 UTC (rev 7492)
@@ -101,7 +101,7 @@
     wglUseFontBitmaps(fl_gc, base, count, fl_fontsize->listbase+base);
     SelectObject(fl_gc, oldFid);
 # elif defined(__APPLE_QUARTZ__)
-    /* FIXME: no OpenGL Font Selection in Cocoa!
+#if __ppc__
 //AGL is not supported for use in 64-bit applications:
 
//http://developer.apple.com/mac/library/documentation/Carbon/Conceptual/Carbon64BitGuide/OtherAPIChanges/OtherAPIChanges.html
     short font, face, size;
@@ -114,7 +114,7 @@
     fl_fontsize->listbase = glGenLists(256);
        aglUseFont(aglGetCurrentContext(), font, face,
                size, 0, 256, fl_fontsize->listbase);
-     */
+# endif
 # else 
 #   error unsupported platform
 # endif
@@ -123,7 +123,7 @@
 
   }
   gl_fontsize = fl_fontsize;
-#ifndef __APPLE_QUARTZ__
+#if !(defined( __APPLE_QUARTZ__) && !__ppc__)
   glListBase(fl_fontsize->listbase);
 #endif
 }
@@ -196,7 +196,7 @@
 #endif
 }
 
-#ifdef __APPLE__
+#if defined( __APPLE__) && !__ppc__
 static void gl_draw_cocoa(const char* str, int n);
 #endif
 
@@ -207,8 +207,15 @@
   */
 void gl_draw(const char* str, int n) {
 #ifdef __APPLE__  
-  gl_draw_cocoa(str, n);  
+  
+#if !__ppc__
+  gl_draw_cocoa(str, n);
 #else
+// Should be converting the text here, as for other platforms???
+  glCallLists(n, GL_UNSIGNED_BYTE, str);
+#endif
+  
+#else
   static xchar *buf = NULL;
   static int l = 0;
 //  if (n > l) {
@@ -357,7 +364,7 @@
   glDrawPixels(w,h,d<4?GL_RGB:GL_RGBA,GL_UNSIGNED_BYTE,(const ulong*)b);
 }
 
-#if defined( __APPLE__) || defined(FL_DOXYGEN)
+#if (defined( __APPLE__) && !__ppc__) || defined(FL_DOXYGEN)
 
 #include <FL/glu.h>
 

_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit

Reply via email to