Jump to content
  • Advertisement

LazyDuke

Member
  • Content Count

    8
  • Joined

  • Last visited

Community Reputation

6 Neutral

About LazyDuke

  • Rank
    Newbie

Recent Profile Visitors

1191 profile views
  1. LazyDuke

    "3D Decals" for roads on terrain.

    That would be pretty cool!
  2. LazyDuke

    "3D Decals" for roads on terrain.

    Before doing that, first i need to snap the road geometry to the ground. If i tried to do what you say right now, there would be z-fighting and clipping between the road decal and the terrain because the road is not a real decal since it hasn't been flattened to the terrain yet. That's what i need to know, how to turn the curved road mesh into a decal and after that blend it with the terrain. Sorry for not being very clear. If only Unity had built-in spline decals... I know you already told me a way how to do this, but i need a more accurate one since the player will be able to place roads wherever they want.
  3. LazyDuke

    "3D Decals" for roads on terrain.

    This is what i don't understand, rendering the decals to backbuffer. I assume that by rendering the decals you mean rendering them from a 3D perspective, and then when rendering the terrain blend the pixels with the corresponding ones from the decal buffer, so that they don't look like they are floating when you look closely, right?
  4. LazyDuke

    "3D Decals" for roads on terrain.

    Okay, so i ran into a problem... My project is a small "city builder", and the player will modify the terrain(I got the terrain tools already covered). If i simply let the player draw the road with the spline system, if they set the start and end of the road to have a mountain in between, the road will go through the mountain. With the back buffer technique the road will still be drawn over the terrain, but it will look weird, right? Or did i completely misunderstand it?
  5. LazyDuke

    "3D Decals" for roads on terrain.

    Yes, Unity lets you choose between forward and deferred, and i'm using deferred for my project. I'll try to get something working, thanks! I'll ask for more help if i can't get it to work.
  6. LazyDuke

    "3D Decals" for roads on terrain.

    It looks like just what i want to achieve!(By the way, i also love how the ocean changes quality the farther you get from it). I'm just getting started with shaders, so i don't know how all that back buffer texture and sampling works, so i'm a little confused there. But the way i understood it, you're drawing the roads "flattened" into the terrain texture/pixel shader instead of a road model over the terrain, right? I could probably do that with the roads and just raytrace the sidewalk, i guess clipping won't be noticeable on the sidewalk since it's meant to be taller than the road. I think Planet Coaster does something similar to this. Will i be able to use a separate shader for the roads this way? I want to do some normal mapping on them.
  7. LazyDuke

    "3D Decals" for roads on terrain.

    Thanks! The Splines are actually a step forward, and it's exactly what i was looking for, BUT, i still need a way to modify the geometry of the curved mesh to match the underlying terrain without clipping through it. This is what i mean(Sorry for the 5 years old kid drawing lol): Image 1 would be the geometry of the curved road, and the second image is the terrain wireframe. As you can see in the third image, the road doesn't have enough gemoetry to snap correctly to the terrain so it will clip through it. That's what i need help with right now. I agree that Unity is missing a lot of very important tools that other game engines like Unreal already have, and it's a shame. I was planning on buying an asset that does what i want, but i prefer scripting it myself so i can fully understand it and make it do exactly what i want(And for free!)
  8. Hello! I'm not sure if this is the right place since i'm new to the forums. I'm creating a simple "City creator" right now, and, obviously, i need to create a Road tool for it. I was planning on doing raytracing to make the road snap to the terrain geometry, but it would clip through the terrain in places with mountains or different heights. I don't want to make a simple 2D decal because it would not look good without shape(The sidewalk is of course going to be taller and have a different geometry than the road itself) and i want to make it "bendable". I'm not the best at maths and geometry manipulation so i don't know where to start... I'm using Unity by the way, and sorry for my bad English!
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!