3d programming without opengl

N

nelson -

hi!
i want to build up a simple 3d interactive geometry application in
python. Since i want to run it without 3D acceleration (a scene will
be quite simple) I was wondering if there was a library in python that
allow me to build 3D graphic without the need to use OpenGL.... I
google but i can't find nothing interesting... (the best would be a
pure python solution)

Thanks,
nelson
 
P

Paul McGuire

nelson - said:
hi!
i want to build up a simple 3d interactive geometry application in
python. Since i want to run it without 3D acceleration (a scene will
be quite simple) I was wondering if there was a library in python that
allow me to build 3D graphic without the need to use OpenGL.... I
google but i can't find nothing interesting... (the best would be a
pure python solution)

Thanks,
nelson

Here's a page (http://www.vrplumber.com/py3d.py) with links to 73 possible
libraries.

I've played with Slut (http://slut.sourceforge.net/) and it is quite easy to
work with. Here's a Flash movie (recorded using Wink) of a sphere that I
programmed and rotated about:
http://www.geocities.com/ptmcg/python/sphere1.htm, and here is the program
that created it: http://www.geocities.com/ptmcg/python/vecSlut2.py.txt.

The demos that come with Slut are quite impressive, too. The Slut project
web page summarizes them here
(http://slut.sourceforge.net/examples/index.html), but the little videos
don't do them justice.

-- Paul
 
P

Paul McGuire

Paul McGuire said:
Here's a page (http://www.vrplumber.com/py3d.py) with links to 73 possible
libraries.

I've played with Slut (http://slut.sourceforge.net/) and it is quite easy
to work with. Here's a Flash movie (recorded using Wink) of a sphere that
I programmed and rotated about:
http://www.geocities.com/ptmcg/python/sphere1.htm, and here is the program
that created it: http://www.geocities.com/ptmcg/python/vecSlut2.py.txt.

The demos that come with Slut are quite impressive, too. The Slut project
web page summarizes them here
(http://slut.sourceforge.net/examples/index.html), but the little videos
don't do them justice.

-- Paul
Well, shoot, I killed my free bandwidth on GeoCities with that link to the
Flash animation!

I've uploaded a smaller video, should support 20-25 views/hour, instead of 3
like the old one. Please bear with me.

Thanks,
-- Paul
 
S

Steve Holden

Paul said:
Here's a page (http://www.vrplumber.com/py3d.py) with links to 73 possible
libraries.

I've played with Slut (http://slut.sourceforge.net/) and it is quite easy to
work with. Here's a Flash movie (recorded using Wink) of a sphere that I
programmed and rotated about:
http://www.geocities.com/ptmcg/python/sphere1.htm, and here is the program
that created it: http://www.geocities.com/ptmcg/python/vecSlut2.py.txt.

The demos that come with Slut are quite impressive, too. The Slut project
web page summarizes them here
(http://slut.sourceforge.net/examples/index.html), but the little videos
don't do them justice.
Looks like c.l.py just slashdotted you ... """The GeoCities web site you
were trying to view has temporarily exceeded its data transfer limit.
Please try again later."""

regards
Steve
 
N

nelson -

Hi paul,
i look at slut and it seem very good... Can i embed it into a
wxpython application?

thanks,
nelson
 
P

Paul McGuire

Steve Holden said:
Looks like c.l.py just slashdotted you ... """The GeoCities web site you
were trying to view has temporarily exceeded its data transfer limit.
Please try again later."""

regards
Steve
--
Steve Holden +44 150 684 7255 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://holdenweb.blogspot.com
Recent Ramblings http://del.icio.us/steve.holden

It didn't take long either! I replaced the 1.4M .swf file with a 170K .swf
file, so things seem to be working again. (My b/w limit is 4.2M/hour, but I
can't complain when it's free!)

-- Paul
 
P

Paul McGuire

nelson - said:
Hi paul,
i look at slut and it seem very good... Can i embed it into a
wxpython application?

thanks,
nelson

I've no earthly idea, nelson, sorry. The sphere program is the extent of my
slut experience (for which my wife is quite grateful!). I think the slut
website mentions a mailing list, that should be able to answer your
technical questions.

Good luck!
-- Paul
 
S

Stephen Eilert

nelson said:
hi!
i want to build up a simple 3d interactive geometry application in
python. Since i want to run it without 3D acceleration (a scene will
be quite simple) I was wondering if there was a library in python that
allow me to build 3D graphic without the need to use OpenGL.... I
google but i can't find nothing interesting... (the best would be a
pure python solution)

Thanks,
nelson

I have no idea why you would want to do that. The fact that the scene
is simple shouldn't be the only reason. After all, if a user is able to
run the latest <insert_game_or_modelling_package_here> but your simple
scene runs much slower, he is going to assume there is something wrong
with it.

If the target user has even a simple 3D accelerator, you are taking a
huge performance hit. That shouldn't be done without a good reason.
What's more, giving it is should be a pure Python solution, you won't
even take advantage of MMX/SSE/3d now!, which all recent processors
have. I'm avoiding talking about raw Python performance here.

I did that once, so that I could learn how to make a software renderer,
but that's not your case, since it is a library you are looking for.
Perhaps there are other requirements that require what you are asking
for, but I can't see in your message.


Stephen
 
G

Grant Edwards

i want to build up a simple 3d interactive geometry application in
python. Since i want to run it without 3D acceleration (a scene will
be quite simple)

If you just want slow, it's probably easier to use OpenGL and
just put calls to time.sleep() in strategic places.
I was wondering if there was a library in python that allow me
to build 3D graphic without the need to use OpenGL.... I
google but i can't find nothing interesting... (the best would
be a pure python solution)

Oy. A pure Python solution would probably be _really_ slow.
 
F

Fredrik Lundh

Grant said:
Oy. A pure Python solution would probably be _really_ slow.

Pure Python doesn't necessarily imply "no graphics drawing code written
in some other language", though. You can get pretty far by using a 2D
library for simple 3D rendering.

</F>
 
R

Richard Jones

Fredrik said:
Pure Python doesn't necessarily imply "no graphics drawing code written
in some other language", though. You can get pretty far by using a 2D
library for simple 3D rendering.

Someone wrote a 3D demo for the pygame.draw challenge*. It worked but
unfortunately he didn't end up finishing and submitting it. It had severe
performance limitations :)


Richard

*: http://media.pyweek.org/static/pygame.draw-0606.html
 
R

Richard Jones

Fredrik said:
someone just posted this to reddit:

http://www.uselesspickles.com/triangles/demo.html

which I'd say qualifies as simple 3D with pretty decent performance
given what it does and what platform it runs on...

OK, that's a pretty cool demo :)

My definition of "severe" would involve a slow-down if you tried to render
several of those relatively simple objects :)

On my Althon64 3500+ system running in Konqueror or Mozilla I can get four
windows viewing that page before performance really starts to drag.

I should convince Alex to dig up that old code - I always was curious to see
it. Hmm.


Richard
 
W

Will McGugan

nelson said:
hi!
i want to build up a simple 3d interactive geometry application in
python. Since i want to run it without 3D acceleration (a scene will
be quite simple) I was wondering if there was a library in python that
allow me to build 3D graphic without the need to use OpenGL.... I
google but i can't find nothing interesting... (the best would be a
pure python solution)

If you are worried about running your 3d app on older machines, OpenGL
will typically fall back to software rendering if the hardware isn't
available. Although you would have to be running it on an ancient PC if
that is an issue.

If you really want to avoid OpenGL, then writing a custom 3D engine
using flat shaded polys, with painters algorithm, rendered with your
favourite gui toolkit isn't a great deal of work.


Will McGugan
 
G

Grant Edwards

If you are worried about running your 3d app on older
machines, OpenGL will typically fall back to software
rendering if the hardware isn't available.

That's true. OpenGL (which will do SW rendering) will
certainly be available on most/all Linux machines (except for
headless or text-only servers).
Although you would have to be running it on an ancient PC if
that is an issue.

Not true. None of my machines have hardware 3D acceleration.
One is only 9 months old, the others are 2-3 years old.
However, OpenGL's software rendering works fine and has
sufficient performance for most things short of 3D video games.
 
J

Jordan

I don't thnk you should have any problems using Slut with wxpython - wx
would be much less amazing if it couldn't do something like that. On
the other hand, I thought that you were looking for something that
doesn't use openGL and I think that Slut is built around it.

Cheers,
Jordan
 
P

Paul McGuire

On
the other hand, I thought that you were looking for something that
doesn't use openGL and I think that Slut is built around it.

Yes, slut *does* use OpenGL, so if that is in fact a poison pill for this
app, it's a no-go. The only reason I posted my original pointer to is was
to show that an OpenGL app doesn't require using a complicated API.

-- Paul
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top