Quick Links: Download Gideros Studio | Gideros Documentation | Gideros Development Center | Gideros community chat
Progress using 3D in Gideros - Gideros Forum

Progress using 3D in Gideros

I'm having a hard time prying myself away from the computer since I've gotten into 3D coding with Gideros, having been away from 3D work for a number of years. I mentioned on another thread that I was looking into whether Gideros's 3D support was usable for a new fishing game I have planned, or if I'd need to use pre-rendered textures and build the game in 2D. I dabbled in Unity, but didn't care for the layers and the interface, and would much rather work with a system that just lets me load or create meshes from Blender models, and code all the behavior directly. I'm thrilled to find that Gideros can do a lot more than I would have guessed. Sure, there are limitations, like no support for models with animated armatures, as far as I know, but for an engine that's primarily 2D, it can do plenty of 3D.

Today I made a custom shader that handles aerial perspective (fog, to make distant objects look distant), and to fog underwater objects relative to the depth and the viewing angle, plus water clarity, basically specialized fog that only applies below the surface. So far that's working fine on the landscape, but not with other subsurface objects, so it still needs work, but the effect on the lake bottom is exactly what I had in mind. It's my first experiment with a custom shader, and I clearly have a lot to learn, but it's an encouraging start. I've improved the heightfield code for performance, tried swapping in a landcsape mesh with 16 times more detail than I was using, and it still behaves nicely. I changed my water surface animation method to apply just to the area around the viewer, rather than over the entire body of water, which allows me to scale up the whole world greatly without hurting performance.

If anyone is interested in the heightfield landscape code, or the fogging shader, let me know and I'll share some modules.

Here's the progress so far:





Paul
+1 -1 (+6 / -0 ) Share on Facebook

Comments

  • wow it looks awesome, I didn't know we could something like that in Gideros
    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
  • hgy29hgy29 Maintainer
    I am working on animated models support. I will let you know...
    +1 -1 (+4 / -0 ) Share on Facebook
  • PaulHPaulH Member
    edited November 7
    Oooh... That's really cool! There are lots of things I've used animated models for in the past that I thought I'd do in Gideros using sets of pre-posed models, or break models into parts and move them relative to one another, but models with animations would be much smoother, and more straightforward. I'd love to have that!

    Likes: MoKaLux

    +1 -1 (+1 / -0 ) Share on Facebook
  • MoKaLuxMoKaLux Member
    edited November 7
    @PaulH I nominate you GIDEROS 3D CODER OF THE DECADE :)
  • Thanks, but if there were such an honor, my nomination would go to @hgy29, for the addition of animated models. I can't wait to starting working with that.

    Here's what my project looks like with another week of progress:





    I've fixed some things in the height field mesh generation, fixed the underwater shader and improved the main shader, added programatically generated lakes with variable geographical features, changed the controls from buttons to sliders, added swiping from the center to look around, and today I added a system that populates the world with objects (trees, etc) a zone at a time, fading them in as you approach, and fading them out and removing them from the scene when they're far away. There are still some artifacts in the landscape objects, and there's lots of improvement to be made there, and everywhere, but this has been a good test of performance.

    Even with object density cranked up pretty high, it's still plenty smooth on a Galaxy S10. An old GS4 can only manage around 10 fps at that level, but one can always decrease the amount of scenery detail on slower devices.

    +1 -1 (+6 / -0 ) Share on Facebook
  • Apollo14Apollo14 Member
    edited 1:43AM
    PaulH said:

    An old GS4 can only manage around 10 fps at that level, but one can always decrease the amount of scenery detail on slower devices.

    That's what I was talking about when I said that 3D is too sophisticated.

    For decent 3D we'd need occlusion culling, mesh combining, mesh LODs, benchmarking drawcalls/triangles, etc. And lots of other stuff.

    Honestly, it'd be better for Gideros to become solid 2D engine with support of industry standard SDKs that are required by every mobile publisher, shader editors, particle editors, etc. Or it will become neither fish nor flesh.

    (if someone asked my opinion)
    > Newcomers roadmap: from where to start learning Gideros
    "What one programmer can do in one month, two programmers can do in two months." - Fred Brooks
    “The more you do coding stuff, the better you get at it.” - Aristotle (322 BC)
  • hgy29hgy29 Maintainer
    Apollo14 said:


    For decent 3D we'd need occlusion culling, mesh combining, mesh LODs, benchmarking drawcalls/triangles, etc. And lots of other stuff.

    Actually it depends on what you want to do, and you can always do that yourself in lua. Keep in mind that modern hardware can easily do with brute force what old games did with lots of optimizations. I am already surprised when I see what people can do with Gideros limited 3D support.

Sign In or Register to comment.