Parametrized 3D object
-
- Posts: 18
- Joined: Wed Feb 27, 2008 2:32 pm
- Location: Russia, Moscow
Parametrized 3D object
How correctly create parametrzied 3D object in Irrlicht, for example parallelepiped with properties Width, Lenght, Height, that can be changed from code and 3D model chenges accordingly.
-
- Posts: 18
- Joined: Wed Feb 27, 2008 2:32 pm
- Location: Russia, Moscow
No, scale is not what i need
I have more complex object than pipe, and i want to know, how can i control modification of object in Irrlicht. I think that Custom Scene Node (Tutorial 3) is what i need, but may be there is easer way to control 3D model...
In other words ...
how can i change internal pipe size or pipe wall thickness... I think must be a way to create object "Pipe" with this properties and somehow connect it to 3D medel... Scale is wrong way i think...
[/img]
I have more complex object than pipe, and i want to know, how can i control modification of object in Irrlicht. I think that Custom Scene Node (Tutorial 3) is what i need, but may be there is easer way to control 3D model...
In other words ...
how can i change internal pipe size or pipe wall thickness... I think must be a way to create object "Pipe" with this properties and somehow connect it to 3D medel... Scale is wrong way i think...
[/img]
-
- Posts: 18
- Joined: Wed Feb 27, 2008 2:32 pm
- Location: Russia, Moscow
Ok so you want to be able to control things like the thickness of the pipe's 'walls' right?
Yeah sounds more complicated than scaling....
I'm not sure how you'd go about doing it, i guess you'd need to have each seperate part of the model that you'd want to affect in a different mesh buffer and then scale the individual mesh buffers to get that effect....
Yeah sounds more complicated than scaling....
I'm not sure how you'd go about doing it, i guess you'd need to have each seperate part of the model that you'd want to affect in a different mesh buffer and then scale the individual mesh buffers to get that effect....
-
- Posts: 18
- Joined: Wed Feb 27, 2008 2:32 pm
- Location: Russia, Moscow
I'm not particularly sure what MDX is, seems to be a more easily usable version of DX right? So i guess in a way it's like irrlicht in the way that irrlicht abstracts away from DX and OGL calls.
But i would imagine that irrlicht would probably still be the easier of the two to use, though i've not used MDX so can't accurately comment on it!
But i would imagine that irrlicht would probably still be the easier of the two to use, though i've not used MDX so can't accurately comment on it!
-
- Posts: 18
- Joined: Wed Feb 27, 2008 2:32 pm
- Location: Russia, Moscow
Irrlicht is very usefull for game developement, but for CAD i can't find any tutorials, examples or ready projects... I continue search for Irrlicht advantages in CAD developement
P.S. Managed DX is DX with very convinient API, fully integrated with .NET (and I'm .NET developer)... It also has cameras like Irrlicht and it works with 3D models and so on...
P.S. Managed DX is DX with very convinient API, fully integrated with .NET (and I'm .NET developer)... It also has cameras like Irrlicht and it works with 3D models and so on...
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
You won't need a custom scene node if you just want to use custom meshes. Then it's enough to create an SMesh manually, fill the meshbuffers, and add it to a mesh scene node. When you want to change the mesh you simple getMesh() it and access the meshbuffers.
Custom scene node is necessary for special render techniques, or when custom meshes have to be serialized (see the Sphere scene node)
Custom scene node is necessary for special render techniques, or when custom meshes have to be serialized (see the Sphere scene node)
-
- Posts: 18
- Joined: Wed Feb 27, 2008 2:32 pm
- Location: Russia, Moscow
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
You should check the CGeometryCreator for this. It contains the sphere generation method, which does a pretty similar job. The basics are to create an SMesh and an SMeshBuffer, add the buffer to the mesh and fill it with S3DVertex elements. Then you'll also need indices to choose the vertices which define a face of the mesh. Finally set up the material and recalculate the bounding boxes.