42bs Posted August 16, 2022 Share Posted August 16, 2022 This is a small voxel flight prove of concept. I wanted to make it a demo for SV, but simply had no time. So here the current version. Numbers are: ms to render the screen, frames to render the screen and height of "flyer". Here a short "hand recorded" video: voxel.cof 23 Quote Link to comment Share on other sites More sharing options...
+Sauron Posted August 16, 2022 Share Posted August 16, 2022 Looks nice. I know there's been several voxel engines that have floated around here, including DrTypo's one that he uses in Fallen Angels. I'd like to see more experimenting with them, personally. 1 Quote Link to comment Share on other sites More sharing options...
sirlynxalot Posted August 17, 2022 Share Posted August 17, 2022 Looks great. Actually with those colors, it kinda reminds me of my local weather station circa 2000 showing off the temperature and weather in the area 😆 1 Quote Link to comment Share on other sites More sharing options...
philipj Posted August 17, 2022 Share Posted August 17, 2022 9 hours ago, Sauron said: Looks nice. I know there's been several voxel engines that have floated around here, including DrTypo's one that he uses in Fallen Angels. I'd like to see more experimenting with them, personally. I've always wanted to experiment with 3D splines, nerbs, and voxel for the Jag and combine the three... Voxels seems very cheap to shade very fast, can be used as sprites for very fast OP handling, and can be copied several times over in memory to fill a screen line very fast with emphasis on volumetrics instead of the slow process of drawing quads or triangles for 3D... all there's needed is a good strong spline and nerb based realtime 3D engine with the Motorola having better access main memory and cartridge for solid real 3D representation handling fast wireframe while the Jaguar do what it does best; handle 2D images efficiently... at least in theory, but all of that theory is a curiosity at this point with nothing to back everything I said. 2 Quote Link to comment Share on other sites More sharing options...
42bs Posted August 17, 2022 Author Share Posted August 17, 2022 The 'problem' with the voxels (btw same for raycaster like Doom or Wolfenstein) you cross a lot of DRAM page boundaries as screen memory is from left to right not up to down. I will have to try and rotate my screen by 90° and draw lines instead of columns. My bet, at least 50% quicker. 1 1 Quote Link to comment Share on other sites More sharing options...
+CyranoJ Posted August 17, 2022 Share Posted August 17, 2022 3 minutes ago, 42bs said: The 'problem' with the voxels (btw same for raycaster like Doom or Wolfenstein) you cross a lot of DRAM page boundaries as screen memory is from left to right not up to down. I will have to try and rotate my screen by 90° and draw lines instead of columns. My bet, at least 50% quicker. What about vertical object strips arranged horizontally? 1 Quote Link to comment Share on other sites More sharing options...
42bs Posted August 17, 2022 Author Share Posted August 17, 2022 (edited) 25 minutes ago, CyranoJ said: What about vertical object strips arranged horizontally? Not sure what you mean. The "classical" voxel engine draws for each X vertical stripes where the height is determined by the map scanned in Z direction. I am not using the painter algo, so it draws only a new column if it is "higher" than the one in front. So if I wanted to draw horizontally, I need to know the colors for each pixel. One optimization could be to prepare the vertical stripe in GPU RAM and then draw it completely. If only GPU RAM could be accessed 8 or 16 bit wise Edited August 17, 2022 by 42bs Quote Link to comment Share on other sites More sharing options...
+CyranoJ Posted August 17, 2022 Share Posted August 17, 2022 I mean if you have single/double pixel wide objects 2x200 arranged horizontally so at 0,2,4,6 etc that way your vertical 'stripe' is 'horizontal' (sequential) in RAM. 1 Quote Link to comment Share on other sites More sharing options...
42bs Posted August 17, 2022 Author Share Posted August 17, 2022 18 minutes ago, CyranoJ said: I mean if you have single/double pixel wide objects 2x200 arranged horizontally so at 0,2,4,6 etc that way your vertical 'stripe' is 'horizontal' (sequential) in RAM. Ah, you mean OP objects. Ok, I guess I get the idea. So each column is an object. The blitter writes linearly into the object. But the minimal X size of an object is 1 phrase, which means here 4 pixels. Anyway an idea to keep in the notebook. 1 Quote Link to comment Share on other sites More sharing options...
saboteur Posted August 17, 2022 Share Posted August 17, 2022 I've always been interested in voxels, but never understood the intracacies of rendering. E.G you use a height map for the terain but do you only plot the surface (single pixel layer) or as a solid ( multiple layers ) But I guess that depends on how you interact with the terrain ( you can blow holes in it ). Anyhoo always seemed to me that it created some very realistic terrain to roam around. Quote Link to comment Share on other sites More sharing options...
42bs Posted August 17, 2022 Author Share Posted August 17, 2022 4 minutes ago, saboteur said: I've always been interested in voxels, but never understood the intracacies of rendering. E.G you use a height map for the terain but do you only plot the surface (single pixel layer) or as a solid ( multiple layers ) But I guess that depends on how you interact with the terrain ( you can blow holes in it ). Anyhoo always seemed to me that it created some very realistic terrain to roam around. This one is good to learn: https://github.com/s-macke/VoxelSpace 2 1 Quote Link to comment Share on other sites More sharing options...
saboteur Posted August 17, 2022 Share Posted August 17, 2022 Brilliant - thanks for the link. Commanche landscapes and speed always impressed. 1 Quote Link to comment Share on other sites More sharing options...
RollOut Posted August 17, 2022 Share Posted August 17, 2022 That looks really cool. I may have misunderstood, @42bs, is this part of a project you are working on, in more like a stand alone proof of concept? Quote Link to comment Share on other sites More sharing options...
42bs Posted August 17, 2022 Author Share Posted August 17, 2022 21 minutes ago, RollOut said: That looks really cool. I may have misunderstood, @42bs, is this part of a project you are working on, in more like a stand alone proof of concept? I wanted to make a demo for Sillyventure but was to late to finish in time. I will polish it a bit and then publish code as usual. Quote Link to comment Share on other sites More sharing options...
SCPCD Posted August 17, 2022 Share Posted August 17, 2022 12 hours ago, 42bs said: Ah, you mean OP objects. Ok, I guess I get the idea. So each column is an object. The blitter writes linearly into the object. But the minimal X size of an object is 1 phrase, which means here 4 pixels. Anyway an idea to keep in the notebook. There is the "FIRSTPIX" field in the BitmapObject that can be used to start on a subboundary of the phrase. Maybe you can use it to set a bitmap object of 1 phrase wide with the firstpixel as the 4th one. Nether used it myself though (so didn't know if it works properly in any cases ;)) Quote Link to comment Share on other sites More sharing options...
+cubanismo Posted August 17, 2022 Share Posted August 17, 2022 9 minutes ago, SCPCD said: Ah, you mean OP objects. Ok, I guess I get the idea. So each column is an object. The blitter writes linearly into the object. Doesn't that just move the overhead from the blitter to the object processor though? Or does the OP handle all these objects more efficiently somehow when it walks the list? Quote Link to comment Share on other sites More sharing options...
42bs Posted August 17, 2022 Author Share Posted August 17, 2022 I changed from vertical to horizontal stripes and could not see a significant difference. Quote Link to comment Share on other sites More sharing options...
jguff Posted August 17, 2022 Share Posted August 17, 2022 2 hours ago, 42bs said: I changed from vertical to horizontal stripes and could not see a significant difference. If you have two maps (color and height), are you interleaving the the two maps together to avoid crossing page boundaries constantly? 2 Quote Link to comment Share on other sites More sharing options...
42bs Posted August 18, 2022 Author Share Posted August 18, 2022 4 hours ago, jguff said: If you have two maps (color and height), are you interleaving the the two maps together to avoid crossing page boundaries constantly? Currently it is only one map. The height defines the color. 0..10 blue, 11..100 green, 100..200 brown and the rest grey. Quote Link to comment Share on other sites More sharing options...
ArneCRosenfeldt Posted August 20, 2022 Share Posted August 20, 2022 Commanche (1992) had tilt. When you fly into a mountain, you see that they draw squares ( a bit like traces in Quake I ) .. not columns. Commanche has a z-buffer. So why not port that engine? Draw back to front const-z stripes .. Ah it is a bit complicated when you pitch .. but basicaly you coudl flood the blitter with DESTZEN, flat shaded squares and later use the z data to render other objectes. I still think that the fast JRISC is better suited for some intelligent rendering like Quadtree. It may be faster to rotate 90° after the rendering. There is suprising fast planar to chunky code out there for other systems. On Yag you could blit a whole DRAM page into SRAM, then let JRISC rotate it by 90° and then blit back. Use OP to create 32x32 tiles on screen. Or better use some running / staggered system and have 64x16 tiles .. 8 Quote Link to comment Share on other sites More sharing options...
philipj Posted August 24, 2022 Share Posted August 24, 2022 (edited) On 8/17/2022 at 5:27 AM, 42bs said: This one is good to learn: https://github.com/s-macke/VoxelSpace The images on the website reminds me of the old "Vistapro Landscape" program... it had a feature where one could view a "fly through" scene using some low vector or fractal looking scene before you actually render the fly-through... I remember thinking to myself when dealing with the old program "wouldn't it be neat to have a polygon based 3D engine that rendered as fast as Voxels (high details) do without the overhead of a limited polygon count based 3D engine...?" But then again that's a bit of a dream engine on my part; it has been fun doing research on that sort of thing over the years. https://youtu.be/do1LWcPPtew Edited August 24, 2022 by philipj Quote Link to comment Share on other sites More sharing options...
42bs Posted August 24, 2022 Author Share Posted August 24, 2022 Actually, having a working landscape generator, my next plan is a poly landscape. Only I struggle with the mathematics. 1 Quote Link to comment Share on other sites More sharing options...
philipj Posted August 24, 2022 Share Posted August 24, 2022 (edited) I want to use Voxels to create 3D surfaces or pseudo 3D surfaces more so than landscapes. Edited August 24, 2022 by philipj 1 Quote Link to comment Share on other sites More sharing options...
+CyranoJ Posted August 24, 2022 Share Posted August 24, 2022 1 hour ago, philipj said: I want to use Voxels to create 3D surfaces or pseudo 3D surfaces more so than landscapes. JOINED May 31, 2003 You haven't even accomplished HELLO WORLD in 19 years of ramblings. 1 6 Quote Link to comment Share on other sites More sharing options...
+Gemintronic Posted August 24, 2022 Share Posted August 24, 2022 Here's your chance to get your feet wet philipj! Made a screenshot of a hello world for you. I dumped the JagStudio zipped contents into C:\JagStudio Added C:\JagStudio to the PATH Made a hello folder under C:\JagStudio\projects\basic Create a hello.bas file with the text " rapPrint "Hello philipj" " Copied the ASSETS folder and asset.txt, rap*.s files from the print project to the hello project From a Administrator level PowerShell shell went into the C:\JagStudio folder and executed "build hello ROM" 5 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.