Asset - Shaders Snidr's Voxel Sprites

Discussion in 'Marketplace' started by TheSnidr, Feb 23, 2019.

  1. TheSnidr

    TheSnidr Heavy metal viking dentist GMC Elder

    Joined:
    Jun 21, 2016
    Posts:
    462
    [​IMG]
    Snidr's Voxel Sprites

    Welcome to the topic about Snidr's Voxel Sprites!

    Marketplace link
    Executable download link


    This asset allows you to draw 3D voxel objects using ray casting. The asset is made specifically to work well with conventional 3D games, allowing for a combination of voxel sprites and triangle meshes.

    The voxel sprites can be transformed like any other 3D object using matrices. Even if the object is transformed, the actual voxels will still be rendered in world-space, resulting in a lovely low-resolution effect when the object rotates.
    [​IMG]
    The sprite for this car actually looks like this:
    [​IMG]

    The asset has only been confirmed to work on Windows.

    Thanks to:
    kraifpatrik, for showing that you can set the depth of individual pixels in a shader!
     
    Last edited: Feb 23, 2019
  2. IGameArt

    IGameArt Member

    Joined:
    Jun 21, 2016
    Posts:
    125
    So then are these essentially just 2d images rendered to look 3d using a shader, with the addition that individual pixels have their own depth and can appear to pass through other geometries and voxels?
     
  3. TheSnidr

    TheSnidr Heavy metal viking dentist GMC Elder

    Joined:
    Jun 21, 2016
    Posts:
    462
    They are essentially true voxels, since the texture map is laid out so that the voxel sprite has both width, height and depth.
    It can indeed be compared to the so-called sprite-stacking technique, but that technique would not allow for any other rotations than around the z-axis, like this:
    [​IMG]
    [​IMG]
    [​IMG]
    As opposed to the usual way to draw 3D graphics, rasterization of triangles, the voxel sprites are rendered by casting rays from the camera and returning the colour of the first voxel the ray hits. This also returns info about the normal at the intersection, and we can even cast more rays from the position of the intersection for cheap exact shadows and ambient occlusion.
     
    RujiK likes this.
  4. IGameArt

    IGameArt Member

    Joined:
    Jun 21, 2016
    Posts:
    125
    Hmmm, I'm going to experiment with combining this with my voxel format importer. Your renderer is far superior to mine, but mine allows for loading of known formats, like ken silverman's formats :p
     
  5. TheSnidr

    TheSnidr Heavy metal viking dentist GMC Elder

    Joined:
    Jun 21, 2016
    Posts:
    462
    I also made a few tests a while ago, using a 2048x2048 surface for a 256x256x64 world! It had more optimizations, like a cascade of grids that increased in resolution and stuff.
    In the following gif I removed the surface clearing function, resulting in something that looks like a voxel version of the solitaire win effect:
    [​IMG]
     
  6. Samuel Venable

    Samuel Venable Time Killer

    Joined:
    Sep 13, 2016
    Posts:
    1,216
    Truly a work of art. This is really cool!
     
    TheSnidr likes this.
  7. TheSnidr

    TheSnidr Heavy metal viking dentist GMC Elder

    Joined:
    Jun 21, 2016
    Posts:
    462
    Samuel Venable and kraifpatrik like this.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice