Replies: 9 comments 11 replies
|
Hi, I've changed calculations from float to fixed point math and now raycasting calculation is few times faster. |
|
Changing from float to fixed point calculations along with optimized rectangle drawing gave quite an speed improvement. raycaster_20241108.mp4 |
|
Hi, I've managed to speed this up and added floor shading. raycaster_20241112.mp4 |
|
I've made some progress. Textures seems to work quite well. I'm also using whole 320x180 screen. Still a lot of work but I think I'm going forward. Now I have to add sprites. raycaster_20241206.mp4 |
|
I wonder if I can use some sprites along with normal bitmap graphics. Now I'm loading converted image as full screen asset like this: Video mode is set like this: Then I draw other stuff as normal pixels, lines etc. It would look much better if instead of simple drawing the compass needle using lines I could put sprite there and just rotate it. |
|
I've made some improvements to the raycaster code. It faster now so I can render it with higher resolution when moving. raycaster_20260122.mp4 |
|
Thanks for the info and link to to the discord 👍 |
|
Sprites time! raycaster_20260205.mp4 |
|
I've added floor/ceiling textures and changed theme. There is also map scan, too. raycaster_20260214.mp4 |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi,
I've tried to write simple raycaster. It kinda works, but it's really slow.
Part of this is due to drawing filled rects which you can see when screen is updating.
I know that using floats for calculations is bad idea for 6502.
I've tried to replace some of those operations with integer math with scaling. It's little bit faster but gives me some errors so I've left floating math version for now.
Code is available here: https://github.com/grakoczy/RP6502-raycasting-llvm-mos
Maybe someone with more skills will be able to make it run faster?
Anyway it's a lot of fun writing programs for this little machine :)
raycaster.mp4
All reactions