Archived

This topic is now archived and is closed to further replies.

How do you create solid spheres?

This topic is 5619 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Im triing to make a transparent solid sphere...but having little luck I have been triing to use gluSphere and make a for loop with the radi slowly decreasing...this is horribly inefficent..ohh yeah and it doesnt work is there a gl solid sphere? or any simple way to create one?

Share this post


Link to post
Share on other sites
In 3D rendering under OpenGL/DirectX/etc., there isn''t anything like a "solid sphere". There isn''t actually a "solid" anything; everything is just surfaces.

Why do you feel you need a solid sphere, rather than a hollow one?



Don''t listen to me. I''ve had too much coffee.

Share this post


Link to post
Share on other sites
Are you trying to make a translucent/transparent sphere that also distorts light? Much like a crystal ball? Then that is different from a solid sphere. As mentioned above, there is no such thing as solid in the sense that the sphere has insides.
But you can make the surface appear to reflect or distort light. Bump mapping might not be the thing, but I am sure it won''t be too hard to find some algorithms on distorting light. You might need to do some kind of cube reflection or something and then mess with the images you get, but perhaps someone else can help more on the topic than I can.

-------------------------
(Gorgeous graphics)+(beautiful sound effects)+(symphonic music)+(no gameplay) != Good game

Share this post


Link to post
Share on other sites
Ick thats what i was afraid of...


I wana make a partical engine that uses transparent solid spheres....

So that the middle of the sphere would be almost ''solid'', while the edges whould be nearly completely transparent...and it would become more solid as it goes towards the middle...

Got any sugestions on what to do? i really dont wana use 2d images on a quad or trianle.

thnx

Share this post


Link to post
Share on other sites
Well, why don''t you just use a texture and use the alpha channel to simulate the different density. BTW. that''s how particle systems are almost always made: textured tris...


Yesterday we still stood at the verge of the abyss,
today we''re a step onward!

Share this post


Link to post
Share on other sites
Still... if you really want 3d for some reason, just put a sphere in a sphere in a sphere and blend it. You could put more spheres if needed. Though really, a particle system wouldn''t work very well even with plain spheres floating around. The polycount would get out of control. Use textured tris/quads for the same effect. For what you want, I once just took a photoshop brush, clicked once, and used that texture to be my "sphere". Check out NeHe''s tut''s on the subject.

Alex Broadwin
A-Tronic Software & Design
-----
"if you fail in life, you were destined to fail. If you suceed in life, call me."
"The answer is out there."
"Please help, I''m using Windows!"

Share this post


Link to post
Share on other sites
quote:
Original post by Vaporisator
Well, why don''t you just use a texture and use the alpha channel to simulate the different density.


Thats is a good idea..but i wana have it be uniform from all angles...I guess im triing to create something beyond what i can do...guess ill use triangles

unless someone has some amazing idea

Share this post


Link to post
Share on other sites
You misunderstand. When they say "use tris" they mean to use triangles but for each frame you would rotate the trangles to face the camera/viewer. This way it *would* be uniform from all angles. This is how almost all particle engines work btw.

-Michael

Share this post


Link to post
Share on other sites
Search around for a tutorial on billboarding ... combined with alpha-textured quads (one for each particle), this will achieve the same effect as the nested translucent spheres at approximately one-poofteenth of the cost

[edit] everyone posted while i was typing

how can you possibly view it from two different angles at once?... different viewpoints require different transformations of the scene... you can't have two different transformations occurring at once ?!? ...if you are drawing the scene from a different angle (ie camera position) you simply apply a different transform before drawing the particles... trust me... go and muck around with billboarding

[edited by - Bad Monkey on July 24, 2002 8:22:58 PM]

Share this post


Link to post
Share on other sites