Page 1 of 1

Idea for 3D on elec /BBC... Am I mad?

Posted: Tue Jul 19, 2016 12:57 am
by Stonemonkey
Hi all, first off I'll say I realise this is a big ask so I don't know if anyone will be interested, particularly as I don't know how well this could really work or if anyone here would really be interested in attempting such a thing.

My first computer was an electron when I was about 10 and I got into programming it straight away, mostly basic but I picked up a bit of assembly too. I dabbled with some 3D and had some slow wireframe shapes spinning around but I always wanted to create some sort of 3D maze to move through. I did buy one maze game for it but you had to wait a while as it drew each frame and you could only turn right angles or forward a block at a time.
Years later I have done a fair bit of graphics programming on PC and came up with a way of drawing something looking similar to raycasting vertical walls from a 2D map but done a very different way and I've always thought it might just be possible to get it running on an electron or BBC at a reasonable speed. I did make an attempt a few years ago on an emulator but got a bit lost with it and I've not got the code any more.
So, would anyone here have any interest in working or helping in such a thing? Or am I just crazy in wondering if it could be done?

Cheers, sm

Re: Idea for 3D on elec /BBC... Am I mad?

Posted: Tue Jul 19, 2016 5:34 am
by White Flame
There's been plenty of Wolfenstein 3D style graphics from the demoscene on 6502-based home computers. There's certainly nothing preventing such renderers from existing, just tradeoffs as to how fast you want it to run.

Re: Idea for 3D on elec /BBC... Am I mad?

Posted: Tue Jul 19, 2016 6:28 am
by Stonemonkey
I'll have a look, any links or what to search for? Any that would have run on original electron or BBC hardware?

Re: Idea for 3D on elec /BBC... Am I mad?

Posted: Tue Jul 19, 2016 7:10 am
by White Flame
I'm a Commodore 64 guy, so here's a few examples from it. (1MHz, and a non-linear framebuffer with 8x8 pixel palette cells)

https://youtu.be/ZQZOvsIHLT0?t=364
https://www.youtube.com/watch?v=X3Oqz5WjDPI

and one on the Atari, which I believe is ~2MHz and has a linear framebuffer:

https://youtu.be/ZQZOvsIHLT0?t=364

Re: Idea for 3D on elec /BBC... Am I mad?

Posted: Tue Jul 19, 2016 11:59 am
by Stonemonkey
Very cool thanks. Are there any articles on how they're done?
I wasn't thinking of texturing, only solid or checked pixels. A big difference though would be that walls could be positioned anywhere at angles and any length.

Re: Idea for 3D on elec /BBC... Am I mad?

Posted: Thu Jul 21, 2016 12:10 am
by resman
Here is raycasting on Apple II lores, 40x48 16 colors:
https://www.youtube.com/watch?v=QUN5CSWiLaw

About 20-25 FPS

Re: Idea for 3D on elec /BBC... Am I mad?

Posted: Thu Jul 21, 2016 2:05 am
by teamtempest
There's also a game called Wayout, from 1982. YouTube has a video of the Apple II version, also available for Atari and C64:

https://www.youtube.com/watch?v=frFvZwa_5bo