3d capabilities

Understanding the language, error messages, etc.

3d capabilities

Postby erico » Sun Mar 30, 2014 12:29 am

I was wondering if the processor power will be enough to render wire frame polygons.
It does seem to in my opinion.

So, maybe the standard shipping library could sport functions to deal those easier just as 2d to bitmaps?
Maybe an obj-> self format tool included?

Just some ideas.

I was thinking about the following results.
Attachments
Tst-02.jpg
Tst-02.jpg (39.34 KiB) Viewed 6805 times
Tst-01.jpg
Tst-01.jpg (31.47 KiB) Viewed 6805 times
User avatar
erico
 
Posts: 671
Joined: Thu Mar 27, 2014 9:29 pm
Location: Brazil

Re: 3d capabilities

Postby adekto » Sun Mar 30, 2014 1:32 am

there is a arduino library that has a spinning 3D box i am not sure how much more we can do beyond the 8 vertices and how the hole thing works with multiple objects (and also interact/collide)
anyway u can try this one out all u need is arduino, 2 resisters and a tv with component
tvout lib

also if the gamebuino cant do this i like to know why and see if the solution is in some sort of module to expand the calculations or something
User avatar
adekto
 
Posts: 448
Joined: Tue Feb 25, 2014 9:47 pm
Location: belgium

Re: 3d capabilities

Postby erico » Sun Mar 30, 2014 2:06 am

That 3d cube is going on really fast.

Else wise I really don´t know, I´m not a C++ coder neither an arduino user, can´t try by myself.
I´m just an artist with a BASIC coding capabilities. ;)

Maybe gamebuino can achieve wire frame greatly. Processor on the A500 was running half this speed.
I know there were a few girls to help him up, but here it´s dealing with 1bit image and a 84x48 resolution. It feels doable? ;)
User avatar
erico
 
Posts: 671
Joined: Thu Mar 27, 2014 9:29 pm
Location: Brazil

Re: 3d capabilities

Postby Myndale » Sun Mar 30, 2014 2:24 am

I can't see this being a problem. Monochrome wireframe engines were perfectly doable on a 4MHz PC with a 720x348 Hercules card. Here we have a 84x48 display with a 20MHz microcontroller running at around 8MIPS. Given that the "back buffer" so-to-speak is in SRAM you won't have any contention with the refresh circuitry so optimized assembly routines should be able to get pretty good results.

I was looking into the TV composite idea myself. The display is driven by the same SPI pins that are used to program Gamebuino so it's almost possible to make a TV-out cable that would work with all games and would plug into the ICSP header. I say "almost" because you'd also need to monitor the Command/Data pin, so you'd have to reroute that through the SPI headers or something which means games would have to be written specifically to support it. Still, it would be a small change to the library and for the $5 or so it would cost for a 328p chip, a crystal, 2 osc caps and 2 resistors you would be able to plug Gamebuino into a big-screen TV.
Myndale
 
Posts: 507
Joined: Sat Mar 01, 2014 1:25 am

Re: 3d capabilities

Postby erico » Sun Mar 30, 2014 3:44 am

Myndale wrote:...
so optimized assembly routines should be able to get pretty good results.
....


I recall to be able to experiment asm in the old coco II days.
I´m in hope it is a more art process then a code one these day, and I know this sounds subjective.
But don´t get me wrong, it would be a nice dive. ;)
User avatar
erico
 
Posts: 671
Joined: Thu Mar 27, 2014 9:29 pm
Location: Brazil

Re: 3d capabilities

Postby Myndale » Sun Mar 30, 2014 4:08 am

Some of the most hard-core assembly programming I ever did was for the Playstation 2 vector units. Two chips, one of which had access to the other's SIMD register file and each chip having both an integer pipe and a floating point pipe with a 4-cycle instruction pipeline. In other words, at every single point in your code there were 16 assembly instructions at various stages of execution operating simultaneously, and if you wanted to your code to be stall-free you had to know what every single one of those instructions was doing on that cycle.

Fortunately Arduino is less art and more engineering. One chip, a very predictable execution pipeline, no memory cache issue to worry about. Assembly programming on Gamebuino should be very straightforward compared to other platforms.
Myndale
 
Posts: 507
Joined: Sat Mar 01, 2014 1:25 am

Re: 3d capabilities

Postby Xadiant » Sun Mar 30, 2014 4:10 am

Without any optimizations, assembly or care about using sin, cos and tan functions Im achieving some pretty promising raycasting graphics. If I can make it just a bit more CPU efficient I should be able to have textured walls and essentially a dummed down Wolfenstein 3D soon.

It is very doable, but you really have to watch what your doing and don't do anything thats not absolutely necessary in your engine.
Xadiant
 
Posts: 14
Joined: Tue Mar 04, 2014 6:48 pm

Re: 3d capabilities

Postby erico » Sun Mar 30, 2014 4:23 am

Myndale wrote:... Assembly programming on Gamebuino should be very straightforward compared to other platforms.


That is one thing I wanted to know.
Super thanks for the in depth explanation. I´m into re-learning it. It helps a lot.

Xadiant wrote:Without any optimizations, assembly or care about using sin, cos and tan functions Im achieving some pretty promising raycasting graphics. If I can make it just a bit more CPU efficient I should be able to have textured walls and essentially a dummed down Wolfenstein 3D soon.


I was primarily thinking about simple wire frame objects.
... great to hear more is capable :)
User avatar
erico
 
Posts: 671
Joined: Thu Mar 27, 2014 9:29 pm
Location: Brazil

Re: 3d capabilities

Postby adekto » Sun Mar 30, 2014 1:37 pm

Myndale wrote:...

I was looking into the TV composite idea myself. The display is driven by the same SPI pins that are used to program Gamebuino so it's almost possible to make a TV-out cable that would work with all games and would plug into the ICSP header. I say "almost" because you'd also need to monitor the Command/Data pin, so you'd have to reroute that through the SPI headers or something which means games would have to be written specifically to support it. Still, it would be a small change to the library and for the $5 or so it would cost for a 328p chip, a crystal, 2 osc caps and 2 resistors you would be able to plug Gamebuino into a big-screen TV.


did u mean ur considering making a module? why have a ATmega328P? sude one o those attiny's not be enugh to handle?

on the 3D side im not so convinced we can make any games out of it elite looks complicated im not sure how the hole collision detection worked on it (im not from the uk or was alive in the 80s)
i do think ur idea of virtua racer just wont work out (img2)
User avatar
adekto
 
Posts: 448
Joined: Tue Feb 25, 2014 9:47 pm
Location: belgium

Re: 3d capabilities

Postby rodot » Sun Mar 30, 2014 1:39 pm

Wow, I didn't thought that Gamebuino could handle 3D graphics when I did it. I look forward seeing that!
User avatar
rodot
Site Admin
 
Posts: 1290
Joined: Mon Nov 19, 2012 11:54 pm
Location: France

Next

Return to Programming Questions

Who is online

Users browsing this forum: No registered users and 56 guests

cron