[osg-users] using view dependent overlays
I was looking at the example osganimate and I attempted to use the --ortho option which sets the overlay technique to osgSim::OverlayNode::VIEW_DEPENDENT_WITH_ORTHOGRAPHIC_OVERLAY. However, nothing is overlaid when this method is selected. My assumption is that this method should increase the resolution of the overlaid image as the viewer is zooming into the object receiving the overlay. Someone mentioned that J.P.Delport had a patch to fix this method, but I couldn't find any information on it. I also looked in the trunk and didn't see any updates related to this change. -Blake ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osg::Image pixel format conversion
I actually did check the png writing code and it supports BGRA as of OSG 3.0, however I have to support OSG 2.8 also, which does not have that pixel format yet. I did try acquiring the image from the GPU using GL_RGB but could not get it to work, so I stuck with how osgscreencapture did it. -Blake On 2011-10-31 23:58, J.P. Delport wrote: Hi, is the image coming from the GPU? If so, you can let OpenGL convert it for you on the way to CPU if you don't mind too much about transfer speed. Also, double check the image writing code if a certain format does not support BGRA. jp On 01/11/2011 02:40, Blake Mason wrote: I have a osg::image with pixel format of GL_BGRA. I need to convert it to GL_RGB so that I can write out any generic type of image with osgDB (i.e., jpg, png, tiff, etc). Is there an easy way to convert the _data in the image to be in some other format? I could obviously do this myself with a simple loop, but I wanted to see if there was a simple OSG way. writeImageFile is still commented out in the osgscreencapture.cpp example, and I wonder if it's a similar problem. ___ 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
[osg-users] osg::Image pixel format conversion
I have a osg::image with pixel format of GL_BGRA. I need to convert it to GL_RGB so that I can write out any generic type of image with osgDB (i.e., jpg, png, tiff, etc). Is there an easy way to convert the _data in the image to be in some other format? I could obviously do this myself with a simple loop, but I wanted to see if there was a simple OSG way. writeImageFile is still commented out in the osgscreencapture.cpp example, and I wonder if it's a similar problem. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] osgconv relative to world
I have a .dae file with a model whose vertices are in UTM coordinates. Given the large values of these coordinates a simple conversion will result in a lot of z-fighting issues when I view in OSG viewer. I have tried to translate out this large offset with the -t option and the new --use-world-frame option in osgconv, but it still results in the same z-fighting issue when viewed. In fact, if I output to .osgt and view the VertexData there are still large UTM coordinate values for the vertices. Even worse, it has rounded it down to 6 digits of precision corrupting the geometry. I am on Windows 7, 64 bit built OSG 3.0.1. -Blake ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] File Size Limit on OSG::Image?
If you just need to create a high resoultion rendering from of a single frame, you can modify the camera's projection matrix to capture many smaller segments, something like this: camera-setProjectionMatrix(projMat * osg::Matrix::scale(xSegments, ySegments, 1.0) * osg::Matrix::translate((float)(xSegments) - segmentX*2.0f - 1.0, (float)(ySegments) - segmentY*2.0f - 1.0, 0.0)); I got this idea from the osgcamera example. You can then save an image for each segment with osgDB::writeImageFile and then piece it together with another image editing program. On 2010-12-21 11:30, Geoff Rhodes wrote: Hi, I am currently working on creating a poster image from several images and the file size is pretty large. Currently the one I am trying to create is 65250 wide x 22500 pixels in height (Image needs to be large) Currently I am doing the following: Code: posterImage = new osg::Image; posterImage-allocateImage( (mHeight), (mWidth), 1, GL_RGBA, GL_UNSIGNED_BYTE ); Right now it is giving me an exception when trying to allocate that image. Is there a size limit on it, or am I doing something wrong? ... Thank you! Cheers, Geoff -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35036#35036 ___ 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