H3D.org Forum Index Programming Issues
Problem with cylinder | Register To Post |
| Threaded | Newest First | Previous Topic | Next Topic | Bottom |
| Poster | Thread |
|---|---|
| Anisha | Posted on: 2009/6/10 22:43 |
Just popping in ![]() ![]() Joined: 2009/6/10 From: Posts: 5 |
Problem with cylinder Hi. I am new to using H3D, so thanks in advance for being patient with me. I was attempting to use H3D interfaced with a Falcon device to interact with a scene I created using Python. I created a hollow cylinder and was attempting to move my stylus inside the cylinder, but H3D has inserted haptic triangles into the cylinder so that my stylus's range of motion inside the cylinder is limited to compartments of the cylinder sectioned off by the triangles. I have figured out how to make the triangles visible by selecting the "draw haptic triangles" box under the "Debug" tab under Settings, but I do not know how to make the triangles disappear. How do I eliminate these triangles so that I can move my stylus freely inside the hollow cylinder. Thanks in advance for any replies.
|
| Markus | Posted on: 2009/6/15 8:36 |
Webmaster ![]() ![]() Joined: 2006/3/27 From: SenseGraphics Posts: 1900 |
Re: Problem with cylinder If I understand correctly there are triangles inside the cylinder in places where there should be none, i.e. where the graphics does not display any triangles.
If that is the case then I wonder, what is your graphics card? Is it an ATI card? I tested a simple cylinder withouth bottom cap and which was not solid on my system and had no problems. If I did not understand your example entirely correct please provide a small x3d file which gives you the problem so I can test it. |
| Anisha | Posted on: 2009/6/15 17:16 |
Just popping in ![]() ![]() Joined: 2009/6/10 From: Posts: 5 |
Re: Problem with cylinder Thanks for your reply. Yes, I believe you have assessed my situation correctly; there are triangles inside the cylinder where they should not be. Normally, these triangles are invisible, but I have figured out how to make them show up, as I stated in my last post. As you suspected, my computer does have an ATI card. Is this causing the problem? If not, then is there something wrong with my code? I have included the code I have been using below:
<Scene> <Group> <Transform rotation="1 0 0 1.57" translation = "0 0 -.07"> <Shape> <Appearance> <Material diffuseColor = "1 .4 .3"/><SmoothSurface/> </Appearance><Cylinder DEF="cylinder2" radius="0.08" height=".3" top="false" solid = "false"/> </Shape> </Transform> </Group> </Scene> Thanks again for your help. |
| Markus | Posted on: 2009/6/22 8:42 |
Webmaster ![]() ![]() Joined: 2006/3/27 From: SenseGraphics Posts: 1900 |
Re: Problem with cylinder Yes, it can be the ATI card and bad drivers for OpenGL that is causing the problem. H3DAPI uses the a feature of OpenGL which lets it collect triangles rendered on screen, for ATI card this sometimes gives problems because the ATI card creates triangles which are not there.
You could try to upgrade to the latest trunk version of H3DUtil/HAPI/H3DAPI to see if the problem goes away if you know how to check out trunk or is willing to follow wiki guide. I doubt that this would fix the problem though. Nothing is wrong with your code, it works fine on my system, with an NVIDIA card :). |
| agreen24 | Posted on: 2009/8/3 19:41 |
Quite a regular ![]() ![]() Joined: 2008/12/18 From: Posts: 21 |
Re: Problem with cylinder Hi,
I decided to add my problem here because I see that you were discussing graphics cards. I've been using code that works completely fine on one computer that has an nVidia card, but when I transferred it to a computer with an ATI card, it throws up an error saying "global name hdev is not defined," and when it hits the 'wall' (like it's supposed to, the Falcon starts bouncing around violently - I'll put up some of the code here (the relevant part anyway): python file (please ignore non-indentations, that happened when I pasted): Quote:
Please help! Thanks in Advance! AG |
| agreen24 | Posted on: 2009/8/4 17:46 |
Quite a regular ![]() ![]() Joined: 2008/12/18 From: Posts: 21 |
Re: Problem with cylinder I've already un/reinstalled H3D, and the Falcon drivers, but no good. Any advice?
|
| Markus | Posted on: 2009/8/7 8:50 |
Webmaster ![]() ![]() Joined: 2006/3/27 From: SenseGraphics Posts: 1900 |
Re: Problem with cylinder Seems strange that you would get an error about HDEV for computers with different graphics cards. I guess there are more differences. Is the H3DAPI version the same on both?
Is the wall a geometry? In that case, is it an IndexedTriangleSet or some pre-defined geometry? Are there many triangles? For very few triangles I have not noticed a difference between ATI and NVIDIA. At least not with IndexedTriangleSet. |
| Markus | Posted on: 2009/8/7 8:50 |
Webmaster ![]() ![]() Joined: 2006/3/27 From: SenseGraphics Posts: 1900 |
Re: Problem with cylinder Seems strange that you would get an error about HDEV for computers with different graphics cards. I guess there are more differences. Is the H3DAPI version the same on both?
Is the wall a geometry? In that case, is it an IndexedTriangleSet or some pre-defined geometry? Are there many triangles? For very few triangles I have not noticed a difference between ATI and NVIDIA. At least not with IndexedTriangleSet. I have only noticed it with Cylinder. |
| agreen24 | Posted on: 2009/8/8 4:07 |
Quite a regular ![]() ![]() Joined: 2008/12/18 From: Posts: 21 |
Re: Problem with cylinder It isn't the different graphics card (because I replaced it with an nVidia), but it is something about the single computer. I tried running the program on a third computer, and I didn't get that error, though it did bounce around a little upon hitting the wall. I just don't know where the cause of the problem is, so I don't know what to do from here. Any ideas?...please...
AG |
| Markus | Posted on: 2009/8/12 9:20 |
Webmaster ![]() ![]() Joined: 2006/3/27 From: SenseGraphics Posts: 1900 |
Re: Problem with cylinder Do you get any other error message? Like if it tries to initialize some other device first and fails.
Did you select the falcon device through the H3DLoadSettings program or is the DeviceInfo part of the x3d-file (I am guessing the first one). Are you using the AnyDevice in the H3DLoadSettings? Regarding the bouncing: Which renderer are you using, it is the same bouncing for both GodObjectRender, RuspiniRenderer and Chai3DRenderer? |
| Threaded | Newest First | Previous Topic | Next Topic | Top |
| Register To Post | |




