|
|
simple texture example on OS X, does not work?
I've downloaded and built a very simple texture example on Mac OS X
10.4.11 from here:
http://www.gamedev.net/reference/programming/features/ogltm/texture.zip
It just needed a few little fixes to compile and build as a "Standard
tool" (C command line):
1. Comment or delete #include <windows.h>
2. Fix the main() declaration
3. Add a line
glutInit(&argc, (char **)argv);
in main()
4. Replace includes
<gl/gl.h> with
#include <GLUT/glut.h>
#include <OpenGL/OpenGL.h>
....
Link with Frameworks OpenGL, GLUT, CoreServices, ApplicationServices
Alas, in the end when you run it, it displays a white rectangle in a
window with a black background, but NO texture....
Any idea what is wrong here? Can you reproduce it? Email me if you'd
like a copy of my code plus project
Thanks
Martin
|
|
0
|
|
|
|
Reply
|
freesteel
|
11/29/2007 3:16:10 PM |
|
"freesteel" <freesteelusenet@googlemail.com> wrote in message
news:697a7e31-b188-40ee-bf4f-20600264eb4f@d61g2000hsa.googlegroups.com...
> I've downloaded and built a very simple texture example on Mac OS X
> 10.4.11 from here:
>
> http://www.gamedev.net/reference/programming/features/ogltm/texture.zip
>
> It just needed a few little fixes to compile and build as a "Standard
> tool" (C command line):
>
> 1. Comment or delete #include <windows.h>
> 2. Fix the main() declaration
> 3. Add a line
> glutInit(&argc, (char **)argv);
> in main()
> 4. Replace includes
> <gl/gl.h> with
> #include <GLUT/glut.h>
> #include <OpenGL/OpenGL.h>
> ...
> Link with Frameworks OpenGL, GLUT, CoreServices, ApplicationServices
>
> Alas, in the end when you run it, it displays a white rectangle in a
> window with a black background, but NO texture....
>
> Any idea what is wrong here? Can you reproduce it? Email me if you'd
> like a copy of my code plus project
>
> Thanks
>
> Martin
Did you check for OpenGL errors ?
jbw
|
|
0
|
|
|
|
Reply
|
jbwest
|
11/28/2007 4:12:49 PM
|
|
APOLOGIES
Very silly: The code does work, the only thing that was broken is that
it never loaded the image file: my error checking was simply wrong and
it assumed we had an image loaded.... very sorry and embarassed.
Martin
|
|
0
|
|
|
|
Reply
|
freesteel
|
12/13/2007 12:15:54 PM
|
|
|
2 Replies
259 Views
(page loaded in 0.17 seconds)
Similiar Articles: simple texture example on OS X, does not work? - comp.graphics.api ...I've downloaded and built a very simple texture example on Mac OS X 10.4.11 from here: http://www.gamedev.net/reference/programming/features/ogltm/te... tdelete() example? - comp.lang.csimple texture example on OS X, does not work? - comp.graphics.api ... I've downloaded and built a very simple texture example on Mac OS X 10.4.11 from here ... Replace Broken Images??? - comp.lang.javascriptsimple texture example on OS X, does not work? - comp.graphics.api ... Replace includes <gl/gl.h> with #include <GLUT/glut.h> #include ... Very silly: The code does work ... Tao.Platform.Windows.SimpleOpenGlControl texture problem - comp ...simple texture example on OS X, does not work? - comp.graphics.api ... Tao.Platform.Windows.SimpleOpenGlControl texture problem - comp ..... working. GL_POINTS & Textures - comp.graphics.api.openglsimple texture example on OS X, does not work? - comp.graphics.api ... GL_POINTS & Textures - comp.graphics.api.opengl So for example: Each vertex can read one texel from ... Help a twit with DB2 and SQL with REXX - comp.lang.rexx... anyone got a very simple example of using a call to SQL from rexx in db2, I am working ... table" > say field.x > > this needless to say does not work ... vs. sqlite - comp.os ... Flash .swf as interactive texture - comp.graphics.api.opengl ...simple texture example on OS X, does not work? - comp.graphics.api ... Flash .swf as interactive texture - comp.graphics.api.opengl ... Does anybody know if there is a ... unblock call to listen? - comp.unix.programmer... listen to unblock? MAC OS X ... :) Thats so simple it might actually allways work! :) ... increment a counter for example, this free runs ... Listen to fungus and not ... Simple code encryption (xor) problem - comp.lang.asm.x86 ...simple texture example on OS X, does not work? - comp.graphics.api ... Simple code encryption (xor) problem - comp.lang.asm.x86 ... The OS is unaware and does > not care ... renderbuffer objects - comp.graphics.api.openglIf that still does not work, try creating the minimal example you were speaking of, so I can ... stuff like displaying the z-buffer as a simple grayscaled texture ... simple texture example on OS X, does not work? - comp.graphics.api ...I've downloaded and built a very simple texture example on Mac OS X 10.4.11 from here: http://www.gamedev.net/reference/programming/features/ogltm/te... Graphics and Animation - Mac OS X Technology Overview - Apple ...... pixel processing pipeline that’s great for working ... design dynamic visualizations that, for example ... OS X Server. Simple, powerful server setup and management for ... 7/25/2012 9:04:28 AM
|
|
|
|
|
|
|
|
|