Author Topic: [Lua] Make3D  (Read 41148 times)

0 Members and 3 Guests are viewing this topic.

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
[Lua] Make3D
« on: April 21, 2011, 10:20:22 pm »
Hello everyone !
Well, I will present you a little bit this projet I maintain since .. yes ... this is it ... 2.5 years in TI-Basic !
I named it : Make3D.
Original topic in french :
http://tibank.forumactif.com/t4072-wip-make3d-pour-nspire-cas

First it was only a 3D viewer. In France, during HighSchool, we have to make a projet named "TPE" we can translate to "Supervised Practical Work". The goal is to do a presentation of at least 40 pages and an oral lecture of 15 minutes by groups of 2/3/4 during the whole year. My project was to study the subject "Modèles des Simulations 3D", translated to "3D Simulation Models" ('love english). Basicly we had to see how the virtual world was lead by 3D models and 3D simulations. Every days you're looking to an ad, and there is this beautiful car ... OH WAIT THIS IS 3D.... this was the general idea of the project :D

But, during our researches, the supervisor teacher (which one supervises our project) comes and said to us "Hum ... 'ur only using 3D software aren't you ? you only touch to theory ... this is a shame." The next day I went to school with my TI-Nspire and the first version of Make3D, typically a 3D point  rendering engine coded in TI-BASIC on TI-Nspire :D
http://img228.imageshack.us/img228/5349/make3dpg8.jpg
http://img119.imageshack.us/img119/216/suzanne2ta0.jpg

Kinda cool, our teacher and the examinators were just : O_o and we got 19.5/20   good job \o/

Nice ... so, here the little story of Make3D. Only a stub to answer to my teacher ...
This stub finished to make a tree, like a big tree I mean. We were able to display 3D functions, import models from Blender and make some 3D
geometry.
http://i60.servimg.com/u/f60/13/60/39/93/14-05-12.jpg
http://i60.servimg.com/u/f60/13/60/39/93/sqrt_s10.jpg
http://img10.imageshack.us/img10/8108/cran016.jpg
http://img413.imageshack.us/img413/1179/singe.jpg
http://img297.imageshack.us/img297/8758/cran003.jpg
http://i60.servimg.com/u/f60/13/60/39/93/30-05-10.jpg
http://i60.servimg.com/u/f60/13/60/39/93/01-06-12.jpg
http://img821.imageshack.us/img821/2576/joujouinter.gif

But ... of course... TI-BASIC is .... SLOW. We had to wait over than 5 seconds for a 10 points model, 30 for 50, 5 minutes for 100, etc ...
http://img27.imageshack.us/img27/3182/cran001.jpg

Then, Ndless comes. Hum ... I wanted to port Make3D in C... just lazy (many exams for the final year of HighSchool etc ...)

Then Lua comes.

OmyGAD  :o

Opportunity to make a real 3D engine ;D
http://i20.servimg.com/u/f20/13/60/39/93/acran010.jpg
http://levak.free.fr/ftp/nspire/Make3D/screens/make3D.gif


So now the goal is : make a program that could help anyone in the comprehension of 3D space whereas the built-in 3D function render DON'T display non-function models. This is the goal of Make3D. Make everything you want is 3D (like a cube, a sphere) you can't do with the built-in functions \o/

Thus, I have to develop a fully user-friendly interface and "SDK" to propose a software which HAVE to be easy to use AND powerfull.
http://education.ti.com/html/nspireplayer/3.0.1/application/index.html?locale=en&nspirefile=http://levak.free.fr/ftp/nspire/Make3D/Make3D.tns

Any suggestions are welcome =D
« Last Edit: September 14, 2011, 07:53:04 am by Levak »
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline mikehill2003

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 279
  • Rating: +13/-4
    • View Profile
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #1 on: April 21, 2011, 10:24:11 pm »
Wow...Nice!

Offline ruler501

  • Meep
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2475
  • Rating: +66/-9
  • Crazy Programmer
    • View Profile
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #2 on: April 21, 2011, 10:27:34 pm »
This is great. When do you expect to release a Lua version of this?
I currently don't do much, but I am a developer for a game you should totally try out called AssaultCube Reloaded download here https://assaultcuber.codeplex.com/
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCM/CS/M/S d- s++: a---- C++ UL++ P+ L++ E---- W++ N o? K- w-- o? !M V?
PS+ PE+ Y+ PGP++ t 5? X R tv-- b+++ DI+ D+ G++ e- h! !r y

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #3 on: April 21, 2011, 10:32:05 pm »
This is great. When do you expect to release a Lua version of this?
I thought I could release a TI-BASIC version of this many many time but I love to be perfect :D
So here is the link I will frequently update :
http://levak.free.fr/ftp/nspire/Make3D/Make3D.tns

And with the Nspire-player :
http://education.ti.com/html/nspireplayer/3.0.1/application/index.html?locale=en&nspirefile=http://levak.free.fr/ftp/nspire/Make3D/Make3D.tns
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline jnesselr

  • King Graphmastur
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2270
  • Rating: +81/-20
  • TAO == epic
    • View Profile
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #4 on: April 21, 2011, 10:55:55 pm »
This looks awesome!  Too bad I don't have a nspire.
« Last Edit: April 21, 2011, 10:56:06 pm by graphmastur »

Offline apcalc

  • The Game
  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1393
  • Rating: +120/-2
  • VGhlIEdhbWUh (Base 64 :))
    • View Profile
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #5 on: April 21, 2011, 10:59:41 pm »
This is truly amazing Levak! :)

Excellent work!


Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #6 on: April 22, 2011, 04:42:40 am »
Congratulations !

:)
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #7 on: April 22, 2011, 05:30:26 pm »
This is very cool. I remember seeing this a year ago on TI-BANK back when it was in BASIC. I already found it pretty cool. If the speed in Lua  is decent enough I wonder if it could be used to render some games like the Super Nintendo Star Fox game (I think it was called Star Wings in Europe due to trademark issues) or at least Space Dementia. Even if no game were possible it is still very great.
« Last Edit: April 22, 2011, 05:30:43 pm by DJ_O »

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #8 on: April 22, 2011, 08:18:57 pm »
Hum .. actually I've forgotten to say that I try to use Blender shortcuts and Basic functionnalities/modes

So here are the dots/wire/solid mode integration with a particularity : display point labels.



« Last Edit: April 22, 2011, 08:24:26 pm by Levak »
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #9 on: April 22, 2011, 08:43:23 pm »
That looks pretty good. Also I love how you support shades of gray. :D

On a side note I will move this to the calc projects and ideas section since this is still a project in the works.

By the way does the animated screenshot in the first post run at the real calculator speed?

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #10 on: April 23, 2011, 04:42:56 am »
By the way does the animated screenshot in the first post run at the real calculator speed?

No. In the animated gif, it is too slow. Oncalc it is faster \o/
Edit : Well, I guess it depends on the navigator you use. Personnally on Google Chrome the gif played is slow. OnCalc I can display up to 34 frames per second
« Last Edit: April 23, 2011, 04:44:48 am by Levak »
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #11 on: April 27, 2011, 06:57:12 pm »
Actually, I tried it on my calc yesterday and it was really great. The speed seemed a bit faster than the screenshot. I think in Chrome GIFs plays at 10 FPS max, so maybe that's why for you it seemed much slower.

Good job by the way! One thing I noticed, however, is that when zooming out too much, the cube seems kinda distorted. ???

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #12 on: April 27, 2011, 07:27:28 pm »
Good job by the way! One thing I noticed, however, is that when zooming out too much, the cube seems kinda distorted. ???

It is not "zoom" but focal lens. This lets you switch between orthographic and perspective view. As often said it is also the Zoffset.
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #13 on: April 27, 2011, 07:27:59 pm »
Oh ok, thanks for the info. :D

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: [TI-Nspire] Make3D - TI-Basic to Lua
« Reply #14 on: April 27, 2011, 07:53:36 pm »
Btw, for now I'm thinking about the GUI integration. To be the most flexible possible, I have to think about everything, and this is kinda long. So don't think I let the project dead because I don't do any updates, when an idea comes with me, it is never early :D
Basicly I have to be compatible with the handheld, with the software and with the nspire-player. For that, I have to make a GUI model which can be extensible (I love this word). Now that the core is finished (I think), I have to add all the user part, and this is a main point : Do I have to follow Blender concepts, or do I have to draw my own journey ? Make3D is mainly designed for educational purposes. Add a point, drag it in space, add another point, draw a line between those points. Do I have to solve the line equation ? (distinctions between CAS and nonCAS or really heavy calculous). Or this way : Add a cube, subdivide it, drag some points of the cube, erase and add faces ?

Everything of this is possible, it is just a fondamental question I have to answer : which way take ?

Inb4 : Your answer is "all of that without distinction" : dude, You **** :p
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua