Re: [osg-users] DrawElementsUInt no Element of osg
Hi, first of all thank you David. I found the error. I worked with two different OSG versions :-* I took the libs from osg 2.8.3 but used the src from 2.2.0. Cheers, Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40188#40188 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] too much computation
Hi, On 07/06/11 17:34, hemanth korrapati wrote: Thank you for your answer. can I find an example related to this idea ? I can make you one, but that would leave no fun/exploration for you :) Start simple and look at what osgviewer --image myimage.jpg does. Or look at osgmovie. These examples load an osg::Image and place it onto a quad. What you need to do instead of loading the image, is creating an empty image of the right size (and allocating memory for it - see the osg::Image header for the calls) and then poke your values into it. Attach the image to a texture and then attach the texture to a quad. You can set the texture sampling for the texture (search for FilterMode and NEAREST). You can visualise this quad with your texture on in many ways, depending on what camera you use to look at it. E.g. normal OSG camera where you can spin it around, or you can put it in a HUD, or you can make an orthographic camera. HTH jp On Tue, Jun 7, 2011 at 1:27 PM, J.P. Delport jpdelp...@csir.co.za mailto:jpdelp...@csir.co.za wrote: Hi, another option instead of drawing geometry would be to put your data into a texture (image) and then just visualise that. Using nearest sampling would give you little squares too. jp On 07/06/11 12:38, Sebastian Messerschmidt wrote: From the first look I'd advise to split up the geometries and put them into multiple nodes. Looking at the code I don't know which limit you're hitting here, but there are limits in the opengl implementations that might dissallow buffers beyond certain sizes. cheers Sebastian Hi I have modified the createHUD function provided in the 'osgpick' example, for my application as below. Essentially i have to plot a matrix of values on the screen with each matrix entry represented by a square and its color represented by its value. The size of the matrix is 1615 x 1615. when i run the program, it takes a long time with a blank screen before giving a segmentation fault message. Can I get some help on this - the reason for the error and an efficient way to do this, because I may have to plot 6500 x 6500 sized matrices in the future. I have also posted the gdb output below. Thank you == modified createHUD function used in my application osg::Node* createHUD(osgText::Text* updateText, vectorvectordouble simmat, double max) { // create the hud. derived from osgHud.cpp // adds a set of quads, each in a separate Geode - which can be picked individually // eg to be used as a menuing/help system! // Can pick texts too! osg::Camera* hudCamera = new osg::Camera; hudCamera-setReferenceFrame(osg::Transform::ABSOLUTE_RF); hudCamera-setProjectionMatrixAsOrtho2D(0,3200,0,1600); hudCamera-setViewMatrix(osg::Matrix::identity()); hudCamera-setRenderOrder(osg::Camera::POST_RENDER); hudCamera-setClearMask(GL_DEPTH_BUFFER_BIT); std::string timesFont(fonts/times.ttf); // turn lighting off for the text and disable depth test to ensure its always ontop. osg::Vec3 position(100.0f,1550.0f,0.0f); osg::Vec3 delta(0.0f,-60.0f,0.0f); osg::Geode* geode = new osg::Geode(); osg::StateSet* stateset = geode-getOrCreateStateSet(); stateset-setMode(GL_LIGHTING,osg::StateAttribute::OFF); stateset-setMode(GL_DEPTH_TEST,osg::StateAttribute::OFF); for(int i=0; isimmat.size(); i++) { for(int j=0; jsimmat[i].size(); j++) { osg::Geometry *quad=new osg::Geometry; osg::Vec3Array* vertices = new osg::Vec3Array(4); // 1 quad osg::Vec4Array* colors = new osg::Vec4Array; double colorval=simmat[i][j]/max; colors-push_back(osg::Vec4(colorval,colorval,colorval, 1.0)); quad-setColorArray(colors); quad-setColorBinding(osg::Geometry::BIND_PER_PRIMITIVE); osg::Vec3 newpos=position+osg::Vec3(j,i,0);
[osg-users] Setting up a camera
Hi, I'm trying to write something like a flightsimulator for simulating a sensor. For this I have some world data for my scene. Now I'm trying to create a camera. But the camera doesen't look to where I want it to look at. I get the following values - the position in lat[deg], lon[deg] and height[meter] - the orientation in pitch, roll and yawn in [rad] - the field of view in [rad] splittedt in fov_x_begin, fov_x_end etc - the distance sensing in [meter] from a server. Position and orientation are changing constantly, but first of all I would be happy if I get the right view with some default values. I tried it with setViewMatrix() and setHomePosition() but nothing happens. Maybe I used it wrong but maybe someone can tell me how I have to realize it. Im using osg 2.8.1 with vc8. The camera coordinate have to be with positive z-Axis as the camera view, +y-Axis up and +x-axis to the left. Thank you! Cheers, Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40190#40190 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] Build OSG using DCMTK
Hi Isa, From your description I can't work out what might be wrong. What you could try just pointing osgvolume at the directory that contains the separate dcm images. i.e. osgvolume DirectoryContainingDicomImages osgvolume will work out that you are referring directory and the dicom plugin will then treat all images within that directory as a single set of assocaited dicom files and build an 3D osg::Image from it, and then the osgVolume NodeKit will take this and do all the rendering for you. Robert. On Tue, Jun 7, 2011 at 9:01 PM, Isha Kandaswamy isha.kandasw...@gmail.com wrote: Hi, I checked, and added the links and it worked ,thanks :) .. but still the volume it seems to render is not correct.. It should look like a skull and it looks like random set of lines.. Is there a problem with the way im using the osgvolume?? I use it as osgvolume --images *.dcm to create the volume ... Thank you! Cheers, Isha -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40181#40181 ___ 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] Setting up a camera
Hi Diana, If you are controlling the camera from a user defined path or simulation then you are best to not attach a camera manipulator to the viewer and just set the viewer's master camera directly yourself. If you do try to set the camera's view matrix yourself but still have a camera manipualtor attached the value you set will be overwritten. The osgViewer::Viewer by default will not attach a camera manipulator, but if you call viewer.run() it will know assume there isn't anything else settings the view matrix so will attach a camera manipulator as a fallback to at least provide some interactive view. For your own app I'd expect something like: osgViewer::Viewer viewer; viewer.setSceneDat(mySceneGraph); viewer.realize(); while(!viewer.done()) { viewer.getCamera()-setViewMatrix(myViewMatrix); // or use setViewMatrixAsLookAt(..) viewer.frame(); } Robert. On Wed, Jun 8, 2011 at 8:38 AM, Diana Kittelmann diana.kittelm...@gmx.de wrote: Hi, I'm trying to write something like a flightsimulator for simulating a sensor. For this I have some world data for my scene. Now I'm trying to create a camera. But the camera doesen't look to where I want it to look at. I get the following values - the position in lat[deg], lon[deg] and height[meter] - the orientation in pitch, roll and yawn in [rad] - the field of view in [rad] splittedt in fov_x_begin, fov_x_end etc - the distance sensing in [meter] from a server. Position and orientation are changing constantly, but first of all I would be happy if I get the right view with some default values. I tried it with setViewMatrix() and setHomePosition() but nothing happens. Maybe I used it wrong but maybe someone can tell me how I have to realize it. Im using osg 2.8.1 with vc8. The camera coordinate have to be with positive z-Axis as the camera view, +y-Axis up and +x-axis to the left. Thank you! Cheers, Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40190#40190 ___ 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] Absolute beginner questions
Hi Basil, On OpenSceneGraph.sln choose to compile the project ALL_BUILD , rather than Rebuild Solution. hopes it help :) Mohamed ALJI -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40193#40193 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Setting up a camera
Thanks Robert, but when I try viewer.setSceneData(loadedModel); viewer.realize(); while(!viewer.done()) { ... viewer.frame(); } it doesen't display my scene. viewer.run() works fine. Diana. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40194#40194 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Meta-data in core OSG - project started
Hi Peter, On Tue, Jun 7, 2011 at 9:51 PM, Peter Amstutz peter.amst...@tseboston.com wrote: Thank you for taking up this task. While not central to the mission of graphics rendering, this feature will certainly make writing applications around OSG a little bit easier for all of us. My proposal for putting get/setUserValue convenience methods directly osg::Object was based on the idea that the interface methods on osg::UserDataContainer would accept the parent object as a parameter, thus allowing a single container instance to be shared while providing different data to different callers. Um... I find this idea to be a bit awkward and only really at useful for very specific usage model where you want a single custom UserDataContainer to maanage all user data access for the scene graph. If you don't use share a single UserDataContainer between objects then passing the Object pointer is pointless and confusing - and this will be the default scheme used by the vast majority of users. Having multiple custom UserDataContainer that reference single central data container is possible with the current scheme and wouldn't polute a small numbers of users needs into the core classes. Without that aspect, having get/setUserValue on osg::Object still offers some convenience but also introduces confusion and redundancy. Also, the ability to set any osg::Object as the metadata container for any other osg::Object seems like an invitation for chaos. I think chaos is a rather overblown suggestion. The latest rev isn't an ideal class layout, and as I've said it does feel awkward but I don't ever expect anything other than a tiny proportion of users to ever need to assign their own UserDataContainer let alone provide a custom UserDataContainer, I strongly doubt that the ability to attach a normal osg::Object as a user data container is likely to cause any problems. I think the pattern you describe as object-getUserDataContainer()-get...() is acceptable, and is perfectly consistent with the existing scene graph patterns in OSG (setting up StateSets in particular comes to mind -- indeed recently someone wanted to use StateSets as an ad-hoc metadata scheme). My preference looks like: class osg::Object { // access _userDataContainer osg::UserDataContainer* getUserDataContainer(); void setUserDataContainer(osg::UserDataContainer*); osg::UserDataContainer* getOrCreateUserDataContainer(); // for backwards compatibility, defer to _userDataContainer virtual get/setDescriptions(); virtual get/setUserData(); }; // abstract base class user data container class osg::UserDataContainer : public osg::Object { // returns self osg::UserDataContainer* getUserDataContainer(); osg::UserDataContainer* getOrCreateUserDataContainer(); // throws exception/assertion or otherwise fails void setUserDataContainer(osg::UserDataContainer*); small note, I'm avoiding use of exceptions in the core, due to the needs of embedded OSG usage - I don't want different behaviours on different builds. This seems very straightforward and avoids cluttering up osg::Object. Is there a reason this approach was rejected, aside from a desire to avoid the object-getUserDataContainer()-get...() pattern? There is a little awkward issue of having a ref_ptr to sublcass of osg::Object from within an osg::Object itself. To get around this you'd need to define any subclass as a nested class of osg::Ojbect, which... polutes osg::Object so it's swings and rounabouts with sticking the functionality in a subclass. If a single user data container instance is referenced by multiple nodes, will it be serialized once or multiple times? Once, all osg::Object are serailized with an unique object id that is written out once then subsequent refrences to the that Object used the object id. When the data is read back in the serializers just create on instance and then share it. This feature automatically will work for user data. Can a user data container contain references to osg::Objects in the same scene graph? Can the serializers handle this? They are all just osg::Object's they all just get seralized out. The osguserdata example attaches an osg::Geometry as a user object and it gets serialized in and out correctly. The only thing you'd need to be minful of is if a UserDataContainer holds a referneced to a paret - this would cause a circular refefence that would prevent all the objects in the loop and their children from being deleted. This is a standard issue for any ref counted data strucutre so isn't a specific to user data, it's just an issue users need to be mindful. W.r.t you suggestion. Feel free to go ahead an implement what you are thinking of, reviewing stuff thta actually is implemented and working in header and source files is far more pratical than second guessing write ups in emails. The only part I feel strongly is the wrong way is the passing of the Object* to the access methods in UserData,
Re: [osg-users] Setting up a camera
Hi Diana, On Wed, Jun 8, 2011 at 9:29 AM, Diana Kittelmann diana.kittelm...@gmx.de wrote: it doesen't display my scene. viewer.run() works fine. What do you mean, doesn't display your scene. What do you see? Just the default blue backgroud? Did you set your view matrix to look at the scene? If you don't have a camera manipulator doing this for you'll need to set this yourself. Is it that you are struggiling with the maths of how to set a view matrix? Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Computing Near and Far problem when viewing large terrain and small object
Hi, My applicaiton use a quiet large terrain model (about 4000KM*4000KM),and when I viewing some very small flying objects(about 20m*20m) above the terrain ,the object seems been culled. I know it is the Near and Far Plane issue,so I setComputeNearFarMode(osg::CullSetting::COMPUTE_NEAR_FAR_USING_PRIMITIVES); setNearFarRation(0.0001); It solves the problem,make the small objects visible. However it causes another problem ,I have also loaded some vector GIS models (such as roads,country boundraies) which made by osgGIS. When I COMPUTE NEAR FAR USING PRIMITIVES,the vector models cause me 50% ~60% CPU usage!When I disabled COMPUTE NEAR FAR USING PRIMITIVES,or hiding the vector models ,it only cost me 10%~15% CPU usage.The vector models is only 3.5mb. Is there a better solution to solve this problem? Thank you! Cheers, Lv -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40196#40196 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Computing Near and Far problem when viewing large terrain and small object
Hi Lv, If you have a scene with a very large distance range then depth precision is an awkward issue to deal with - the lower the near/far ratio the lower the precision. To retain precision you have to either push out the near plane or pull in the far plane, and they work as ratios so doubling the distance of the far plane is equivilant to pulling the far distance by half. You can juggle the exact distance computation but in the end if you need to render something very near and somehing very far you are forced to have a small near and large far values and with it precision issues. When you are in this situation the only practical thing to do is to depth partition your scene so that you render it into two or more sections. Basically you render the far section first then overlay the nearer sections on top of this, with the overlay sections clearing the depth buffer but not the colour buffer. In OSG 2.8.x there is an osgdepthpartion example that uses a series of in scene graph osg::Camera to set up the partitioning. It's quite clucky and awkward though so I wouldn't recommend. A much easier and flexible means of manage the depth partition is to set up multple slave Camera's in the view to do the job of the depth partitioning, this way the viewer configuration changes when you want to change to depth partition and the scene graph remains the same. In svn/trunk and 2.9.x there is support for creating slave Cameras to do depth partitioning, see the osgshadow example for this. Look for the section that does viewer.setUpDepthPartition(). Robert. On Wed, Jun 8, 2011 at 9:39 AM, Lv Qing donlvq...@msn.com wrote: Hi, My applicaiton use a quiet large terrain model (about 4000KM*4000KM),and when I viewing some very small flying objects(about 20m*20m) above the terrain ,the object seems been culled. I know it is the Near and Far Plane issue,so I setComputeNearFarMode(osg::CullSetting::COMPUTE_NEAR_FAR_USING_PRIMITIVES); setNearFarRation(0.0001); It solves the problem,make the small objects visible. However it causes another problem ,I have also loaded some vector GIS models (such as roads,country boundraies) which made by osgGIS. When I COMPUTE NEAR FAR USING PRIMITIVES,the vector models cause me 50% ~60% CPU usage!When I disabled COMPUTE NEAR FAR USING PRIMITIVES,or hiding the vector models ,it only cost me 10%~15% CPU usage.The vector models is only 3.5mb. Is there a better solution to solve this problem? Thank you! Cheers, Lv -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40196#40196 ___ 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] SwitchNode Animation with a specific time interval
Hi Vijay, On 7/06/11 23:32 , Vijay Kalivarapu wrote: I have a bunch of timesteps of data that I need to animate between. I set up my code so that each timestep corresponds to a switch node and I attempted to animate between each switchnode. ... Currently, the speed at which the switch node is animating between timesteps is machine dependent. In other words, the animation speed is dependent on the machine that could count to 30 quick enough. I would ideally like the animation to happen at a specific time interval instead and hoping to avoid the Have you considered using osg::Sequence? It does exactly that, switch between nodes based on times. Cheers, /ulrich ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Setting up a camera
Yeah, I'm just seeing the blue background. And yaeh im struggeling with the math to set up my matrix. I set it up like this: while(!viewer.done()) { osg::EllipsoidModel convert; convert.convertLatLonHeightToXYZ(lat, lon, height, x, y, z); osg::Vec3 pos(x, y, z); osg::Matrixd matrix; matrix.setRotate(osg::Quat(osg::DegreesToRadians(0.0), osg::X_AXIS, osg::DegreesToRadians(0.0), osg::Y_AXIS, osg::DegreesToRadians(0.0), osg::Z_AXIS)); matrix.setTrans(pos); viewer.getCamera(); viewer.frame(); } But I'm not sure if this is right. Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40200#40200 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Shaders and Nvidia 275.33 drivers problem
Hello I have win7 x64 nvidia video card I found strange problem after update to version 275.33 of nvidia drivers. I see artifacts with shaders, i tried to find why. Part of shader uniform variables are not work correctly. i try to debug it with gdebugger and i noticed non-initialized values in part of uniforms. file src/osg/Program.cpp lines 672-673 Code: _extensions-glGetActiveUniform( _glProgramHandle, i, maxLen, 0, size, type, name ); Later i found that names of array variables coming with [0]. example - %name%[0] i tested with 266.58 they coming without [0] as result in _uniformInfoMap[Uniform::getNameID(reinterpret_castconst char*(name))] = ... we recording values with [0]. file src/osg/Program.cpp lines 213 Code: inline void apply(const Uniform uniform) const { GLint location = getUniformLocation(uniform.getNameID()); if (location=0) and here we can't get right location i fix it, please look patch Code: --- a/OpenSceneGraph/src/osg/Uniform.cpp +++ b/OpenSceneGraph/src/osg/Uniform.cpp @@ -611,13 +611,13 @@ unsigned int Uniform::getNameID(const std::string name) static UniformNameIDMap s_uniformNameIDMap; OpenThreads::ScopedLockOpenThreads::Mutex lock(s_mutex_uniformNameIDMap); -UniformNameIDMap::iterator it = s_uniformNameIDMap.find(name); +UniformNameIDMap::iterator it = s_uniformNameIDMap.find(name.substr(0, name.find([))); if (it != s_uniformNameIDMap.end()) { return it-second; } unsigned int id = s_uniformNameIDMap.size(); -s_uniformNameIDMap.insert(UniformNameIDMap::value_type(name, id)); +s_uniformNameIDMap.insert(UniformNameIDMap::value_type(name.substr(0, name.find([)), id)); return id; } But i don't think that is a good solution. Thank you! Cheers, Alexander -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40201#40201 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Setting up a camera
Hi Diana, I'm afraid I don't have the time to write up a full tutorual on maths of setting view matrixes and matrix maths, the topic has been covered lots of time by the community so I'd recommend you have a look through the archhives. As a quite note, I'd mention that in OpenGL and the OSG the view matrix translates the world coordinates into the eye coordinates, and eye coordinates are +ve X to the right, +ve Y up, +veZ out from the screen. While in vis-sim the convention is that world coordinates of the scene have +ve X to the east, +ve Y north +ve Z up. Please note that the scene is in world coordinates, and the view matrix transforms the world cooridnates into eye coordinates, the view matrix doesn't position the eye into the scene but the other way around - this is important as it's the inverse matrix of a matrix that positions an object in the scene in world coordinates. This later point is probably where you have gone wrong. I won't dive in any further as teaching users about maths is not my role - I have plenty of other work to do. Please spend some time looking into the background maths, there are a huge number of articles on the web and posts on osg-users over the years. Robert. On Wed, Jun 8, 2011 at 9:59 AM, Diana Kittelmann diana.kittelm...@gmx.de wrote: Yeah, I'm just seeing the blue background. And yaeh im struggeling with the math to set up my matrix. I set it up like this: while(!viewer.done()) { osg::EllipsoidModel convert; convert.convertLatLonHeightToXYZ(lat, lon, height, x, y, z); osg::Vec3 pos(x, y, z); osg::Matrixd matrix; matrix.setRotate(osg::Quat(osg::DegreesToRadians(0.0), osg::X_AXIS, osg::DegreesToRadians(0.0), osg::Y_AXIS, osg::DegreesToRadians(0.0), osg::Z_AXIS)); matrix.setTrans(pos); viewer.getCamera(); viewer.frame(); } But I'm not sure if this is right. Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40200#40200 ___ 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] Setting up a camera
On 8/06/11 10:59 , Diana Kittelmann wrote: Yeah, I'm just seeing the blue background. And yaeh im struggeling with the math to set up my matrix. I set it up like this: while(!viewer.done()) { osg::EllipsoidModel convert; convert.convertLatLonHeightToXYZ(lat, lon, height, x, y, z); osg::Vec3 pos(x, y, z); osg::Matrixd matrix; matrix.setRotate(osg::Quat(osg::DegreesToRadians(0.0), osg::X_AXIS, osg::DegreesToRadians(0.0), osg::Y_AXIS, osg::DegreesToRadians(0.0), osg::Z_AXIS)); matrix.setTrans(pos); viewer.getCamera(); viewer.frame(); } But I'm not sure if this is right. Did you forget to include the bit where you set the matrix to the camera? Something like: viewer.getCamera()-setViewMatrix(matrix); /ulrich ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Call osgAnimation::Animation::setDuration several times
Hi, I have a problem with the call setDuration of osgAnimation::Animation. If I define the animations at the beginning of the application do it correctly. But if I change the duration, defined above, in execution, for example by putting half the time, makes the animation faster but twice ... may be a bug? Code: osgAnimation::ActionStripAnimation* newAnimAction = new osgAnimation::ActionStripAnimation(anim,0.3,0.3); anim-setDuration(anim-getDuration()*0.5); newAnimAction-setLoop(1); // one time tml-addActionAt(tml-getCurrentFrame() + 1,newAnimAction, 2); Thank you! Cheers, Aitor -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40205#40205 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Setting up a camera
Thanks alot Robert. I try to teach me some math on my own now, but your answers were really helpful. @ulrich I did include I just missed to write it in my Post. Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40207#40207 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Shaders and Nvidia 275.33 drivers problem
The 275.33 Drivers are not good I personally would avoid like the plague, they are causing all sorts of problems for people Gordon Tomlinson System Engineering Consultant Overwatch® An Operating Unit of Textron Systems __ WARNING: Documents that can be viewed, printed or retrieved from this E-Mail may contain technical data whose export is restricted by the Arms Export Control Act (Title 22, U.S.C., Sec 2751, et seq,) or the Export Administration Act of 1979, as amended, Title 50, U.S.C., App. 2401 et seq. and which may not be exported, released or disclosed to non-U.S. persons (i.e. persons who are not U.S. citizens or lawful permanent residents [green card holders]) inside or outside the United States, without first obtaining an export license. Violations of these export laws are subject to severe civil, criminal and administrative penalties. -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Alexander Sinditskiy Sent: Wednesday, June 08, 2011 5:04 AM To: osg-users@lists.openscenegraph.org Subject: [osg-users] Shaders and Nvidia 275.33 drivers problem Hello I have win7 x64 nvidia video card I found strange problem after update to version 275.33 of nvidia drivers. I see artifacts with shaders, i tried to find why. Part of shader uniform variables are not work correctly. i try to debug it with gdebugger and i noticed non-initialized values in part of uniforms. file src/osg/Program.cpp lines 672-673 Code: _extensions-glGetActiveUniform( _glProgramHandle, i, maxLen, 0, size, type, name ); Later i found that names of array variables coming with [0]. example - %name%[0] i tested with 266.58 they coming without [0] as result in _uniformInfoMap[Uniform::getNameID(reinterpret_castconst char*(name))] = ... we recording values with [0]. file src/osg/Program.cpp lines 213 Code: inline void apply(const Uniform uniform) const { GLint location = getUniformLocation(uniform.getNameID()); if (location=0) and here we can't get right location i fix it, please look patch Code: --- a/OpenSceneGraph/src/osg/Uniform.cpp +++ b/OpenSceneGraph/src/osg/Uniform.cpp @@ -611,13 +611,13 @@ unsigned int Uniform::getNameID(const std::string name) static UniformNameIDMap s_uniformNameIDMap; OpenThreads::ScopedLockOpenThreads::Mutex lock(s_mutex_uniformNameIDMap); -UniformNameIDMap::iterator it = s_uniformNameIDMap.find(name); +UniformNameIDMap::iterator it = s_uniformNameIDMap.find(name.substr(0, name.find([))); if (it != s_uniformNameIDMap.end()) { return it-second; } unsigned int id = s_uniformNameIDMap.size(); -s_uniformNameIDMap.insert(UniformNameIDMap::value_type(name, id)); +s_uniformNameIDMap.insert(UniformNameIDMap::value_type(name.substr(0, name.find([)), id)); return id; } But i don't think that is a good solution. Thank you! Cheers, Alexander -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40201#40201 ___ 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] [osgPlugins] Is fx required while building collada on Linux?
Hi, I was trying to build the OSG Collada plugin for Xcode. I followed the step-by-step instruction on http://www.openscenegraph.org/projects/osg/wiki/Support/KnowledgeBase/Collada, but I get the same error as Siddhi: Compiling src/cfxAnnotatable.cpp to build/mac-1.4/obj/cfxAnnotatable.o In file included from src/cfxAnnotatable.cpp:9: include/cfxAnnotate.h:15:19: error: Cg/cg.h: No such file or directory In file included from src/cfxAnnotatable.cpp:9: include/cfxAnnotate.h:43: error: ‘CGannotation’ does not name a type include/cfxAnnotate.h:54: error: ‘CGannotation’ does not name a type make[1]: *** [build/mac-1.4/obj/cfxAnnotatable.o] Error 1 make: *** [all] Error 2 How can I solve this problem? Any suggestion is appreciated. Thank you! Cheers, Büsra -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40209#40209 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Call osgAnimation::Animation::setDuration several times
In fact related to the code it makes sense. Because strip duration is initialized from the Animation duration. Could you try to manipulate the duration of the strip instead ? Cedric On Wed, 2011-06-08 at 12:52 +0200, Aitor Ardanza wrote: Hi, I have a problem with the call setDuration of osgAnimation::Animation. If I define the animations at the beginning of the application do it correctly. But if I change the duration, defined above, in execution, for example by putting half the time, makes the animation faster but twice ... may be a bug? Code: osgAnimation::ActionStripAnimation* newAnimAction = new osgAnimation::ActionStripAnimation(anim,0.3,0.3); anim-setDuration(anim-getDuration()*0.5); newAnimAction-setLoop(1); // one time tml-addActionAt(tml-getCurrentFrame() + 1,newAnimAction, 2); Thank you! Cheers, Aitor -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40205#40205 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- Cedric Pinson Provide OpenGL, WebGL and OpenSceneGraph services +33 659 598 614 - cedric.pin...@plopbyte.com http://plopbyte.com - http://osgjs.org - http://showwebgl.com signature.asc Description: This is a digitally signed message part ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Call osgAnimation::Animation::setDuration several times
Ok, I also needed to be defined in ActionStripAnimation. It works now! Thank you! Cheers, Aitor -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40211#40211 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] WWDC 2011
Hi Eric, I didn't make it this year (the 12-hour window before it sold out was way too short!) Perhaps I'll make it next year, but I'm not doing much on my mac these days (besides running Linux on it). Eric S. On Tue, Jun 7, 2011 at 11:45 PM, Eric Wing ewmail...@gmail.com wrote: Hi all, If anybody is at WWDC this year, please drop me a line if you'd like to meet up. Thanks, Eric -- Beginning iPhone Games Development http://playcontrol.net/iphonegamebook/ ___ 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] Rendering of 3d model over the video stream
Thanks for reply! I connected the camera, which returns createHud to osgViewer, Hud has been successfully drawn over the 3D-model, but when i change POST_RENDER to PRE_RENDER, an image of 3D-model (simple pyramid) among an empty space entirely overlaps Hud -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40212#40212 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Rendering of 3d model over the video stream
Hi Kataev? Victor? Could you sign with the name you'd like to be addressed as it's difficult to guess. On Wed, Jun 8, 2011 at 1:56 PM, Kataev Victor victor1...@list.ru wrote: I connected the camera, which returns createHud to osgViewer, Hud has been successfully drawn over the 3D-model, but when i change POST_RENDER to PRE_RENDER, an image of 3D-model (simple pyramid) among an empty space entirely overlaps Hud The main Camera will be clearing the colour buffer and depth buffer before it draws, so what you need to do is disable the clear of the colour buffer. The osghud example shoes this for the HUD camera which is the overlay, you just need to apply this to the main viewer's Camera or what ever Camera you are using for the main 3D scene. Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPPU] Render lower Resolution with unitOut than wandow / fullscreen
Hi All, @Ricky, it works for me as expected now. First I attach a new viewport with e.g. half res of my output window, and attach a texture with the same half res to the Color Buffer of the Camera. This can be done with different Cams and resolutions, if you have some funky pipeline. camera - setViewport( new osg::Viewport( 0 , 0 , halfResWidth , halfResHeight ) ) ; camera - attach( osg::Camera::COLOR_BUFFER0 , textureColor ) ; // has also halfResWidth/Height At the end of the pipeline I tell the unitOut not to use any camera viewport as ( size ) reference, and add another Viewport with the full resolution of my output window. unitOut - setInputTextureIndexForViewportReference( -1 ) ; // Don't use any Camera Viewport as reference unitOut - setViewport( new osg::Viewport( 0 , 0 , fullResWidth , fullResHeight ) ) ; That's it. @Art With out of Sync I meant that the visual scale of the Glowed scene had not the same size as the visual scale of the non glowed scene. My mistake was, that I tried to scale up the viewports that were attached to the cameras ( main and glow ), but should have done that with the viewport attached to unitOut. Everything is working fine now :-) But still a good Debugging Hint, didn't know that till now. Cheers, PP -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40215#40215 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] OSG 2.9.10 on iOS
Hi, I thougt, that when I start Xcode and go to File - New Project… and choose IOS - Application in the drawer, there will appear OSG Application. But it isn´t so. Was my thougth false or what should I do in order that it appear? Because I want to create a new OSG-Project like the project in github. I have to load/open a collada-file. And the github-project doesn´t support collada-plugin. Can you please give me advice, what I have to do? Thank you! Cheers, Büsra -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40216#40216 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Setting up a camera
Hi Diana, I find it pretty convenient to use Code: getCamera()-setViewMatrixAsLookAt (const osg::Vec3 eye, const osg::Vec3 center, const osg::Vec3 up) for setting up the view matrix, it was one of Robert's suggestions but I thought I'd re-emphasize it. Vec3 eye will be the position you're getting from the server. Vec3 center will be the point the camera is aiming at - it doesn't have to be the center of the scene, if you are given or can calculate the direction vector the camera is pointing along, (0,1,0) for example to look along the y-axis, you can add that to your eye point and use the result as center. Vec3 up orients the camera, think about taking a photo in portrait vs landscape vs some other angle. To start if you know the coordinates of some point in the scene, you could use that as center and just play with changing eye, the camera will always look at the same point (center) but from different places. After that, you could then work on calculating center based on the orientation you're receiving from the server. HTH, Cheers, Tom -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40217#40217 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] [osgOcean] FFTSS License
Hi all, The osgOcean wiki mentions that FFTSS is released under LGPL. I can't find any reference to LGPL on their website or in the source code... Does anyone know where that information came from? The text in the FFTSS COPYING file seems more liberal than LGPL, basically saying you have to give us credit... Thanks, Nathan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40218#40218 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Absolute beginner questions
For consistency's sake, I did a clean solution then build solution of ALL_BUILD with the same results (massive errors). Any ideas? -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40219#40219 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osgEarth at FOSS4G in Denver
Folks, Our FOSS4G presentation has been accepted! Thanks to everyone who took the time to cast a vote. We hope to see some of you in Denver this September! Glenn Waldron / Pelican Mapping / @glennwaldron On Wed, Apr 27, 2011 at 11:53 AM, Glenn Waldron gwald...@gmail.com wrote: osgEarth users (and anyone else interested in 3D terrain), We have submitted an abstract for an osgEarth presentation at this year's FOSS4G conference in Denver. FOSS4G selects presenters based on a community vote, so we need your support! The abstract is entitled Open Source 3D Globes with osgEarth. Please follow the following link to review abstracts and cast a vote for us. Thanks for your support!! http://community-review.foss4g.org/ Glenn Waldron / Pelican Mapping / @glennwaldron ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] OSG Qt integration
Hi, I'm using Qt 4.6.3 together with OSG 2.9.8 (precompiled from http://www.multigesture.net/articles/how-to-compile-openscenegraph-2-x-using-mingw/). I have tried several ways to render an OSG window on top of the Qt GUI. I always get the same behaviour, that is, when I open OSG viewer for the first time it works just fine, I close, I re-open, and problems arise. Debugging using gremedy gdebugger I found out that memory leaks arise when I close the OSG viewer. I tried with my own implementation. I also tried http://www.openscenegraph.org/projects/osg/browser/OpenSceneGraph/trunk/examples/osgviewerQtWidget/QOSGWidget.cpp and didn't work, same problem. By the way, I asked this question a while ago and never got and answer but I observed taht somebody removed QOSGWidget from the repository after I did my question. There's this implementation: http://hipersayanx.blogspot.com/2011/04/qt-openscenegraph-offscreen-rendering.html I read in the forum somebody recommending this. On the other hand, when I use this implementation, not in my code, the viewer is slow and pixelated, it doesn't seem the best solution. Any other suggestions? Which is the best Qt-OSG integration? I saw that OSG2.9.8 comes with some osgqt library and that this library was improved in 2.9.9. Do I have any helpful utilities here? I'm not a programmer so it's difficult to me to move from one distribution to another easily. I just need a good Qt-OSG implementation that guarantees that everytime I close a context and re-open it keeps everything tidy and in place so no memory leaks don’t appear. I would be really thankful for any hints since I’m kind of lost and my app is stuck just at this point. Thank you very much in advance. ... Thank you! Cheers, Juan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40221#40221 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] OSG Qt integration
Hi Juan, I can't comment on the possible memory leak with using Qt. What I can say is that quite has bit has changed in the OSG and it's Qt integration since 2.9.8 so I would recommend grabbing the svn/trunk or 2.9.15 dev release and building this directly yourself. If you still see issues then it would be best to implement a small example that illustrates the problem, such as modifiying one of the OSG's Qt examples, so that others in the community can see if they can reproduce the problem, and if there is a bug we can look into it. It doesn't make an sense for us to go chasing up and old dev release though, all dev work goes into svn/trunk, so you'll need to move to svn/trunk or the latest dev release so we can all work on the same base. Robert. On Wed, Jun 8, 2011 at 4:18 PM, Juan Valverde jvalver...@gmail.com wrote: Hi, I'm using Qt 4.6.3 together with OSG 2.9.8 (precompiled from http://www.multigesture.net/articles/how-to-compile-openscenegraph-2-x-using-mingw/). I have tried several ways to render an OSG window on top of the Qt GUI. I always get the same behaviour, that is, when I open OSG viewer for the first time it works just fine, I close, I re-open, and problems arise. Debugging using gremedy gdebugger I found out that memory leaks arise when I close the OSG viewer. I tried with my own implementation. I also tried http://www.openscenegraph.org/projects/osg/browser/OpenSceneGraph/trunk/examples/osgviewerQtWidget/QOSGWidget.cpp and didn't work, same problem. By the way, I asked this question a while ago and never got and answer but I observed taht somebody removed QOSGWidget from the repository after I did my question. There's this implementation: http://hipersayanx.blogspot.com/2011/04/qt-openscenegraph-offscreen-rendering.html I read in the forum somebody recommending this. On the other hand, when I use this implementation, not in my code, the viewer is slow and pixelated, it doesn't seem the best solution. Any other suggestions? Which is the best Qt-OSG integration? I saw that OSG2.9.8 comes with some osgqt library and that this library was improved in 2.9.9. Do I have any helpful utilities here? I'm not a programmer so it's difficult to me to move from one distribution to another easily. I just need a good Qt-OSG implementation that guarantees that everytime I close a context and re-open it keeps everything tidy and in place so no memory leaks don’t appear. I would be really thankful for any hints since I’m kind of lost and my app is stuck just at this point. Thank you very much in advance. ... Thank you! Cheers, Juan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40221#40221 ___ 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] Setting up a camera
Diana, First off, I don't see where you're setting the view matrix for the camera in your code below. You compute the transform, but you'll need to attach it to the camera. Since it looks like you're navigating on a sphere, I would try the following in your while loop below... osg::EllipsoidModel convert; osg::Matrixd position; osg::Matrixd t_matrix; convert.computeLocalToWorldTransformFromLatLongHeight(lat,lon,height,pos ition); t_matrix = position; t_matrix.invert(t_matrix); osg::Matrixd rotate2YUp; rotate2YUp.makeRotate(-M_PI_2, osg::Vec3f(1.0, 0.0, 0.0)); t_matrix *= rotate2YUp; viewer.getCamera()-setViewMatrix(t_matrix); viewer.frame(); Of course, I'm assuming that you have all the other camera state (i.e. projection matrix, viewport, etc.) set up correctly. The above doesn't include an orientation transform so you will need to add that. When you do, it will be concatenated with the position matrix. Make sure that lat, lon are in RADIANS when you call computeLocalToWorldTransformFromLatLongHeight. Height is usually in meters. One more thing...it would probably be best to move the code outside of the while loop and place it in an UpdateCallback... -Shayne -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Diana Kittelmann Sent: Wednesday, June 08, 2011 2:59 AM To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] Setting up a camera Yeah, I'm just seeing the blue background. And yaeh im struggeling with the math to set up my matrix. I set it up like this: while(!viewer.done()) { osg::EllipsoidModel convert; convert.convertLatLonHeightToXYZ(lat, lon, height, x, y, z); osg::Vec3 pos(x, y, z); osg::Matrixd matrix; matrix.setRotate(osg::Quat(osg::DegreesToRadians(0.0), osg::X_AXIS, osg::DegreesToRadians(0.0), osg::Y_AXIS, osg::DegreesToRadians(0.0), osg::Z_AXIS)); matrix.setTrans(pos); viewer.getCamera(); viewer.frame(); } But I'm not sure if this is right. Diana -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40200#40200 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or g ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] SwitchNode Animation with a specific time interval
Thanks Ulrich. I didn't know about this earlier. Looks like this is what I might need. I will post my findings on this soon. ... Thank you! Cheers, Vijay -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40226#40226 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Absolute beginner questions
ps: ALL_BUILD is a project part of the solution OpenSceneGraph.sln ! Mohamed ALJI -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40227#40227 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Absolute beginner questions
I am aware. However, when I do a build solution on ALL_BUILD, it still produces the same slew of errors. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40230#40230 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] Build OSG using DCMTK
Hi, I tried loading it like that, it generates a volume, and looks much better than before, but it still doesnt look right... It looks like most of the image is getting cut off..So i tried loading only 1 dicom file and it looks Like only the top 1/4th right hand corner of the image is getting rendered. I dont understand why this is happening, but i assume the only reason that the volume doesnt look proper is because of this.. Maybe the image is too large to be rendered... I dont understand this though.. could you explain to me, if this should be happening.. and is there a way to render the whole image properly? Also I was reading some other posts and they talk about a transfer function.. Does that make a difference in how the image is rendered?? Thank you soo much for all your help... I have attached a screenshot, in which osg is shown as rendering the top right portion of the mri scan only ... Thank you! Cheers, Isha -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40231#40231 Attachments: http://forum.openscenegraph.org//files/screenshot_102.png ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] Build OSG using DCMTK
Hi Isha, The image data still looks corrupted to me - the lines aren't normal, so I'd suspect this is part of the problem along with only part of the image being read. As to what the problem might be I can't answer. I would suspect an issue with DCMTK reading the image itself. I don't have your imagery so I can't test it out myself. Could you post a link to the data and a description of the command line options you are using? Robert. On Wed, Jun 8, 2011 at 6:46 PM, Isha Kandaswamy isha.kandasw...@gmail.com wrote: Hi, I tried loading it like that, it generates a volume, and looks much better than before, but it still doesnt look right... It looks like most of the image is getting cut off..So i tried loading only 1 dicom file and it looks Like only the top 1/4th right hand corner of the image is getting rendered. I dont understand why this is happening, but i assume the only reason that the volume doesnt look proper is because of this.. Maybe the image is too large to be rendered... I dont understand this though.. could you explain to me, if this should be happening.. and is there a way to render the whole image properly? Also I was reading some other posts and they talk about a transfer function.. Does that make a difference in how the image is rendered?? Thank you soo much for all your help... I have attached a screenshot, in which osg is shown as rendering the top right portion of the mri scan only ... Thank you! Cheers, Isha -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40231#40231 Attachments: http://forum.openscenegraph.org//files/screenshot_102.png ___ 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] Please test svn/trunk in prep for 2.9.16 dev release
Hi All, I'm planning to tag the 2.9.16 dev release tomorrow so would appreciate testing of svn/trunk. Please let me know of success or failure so I know how well things are shapping up for the release. Cheers, Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Shaders and Nvidia 275.33 drivers problem
Concur. They broke 3DVision (dual OC'd 250's) Transmitter lights up, flashes, then turns off. -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Tomlinson, Gordon Sent: Wednesday, June 08, 2011 5:28 AM To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] Shaders and Nvidia 275.33 drivers problem The 275.33 Drivers are not good I personally would avoid like the plague, they are causing all sorts of problems for people Gordon Tomlinson System Engineering Consultant Overwatch® An Operating Unit of Textron Systems __ WARNING: Documents that can be viewed, printed or retrieved from this E-Mail may contain technical data whose export is restricted by the Arms Export Control Act (Title 22, U.S.C., Sec 2751, et seq,) or the Export Administration Act of 1979, as amended, Title 50, U.S.C., App. 2401 et seq. and which may not be exported, released or disclosed to non-U.S. persons (i.e. persons who are not U.S. citizens or lawful permanent residents [green card holders]) inside or outside the United States, without first obtaining an export license. Violations of these export laws are subject to severe civil, criminal and administrative penalties. -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Alexander Sinditskiy Sent: Wednesday, June 08, 2011 5:04 AM To: osg-users@lists.openscenegraph.org Subject: [osg-users] Shaders and Nvidia 275.33 drivers problem Hello I have win7 x64 nvidia video card I found strange problem after update to version 275.33 of nvidia drivers. I see artifacts with shaders, i tried to find why. Part of shader uniform variables are not work correctly. i try to debug it with gdebugger and i noticed non-initialized values in part of uniforms. file src/osg/Program.cpp lines 672-673 Code: _extensions-glGetActiveUniform( _glProgramHandle, i, maxLen, 0, size, type, name ); Later i found that names of array variables coming with [0]. example - %name%[0] i tested with 266.58 they coming without [0] as result in _uniformInfoMap[Uniform::getNameID(reinterpret_castconst char*(name))] = ... we recording values with [0]. file src/osg/Program.cpp lines 213 Code: inline void apply(const Uniform uniform) const { GLint location = getUniformLocation(uniform.getNameID()); if (location=0) and here we can't get right location i fix it, please look patch Code: --- a/OpenSceneGraph/src/osg/Uniform.cpp +++ b/OpenSceneGraph/src/osg/Uniform.cpp @@ -611,13 +611,13 @@ unsigned int Uniform::getNameID(const std::string name) static UniformNameIDMap s_uniformNameIDMap; OpenThreads::ScopedLockOpenThreads::Mutex lock(s_mutex_uniformNameIDMap); -UniformNameIDMap::iterator it = s_uniformNameIDMap.find(name); +UniformNameIDMap::iterator it = s_uniformNameIDMap.find(name.substr(0, name.find([))); if (it != s_uniformNameIDMap.end()) { return it-second; } unsigned int id = s_uniformNameIDMap.size(); -s_uniformNameIDMap.insert(UniformNameIDMap::value_type(name, id)); +s_uniformNameIDMap.insert(UniformNameIDMap::value_type(name.substr(0, name.find([)), id)); return id; } But i don't think that is a good solution. Thank you! Cheers, Alexander -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40201#40201 ___ 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 mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] OSG based aplication nominated in CG Architect Awards
Hello people! Lot of time without writing anything here. Anyway I've been using a lot OSG in almost all my projects. I just one to tell you that one of them have just been nominated in the CG Architect Awards 2011, for Best Real-Time Application, and is completely based on OpenSceneGraph. It's called Spatial, volumetric and sectional analysis of the Cathedral of Santiago de Compostela. http://3dawards.cgarchitect.com/nominees/view/realtime/1099 So never is late to thank the community, because without you this projects are not possible. -- *Alberto Jaspe* *Computer Graphics RD Guy* http://albertojaspe.net ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] Build OSG using DCMTK
Hi, I run it using osgvolume dir of dcm files as you suggested... this is the link to the dcm data https://jshare.johnshopkins.edu/pkazanz1/Skull-2mm.zip I dont seem to understand when i render only one of the files, how it looks right, except that it looks like a part of that image... but the whole volume looks wrong... Thank you soo much for helping me out. ... Thank you! Cheers, Isha -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=40236#40236 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Please test svn/trunk in prep for 2.9.16 dev release
The latest source builds successfully with everything possible enabled on Ubuntu Natty x64. On Wed, Jun 8, 2011 at 1:26 PM, Robert Osfield robert.osfi...@gmail.comwrote: Hi All, I'm planning to tag the 2.9.16 dev release tomorrow so would appreciate testing of svn/trunk. Please let me know of success or failure so I know how well things are shapping up for the release. Cheers, Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- Ryan Pavlik HCI Graduate Student Virtual Reality Applications Center Iowa State University rpav...@iastate.edu http://academic.cleardefinition.com ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] 2.8.5 release tag
The first thing to do is update the wiki, and generate the official zip distribution. I have made a zip file by exporting the subversion tag given, and I can upload it somewhere if that would help. I'm in the process of creating rpm files for use on Fedora 14, x86_64. I will also soon make rpm files for Centos 5, which should also work with Red Hat Enterprise Linux. I'd be willing to help edit the wiki but alas I have forgotten (again) how to get access. Eric On Mon, Jun 6, 2011 at 9:14 PM, Paul Martz pma...@skew-matrix.com wrote: Hi all -- OSG 2.8.5 is now released. The official svn tag is: http://www.openscenegraph.org/svn/osg/OpenSceneGraph/tags/OpenSceneGraph-2.8.5 Will need to get info on the wiki about this shortly. Thanks to everyone who pitched in to help test this release! Fingers crossed, we didn't introduce too many issues with our changes. -- -Paul Martz Skew Matrix Software http://www.skew-matrix.com/ ___ 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] 2.8.5 release tag
Thanks, Robert -- I just tried to log in to the wiki so that I could get the wiki markup source for the 2.8.4 press release to use as a template: http://www.openscenegraph.org/projects/osg/wiki/News/Press/OSG2.8.4 However, I got an error when I tried to log in to the wiki: Trac detected an internal error: OperationalError: database is locked If you could resolve this issue and/or send me the wiki markup source, then I'll write up the announcement and post it. -Paul On 6/6/2011 11:55 PM, Robert Osfield wrote: Hi Paul, On Tue, Jun 7, 2011 at 2:14 AM, Paul Martzpma...@skew-matrix.com wrote: Hi all -- OSG 2.8.5 is now released. The official svn tag is: http://www.openscenegraph.org/svn/osg/OpenSceneGraph/tags/OpenSceneGraph-2.8.5 Will need to get info on the wiki about this shortly. Thanks to everyone who pitched in to help test this release! Fingers crossed, we didn't introduce too many issues with our changes. Congratulations on another stable release ;-) Let me know what and when you want me to update the website and blog about the release. I can do it right away but you might want binaries put together, let me know what you want me to do. Cheers, Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- -Paul Martz Skew Matrix Software http://www.skew-matrix.com/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] 2.8.5 release tag
On 6/8/2011 2:18 PM, Eric Sokolowsky wrote: The first thing to do is update the wiki, and generate the official zip distribution. I have made a zip file by exporting the subversion tag given, and I can upload it somewhere if that would help. I'm in the process of creating rpm files for use on Fedora 14, x86_64. I will also soon make rpm files for Centos 5, which should also work with Red Hat Enterprise Linux. We'll have our usual three-platform builds available shortly as well. -- Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com http://www.alphapixel.com/ Digital Imaging. OpenGL. Scene Graphs. GIS. GPS. Training. Consulting. Contracting. There is no Truth. There is only Perception. To Perceive is to Exist. - Xen ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org