3D Graphics coding

3D Graphics coding

Postby Pyrofer » Tue Oct 03, 2006 2:50 pm

Hi, id love to get some discussion going here about the use of 3D maths and graphics in C without all those fancy hardware accelerators and Direct X api things.

I wrote my whole system from scratch including the plot pixel command!
Pyrofer
 
Posts: 139
Joined: Tue Sep 26, 2006 11:06 pm

Postby MotoHacker » Mon Mar 12, 2007 11:06 pm

I think,not to many people have this knowledge in this days..
Btw,I remember,in the happy 90's many demo and other stuff used pure CPU power,produce amazing 3D.
Guys was coded effects in assembly,the king was,who created high resolution 3D in realtime.
MotoHacker
 
Posts: 4
Joined: Mon Mar 12, 2007 9:11 pm

The lcdline() function

Postby raapeland » Thu May 03, 2007 6:37 am

Looking at the lcdline() function in the source code provided here:
http://www.pyrofersprojects.com/code/3dcube.txt

It appears to me that the LCD helps you a great deal with line drawing, since you only output a command, the coordinates of the line end points and the colour in order to draw a line. Am I wrong? If not, does the LCD help you with polygon filling as well?

-Rein
raapeland
 
Posts: 1
Joined: Thu May 03, 2007 6:30 am

Postby Pyrofer » Thu May 03, 2007 8:54 am

Yes, the original LCD took basic commands such as line and plot.
That LCD used a serial interface and was too slow as it had no polygon command, so I would have to either plot or line loads for each poly.

I moved up to the Nokia LCD after that with a faster SPI interface, that had NO commands at all. Everything in my GFX routine was hand written to change the LCD memory buffer directly.
I wrote my own plot, line and poly commands, this source has not yet been published on the site.

I have another 2 displays to try. Both OLED. I have an updated OLED of the first display that has serial control, but a built in poly command and I have an updated OLED for the second display that has only direct memory access again, but a parallel interface not serial. I havent had time to try out either of these yet.

I published that source code mainly because everybody will use different hardware, but that shows the 3D stuff without loads of complex LCD control stuff.

So to sum up, all the Solid 3D stuff you see is driven by my own handwritten poly command that access's the LCD ram buffer directly.
Most of the Vector stuff on the older screen just uses the LCD built in line command.
Pyrofer
 
Posts: 139
Joined: Tue Sep 26, 2006 11:06 pm

3D Vector objects in C using the PIC micro

Postby cbrauner » Wed Aug 22, 2007 2:05 pm

i read your article about '3D Vector objects in C using the PIC micro'

i successfully tested the code on a atmega128 and a siemens s65 display / i can rotate the cube (x,y,z)

is there a way to get the new source code with triangles (polygons) and solid surfaces to learn more about 3d objects ?


thx and greetings from vienna
cbrauner
 
Posts: 1
Joined: Wed Aug 22, 2007 2:03 pm

Re: 3D Graphics source

Postby Texada » Wed Apr 08, 2009 3:02 am

Hi Pyrofer,

I enjoyed reading about your 3D graphics adventures with the pic. I especially liked the source code you made available and was wondering if you would consider making other sources available as well - polygon fill, backface culling etc.

Thank you very much.
Texada
Texada
 
Posts: 1
Joined: Wed Apr 08, 2009 2:57 am


Return to Software

Who is online

Users browsing this forum: No registered users and 1 guest

cron