So I was wondering how would you go about making a 3D object with the Line() command, I was hoping to work on some concept designs for models on the MC Mod/Add-on "expansion" I was working on at school on-calc, but I seem to bee hitting an issue with the X,Y,Z opposed to the X,Y that it supports, along with needing 12 Line() commands with coordinates stored to a list. Any thoughts on this?
Have you looked at:

:: http://en.wikipedia.org/wiki/Isometric_projection
:: http://en.wikipedia.org/wiki/Perspective_projection

Those are the two major types of 3D that are used in computer graphics; the former is far, far easier than the latter. Take a look at the pages, see if you can understand them, and then I'll explain more.
KermMartian wrote:
Have you looked at:

:: http://en.wikipedia.org/wiki/Isometric_projection
:: http://en.wikipedia.org/wiki/Perspective_projection

Those are the two major types of 3D that are used in computer graphics; the former is far, far easier than the latter. Take a look at the pages, see if you can understand them, and then I'll explain more.


I will look at those when I get a chance, as when I get home I am working on a project with a couple friends, but as soon as I do get a chance, I will take a look at them.
Very good. Isometric translation is surprisingly easy; take a look at Design 3D by myself (and later, Frode van der Meeren as well) for a good example:

http://www.ticalc.org/archives/files/fileinfo/399/39916.html
KermMartian wrote:
Very good. Isometric translation is surprisingly easy; take a look at Design 3D by myself (and later, Frode van der Meeren as well) for a good example:

http://www.ticalc.org/archives/files/fileinfo/399/39916.html


Can that program support multiple (up to and over 50 lines for example)? If so I could just use that for now.
Yes, it can support up to 999 lines, if I recall correctly.
KermMartian wrote:
Yes, it can support up to 999 lines, if I recall correctly.


Nice, I think I will get that when I get home and see what I can do with it.
Or for those of us who may be lazy (*cough* me *cough*), here is just the code for rendering. This helped me a lot Smile

http://www.ticalc.org/archives/files/fileinfo/228/22809.html
_player1537 wrote:
Or for those of us who may be lazy (*cough* me *cough*), here is just the code for rendering. This helped me a lot Smile

http://www.ticalc.org/archives/files/fileinfo/228/22809.html
Thanks tanner! Yup, that's the simple raw rendering engine.
3D is scary stuff. As far as I'm concerned, an OpenGL wizard poofs it all onto my screen. o.o

If you've taken geometry, you can do iso projections. Perspective is trig and nonreal math and uuugh. I couldn't imagine doing it in C, much less Asm.

Good luck, though. Keep us updated, I'd like to see it.

---

Just had a thought. Render X and Y like normal but render Z two right and one up per Z unit from (X, Y). That will probably work to crate the illusion of depth, but only from one angle. You can try playing around with finding the Z axis given a certain angle. Have fun.
I've actually done this before. Here's the topic, including the full source code:
http://ourl.ca/4772
This program uses full perspective 3D on any object you want, and includes two sample objects.
SirCmpwn wrote:
I've actually done this before. Here's the topic, including the full source code:
http://ourl.ca/4772
This program uses full perspective 3D on any object you want, and includes two sample objects.


I'm impressed. Seems like more of a math thing then a programming thing. How complex can the shapes be, SirCmpwn?
Ohhh, that's only wireframe perspective 3D, though. Smile I made a full perspective, hidden-line renderer for Brix3D, which sadly I never released.

Edit: Progbeard, the mathematical transforms to turn (X,Y,Z) coordinates into (X,Y) perspective coordinates are well-defined; you can transform any set of line endpoints.
Same as KermMartian, up to 999 lines. prgmRENDER does most of the heavy lifting, and it's pretty optimized. Still slow as hell, though.
And 999 lines would take unimaginably long to render.
KermMartian, I had considered adding textures, but it already took up 8-9 seconds to render a simple cube, and didn't want to take any longer.
SirCmpwn, not to mention that the algorithms to do polygon or triangle sorting are a massive pain to even do correctly, and I was synthesizing them from scratch.
Sonlen wrote:
So I was wondering how would you go about making a 3D object with the Line() command, I was hoping to work on some concept designs for models on the MC Mod/Add-on "expansion" I was working on at school on-calc, but I seem to bee hitting an issue with the X,Y,Z opposed to the X,Y that it supports, along with needing 12 Line() commands with coordinates stored to a list. Any thoughts on this?


Whatever you do, stay away from trig for projection.

This reminds me of my own BASIC CAD program:

KermMartian wrote:
SirCmpwn, not to mention that the algorithms to do polygon or triangle sorting are a massive pain to even do correctly, and I was synthesizing them from scratch.

Tell me about it x.x

Qwerty.55, that looks amazing!
Thanks, Sir. Unfortunately that project is entirely dead.
Ah, I use Isometric 3D in CAD all the time, it is relatively easy once you get the hang of it Smile (I assume it is the same for the calcs too)
It is indeed, Qazz. Smile Qwerty, why the trig caution, for speed or difficulty?
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement