Re: [osg-users] GLU integration

2010-10-07 Thread Robert Osfield
Hi Stephan,

I checked fixes for these errors yesterday evening - there were
warnings for me with g++ 4.3.3.  Could you do an svn update and let me
know if this fixes things.

Cheers,
Robert.

On Wed, Oct 6, 2010 at 9:11 PM, Stephan Huber ratzf...@digitalmind.de wrote:
 Hi Robert,

 on OS X I get a lot of compile errors in mipmap.cpp:

 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3532:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3532:
 error: invalid conversion from 'void*' to 'GLushort*'


 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3534:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3534:
 error: invalid conversion from 'void*' to 'GLushort*'


 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7394:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7394:
 error: invalid conversion from 'void*' to 'GLushort*'


 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7396:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7396:
 error: invalid conversion from 'void*' to 'GLushort*'


 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:
 error: invalid conversion from 'const void*' to 'const GLubyte*'


 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:
 error:   initializing argument 4 of 'void halveImage_ubyte(GLint,
 GLuint, GLuint, const GLubyte*, GLubyte*, GLint, GLint, GLint)'


 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:0
 /Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:
 error: invalid conversion from 'void*' to 'GLubyte*'


 etc.

 Any hints how to fix this?

 cheers,
 Stephan



 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] GLU integration

2010-10-07 Thread Robert Osfield
Hi All,

I have now moved the subset of glu functions that are now part of the
core OSG library into the osg namespace, so the likes of gluScaleImage
now would be used osg::gluScaleImage.

I have also introduced a gluScaleImage version that doesn't use
glGet's, instead you pass in a PixelStorageModes object that provides
all the appropriate settings.  This version of gluScaleImage is
particularly useful as it allows the function to be used anywhere in
your application - you aren't limited just calling it from a thread
with a valid graphics context.

The osg::Image::scaleImage() and osg::Image::copySubImage() methods
now use this new gluScaleImage function which means that both these
methods can be now called anywhere in your app, at any stage, so you
can move scaling and changing pixel formats into plugins, or into
pre-processing functions in your application.

The osgphotoalbum and osgtexture3D examples both had to use a local
graphics context to do rescaling work then needed to do, and now
thanks to new flexibility they no longer need this temporary graphics
context, so the code is now simplified - one just directly calls the
scale image functions without restriction.

Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] GLU integration

2010-10-07 Thread Stephan Maximilian Huber
Hi Robert,

Am 07.10.10 10:02, schrieb Robert Osfield:
 Could you do an svn update and let me
 know if this fixes things.

Compile went fine for 32bit and 64bit OS X.

Thanks again,

Stephan
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] GLU integration

2010-10-07 Thread Robert Osfield
Hi Stephan,

On Thu, Oct 7, 2010 at 5:54 PM, Stephan Maximilian Huber
ratzf...@digitalmind.de wrote:
 Compile went fine for 32bit and 64bit OS X.

That's excellent news.  Looks like Windows, Linux and OSX now build
fine.  My guess is that other unix platforms will be fine too.

Next step will be to test build out on GLES targets, this may
introduce new problems as the GLU code base won't ever have been used
when building against GLES.

Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] GLU integration

2010-10-06 Thread Robert Osfield
Hi All,

Yesterday I did a review of Mesa's/sgi GLU implementation to look at
the practicality of merging several GLU implementation directly into
the core OSG.  The motivations behind are to make it possible to build
the OSG with the GLU features across all GL targets - including GLES,
and GL 3/4 where GLU is not supported, and also enable us to tweak the
GLU implementations so that we can call them from threads that don't
have a valid graphics context current.  It also simplifies the
dependency chain a little as we will no longer require the external
GLU library.

My review and preliminary experiments with integration went well so
today I bit the bullet and dived in at doing the code integration.  I
now have the OSG building under Linux without the external GLU
library.  The include/osg/GLU header now contains a subset of the
glu.h, with small tweaks to make things compile within the OSG, and
have placed the implementations in src/osg/glu/libutil and glu/libtess
which mirrors the structure found in Mesa so further down the line we
should be able to keep track of changes more easily.

I have already checked my changes in, and have done fresh check-out's
under Linux and everything so far has built. I have feedback from
Jean-Sebastien Guay that things aren't yet compiling under Windows,
and I've applied some of his fixes as well as a few more of my own to
try and get things compiling.  I'm expecting this process to require a
few iterations behind we have a clean build on Windows and Linux.  I
would appreciate testing under other platforms as well.

My hope is that we'll be able to quickly settle the code down and have
it compiling without issue across all platforms.  The more users who
pitch in with testing of svn/trunk the quicker we should be able to
find all the issues and resolve them.  I'll be watching the list like
a hawk for problems and will try and get fixes in a soon as possible.
 I do have to sleep later so it'd be great if we could resolve all the
major problems in the next hour or so, otherwise we might just have
broken build overnight.

Thanks in advance with you assistance on testing,
Robert.

Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] GLU integration

2010-10-06 Thread Stephan Huber
Hi Robert,

on OS X I get a lot of compile errors in mipmap.cpp:

/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3532:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3532:
error: invalid conversion from 'void*' to 'GLushort*'


/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3534:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:3534:
error: invalid conversion from 'void*' to 'GLushort*'


/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7394:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7394:
error: invalid conversion from 'void*' to 'GLushort*'


/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7396:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7396:
error: invalid conversion from 'void*' to 'GLushort*'


/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:
error: invalid conversion from 'const void*' to 'const GLubyte*'


/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:
error:   initializing argument 4 of 'void halveImage_ubyte(GLint,
GLuint, GLuint, const GLubyte*, GLubyte*, GLint, GLint, GLint)'


/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:0
/Users/hudson/.hudson/jobs/osg.current/workspace/osg/src/osg/glu/libutil/mipmap.cpp:7905:
error: invalid conversion from 'void*' to 'GLubyte*'


etc.

Any hints how to fix this?

cheers,
Stephan



___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org