Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

World Building EasyRoads3D v3 - the upcoming new road system

Discussion in 'Tools In Progress' started by raoul, Feb 19, 2014.

  1. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    Hmm a new problem with decals:
    Terrain OK, but over road it disappears:
    upload_2019-12-5_16-46-0.png
     
  2. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
  3. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi Andreas12345,

    That looks like a decal material in the demo package. I don't think they are actually used. But this is what I see in Unity 2018.3+:

    material.jpg

    Note the settings at the bottom starting at The Terrain Z Fighting Offsets

    What type of shader do you use on the road? Does it have an Offset as well? The Offset on the decal material should be stronger negative. Also note the Render Queue settings.

    Which version of the demo package do you use? And was it imported in an older version of Unity and upgraded to the version you use now?

    Thanks,
    Raoul
     
    Andreas12345 likes this.
  4. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    You ask the right questions, i will check :)
     
  5. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    MyRoad use this material
    upload_2019-12-5_20-27-45.png

    When i zoom out, sometimes the decals are shown.
    But when i zoom in they are not visible
     
    Last edited: Dec 5, 2019
  6. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Have you compared and adjusted your decal settings according those in the image in my previous post?

    Thanks,
    Raoul
     
    Andreas12345 likes this.
  7. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    Yes i did
     
  8. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Can you give more feedback, what is the situation? :)

    Or you could have a look for example at the start end decal example materials in the demo package, the setup of the material is the same

    http://unityterraintools.com/tutorials/decals.php

    Thanks,
    Raoul
     
    Andreas12345 likes this.
  9. ibearjp

    ibearjp

    Joined:
    Sep 24, 2014
    Posts:
    15
    2019-12-06  Unity 2019.2.14f1_ _DX11_.png

    I did use the start end offset but it sometime works and some times doesn't and when it works i can't seems to undo when i update scene instance, i have to reopen the whole scene. As for the crl H, tried it and still no marker...
     
  10. ibearjp

    ibearjp

    Joined:
    Sep 24, 2014
    Posts:
    15
    2019-12-06.png
    Additional Image
    Start seems to work but end doesn't?

    I have also select the start maker but end maker won't appear.
     
    Last edited: Dec 6, 2019
  11. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi ibearjp,

    I belief the default Start / End Offsets only work for new instances. Can you try deactivating > reactivating the side object.

    In your screenshot the End Offset is 6. Offsets can overlap the other marker (when this is not the last marker) which will happen when the offset is a positive value. So to end the side object in front of the last marker a negative End Offset must be used. generally a negative value is used here. But for example for bridges a positive End Offset larger then the terrain heightmapscale * 1.5 is recommended. This will make sure the bridge will overlap possible gaps between the road and the bridge after the terrain is adjusted.

    Regarding the last post I mentioned that activating a side object for a marker will cover the area from that marker to the next marker, the End Offset is associated with that marker. In your screenshot the last marker is selected, not the second last marker which controls that section. I will make a note to somehow also activate the control if that marker is selected. or perhaps always show all controls for the selected side object. But currently this is marker specific. There will be more to this soon in v3.2.

    Thanks,
    Raoul
     
    ibearjp likes this.
  12. ibearjp

    ibearjp

    Joined:
    Sep 24, 2014
    Posts:
    15
    Offsets can overlap the other marker (when this is not the last marker) which will happen when the offset is a positive value.< Probably the problem

    In your screenshot the last marker is selected, not the second last marker which controls that section.< This fix the problem

    Would prefer to have marker to adjust like the start maker in future version maybe?
    And easier way to turn off build terrain for just a section of the road would be nice.

    Thanks for the reply!
     
    Last edited: Dec 6, 2019
    raoul likes this.
  13. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    In v3.2 there will be different ways to build Side Objects. The current workflow will still be part of that but Start / End Offsets will change into a single Offset control. A side object can only start or end at a specific marker so that will work well and it will also cover the situation in your last screenshot where the last marker is selected. In v3.2 selecting that marker will control the offset relative to that marker, the end offset in this case.

    Turning off terrain deformation for a road section is possible by toggling on "No Terrain Deformation" for the markers in that area. This can also be done by selecting multiple markers. Terrain deformation is switched off automatically for bridges.

    Thanks,
    Raoul
     
    ibearjp likes this.
  14. Andreas12345

    Andreas12345

    Joined:
    Oct 17, 2013
    Posts:
    526
    I ll check out, the error is most between the eyes :)
     
    raoul likes this.
  15. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
    IT WORKS!!!

    Oh goodness, I am in SUCH a happy mood. I have been working on creating traffic for my game using Unity's new ECS and the Lane Data that is in the beta of ER3D. I JUST got it working.

    I have a little bit of code cleanup and some additional testing. However I should be able to post all of this tomorrow on my github.

    This traffic code is very basic; It takes then to the end of a Road and Connection combo. When it gets to the end of a Road it chooses a random path through the Connection to the next road. This way the traffic is as random as possible. There are no lane changes (except when it goes through an intersection) and there is no collision. Just movement. But I can see that I added a F@$KTON of autos to my scene, which is hover cars so multiple levels, and it has NO affect on frame rates. What I am building is for VR, so frame rate is VERY important.

    Hope this helps others, and mostly thanks to @raoul who is ABSOLUTELY great at helping out here. Without his help, and the great asset, I could have never finished this code.
     
    John-G, hopeful, Noa3 and 3 others like this.
  16. JamesWjRose

    JamesWjRose

    Joined:
    Apr 13, 2017
    Posts:
    687
    Ok gang,

    Here is the code I created for traffic using Unity's DOTS technology and ER3D.

    https://github.com/Blissgig/Easy-Road-3D-ECS-Traffic

    I have spent time creating the document on how this works, but if I miss something please let me know so I can update it.

    I just ran some tests where I fill 50% of the lanes with traffic, for a total of over 1900 autos, and NO affect on frame rate. So YAY for DOTS, and again thanks to Raoul and his team for a great asset and terrific support.
     
    John-G, raoul, hopeful and 1 other person like this.
  17. donkey0t

    donkey0t

    Joined:
    Oct 23, 2016
    Posts:
    71
    Hi, newbie Easy Roads user. I'm using EasyRoadsPro with Vegetation Studio Pro. I have a terrain with grass & tree masks on set to place...grass and trees on it ;) I then have a ER going over the terrain. The roads I've set to remove trees. However, I still get them. What am I doing wrong?
     

    Attached Files:

  18. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi donkey0t,

    Didn't you ask a similar question last week? https://forum.unity.com/threads/eas...-new-road-system.229327/page-154#post-5232593

    Otherwise, the screenshot shows the Build Settings for the terrain. The vegetation options are Unity terrain object related, not Vegetation Studio. I do not see Vegetation Studio handles on the road. What are the Vegetation Studio settings for the specific roads, and are the respective Vegetation Studio components visible in the Inspector when selecting these roads in the hierarchy.

    Thanks,
    Raoul
     
  19. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    704
    Hi, I have a little problem creating a custom package containing ER.
    The culprit is that ER uses absolute pathnames and it's not relocatable.
    Could you please fix it so that it doesn't use absolute pathnames?
    It's not a good practice to use absolute pathnames in general anyway.
    Thanks.
     
  20. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi chrisk,

    EasyRoads3D should not use absolute path names and should be relocatable. How exactly is this causing problems in your project? For which assets is this the case or do you get error messages?

    Thanks,
    Raoul
     
  21. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    704
    It's possible that it's because I'm using an older version. Has the absolute pathname removed recently? If so, I'll try to update it to the latest version and try it again.
     
  22. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    This has not changed for a long time, early v3. That is why I asked for more info, in what way this does not work for you so we can test that.

    Thanks,
    Raoul
     
  23. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    704
    It may be my mistake. I'll test some more and get back to you. Have you created a ER custom package and succeded?
     
  24. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    We create packages all the time. What are the exact steps to recreate this? What type of custom package are you creating? Is this something that goes wrong in the project where the custom package is imported? In that case, what is the history of that project? Was EasyRoads3D already imported in that project? If so, is it located in other folder?

    Thanks,
    Raoul
     
  25. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    v3.2 beta 1 is now available on our website

    Additional to tunnel support announced last month v3.2, this is an introduction to more auto generated side objects based on the terrain and road profile and side object rules.

    Now also included are auto generated bridges, guard rails for sharp turns and for lower terrain sections right next to the road, retaining walls and objects like sharp turn signs.



    The first v3.2 beta is available on our website, https://www.easyroads3d.com/download.php

    Beta release notes:
    https://www.easyroads3d.com/v3beta.php

    For tunnels Unity 2019.3 and the Unity 2019.3 package are required.

    Please import the package in a new project if you like to check it our, or backup your existing project first.

    Thanks,
    Raoul
     
    Freznosis, JBR-games, Rowlan and 5 others like this.
  26. ME_CGI

    ME_CGI

    Joined:
    Dec 9, 2019
    Posts:
    3
    This looks like an awesome tool.

    I work mainly in AEC and typically we build a mesh in another DCC app, like 3ds Max, to be used as "terrain".

    So by the time its imported into Unity its just a fbx mesh. In simplest form, just a plane or a cube, used as a large flat surface we stick buildings onto etc.

    So my question is, with EasyRoads3D Pro, can it only create roads on terrain objects, or can I create roads on any mesh, like in my case a flat imported fbx mesh from another app?
     
  27. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi ME_CGI,

    The tool works with the Unity terrain object in a way that it will adjust the terrain shape to the road shape.

    This is not possible for mesh terrains but it is possible to assign a mesh terrain object in General Settings > Scene Settings. Markers will snap to the mesh terrain. Since you mention your fbx mesh is flat, this should work well in your case.

    Thanks,
    Raoul
     
    ME_CGI likes this.
  28. jdtec

    jdtec

    Joined:
    Oct 25, 2017
    Posts:
    302
    Hi, I've just started using EasyRoads and have a couple of questions.

    1) When will support for Y style crossings be available? Is there anyway to achieve this currently?

    2) If I had a complex X crossing with 3 lanes connecting on some sides, 2 on others, how would I begin to create such a thing? Or does EasyRoads just support generic uniform lane crossings currently?

    3) I see how to add sidewalks/pavements to a crossing but not sure how to do this for standalone road?

    EDIT: Ok I'm seeing lots of promising stuff in the latest beta from this video
    so have emailed you for a serial number so I can access it.
     
    Last edited: Dec 10, 2019
  29. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi jdtec,

    The v3.2 and v3.3 features have been swapped. the first new v3.2 beta was released yesterday. This was announced a couple of posts above. The previous v3.2 beta will soon be available again as v3.3 alpha. It includes support for flexible crossings like Y connectors.

    This is done automatically using the mentioned Flex Connector. In the current v3.1 it is a matter of assigning the specific road types to crossing connections by selecting the connection in the hierarchy. In General Settings > Crossing / Connection Prefabs.

    A new Dynamic Connection Prefab can be created for this. It will be added to the available list Dynamic Prefabs in the Connections tab. The prefab is stored in /Assets/EasyRoads3D/Resources/dynamic prefabs/ where it can edited in a similar way by opening the prefab in the Inspector.

    In v3.1 sidewalks on roads are controlled by the corner handles on the left and right side of each crossing connection. When the handle is green the same sidewalk style will also appear on the road.

    Thanks,
    Raoul
     
    jdtec likes this.
  30. jdtec

    jdtec

    Joined:
    Oct 25, 2017
    Posts:
    302
    Thanks Raoul, I'm looking at creating a new road type to help accomplish this. How would I go about making a road type with additional lanes?
     
  31. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    I see you edited your previous post. The features in that video are indeed available the previous beta, this package will soon be back on the downloads page for v3.3 also including the new v3.2 features.

    Regarding road types and lanes. That is currently more material / texture related, you can add your own materials to road types. Alternatively lane markings can be added as side objects. Both the demo package and the HD Roads Add On package includes examples of this. Multiple line markings can be created quickly by duplicating one and adjust the X Position value which represents the relative position to the center of the road. These line making side objects can be auto activated for the specific road type, that way the lines will be created automatically for each new road of that type.

    Thanks,
    Raoul
     
    jdtec likes this.
  32. jbaujb

    jbaujb

    Joined:
    Oct 17, 2019
    Posts:
    16
    I have purchased the HD road addon but I still cant get URP working. Everything show up purple in the demo scenes and ones I try to create. The new shaders don't seem to make a difference.
     
  33. AdamSingle

    AdamSingle

    Joined:
    Apr 18, 2013
    Posts:
    22
    I'm having an issue where I can't create a new road network. I get an error

    ArgumentException: The Object you want to instantiate is null.
    UnityEngine.Object.CheckNullArgument (System.Object arg, System.String message) (at C:/buildslave/unity/build/Runtime/Export/Scripting/UnityEngineObject.bindings.cs:374)
    UnityEngine.Object.Instantiate (UnityEngine.Object original) (at C:/buildslave/unity/build/Runtime/Export/Scripting/UnityEngineObject.bindings.cs:231)
    EasyRoads3Dv3Editor.OQCODCDQQCV3.CreateEasyRoads3Dv3Object () (at <e7d39089704443f289d79ffeb8b68a55>:0)
    UnityEditor.GenericMenu:CatchMenu(Object, String[], Int32)

    Any ideas what this might be?
     
  34. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi jbaujb,

    LW RP is renamed to URP in Unity 2019.3. It seems it is close to being offcially release but I belief it is still in beta. Is that indeed what you are using? I will check that.

    For LW RP there are packages up to version 6.9

    Thanks,
    Raoul
     
    Last edited: Dec 11, 2019
  35. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi AdamSingle,

    Does this happen after a version upgrade to the new v3.1.9?

    In 3.1.9 the spaces were removed from the “ER Road Network” prefab in /Assets/EasyRoads3D/Resources/

    What probably happens is that Unity does not update the name after the v3.1.9 import in the project with the older version. To prevent issues with that the code will check this situation, but the error is already thrown before that. Could you remove the spaces manually for now for this prefab. I am working on some small improvements for preset asset imports, an update will follow later this week also with a fix for this issue.

    Thanks,
    Raoul
     
  36. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    @jbaujb,

    There were some shader errors in version 7.1.6 in Unity 2019.3.f1. These errors are fixed, the HD Roads asset store package will be updated but I will send the updated shaders already to you so you can test them.

    Thanks,
    Raoul
     
  37. jdtec

    jdtec

    Joined:
    Oct 25, 2017
    Posts:
    302
    Hi Raoul, thanks for your help so far.

    I see that I could take one of your existing road textures and edit it to create a multiple lane texture and then a corresponding material. I was confused because I saw this video from a year ago here:

    Shows a ER Prefab with new tabs [Road Shape] [Sidewalks] [Lane Info]. I have just downloaded and imported the latest 3.2 beta package and don't see these so they're unavailable currently or cancelled? I guess I was expecting something like this to add additional lanes rather than making new textures. Next I tried the side object method...

    I opened the demo scene. Selected a road and clicked Side objects > [Misc] > Primary Road Line Marking.
    After clicking 'Default marker active state' to enabled and adjusting the offset I can see the marking. I don't know why 'Default marker active state' exists though as I see no other way to activate it per road segment?

    Next I want to change the texture of this road marker to be a dashed road marker. I try changing the material but it doesn't lead to any changes. I click update instances in scene and still no changes. I notice the texture the material uses has many road decal sprites. This makes me wonder how the road marking decal has been created in the first place (custom mesh or UV editor? - I can't find any documentation on how to use the UV editor only the odd mention of one on the site). I have an example in the demo scene but with no idea as to how it was created or customised I'm stuck. I can see 'Materials & Textures' in Settings tab but have no idea what this does or how to use it...

    In my own scene I tried to import an existing side object. I opened the 'Import Side Objects' window which is empty. I then try searching through EasyRoad files for existing side object prefabs. I can't find any after looking through the demo files and other places :/ I tried importing something but it said it's not a valid side object - not surprising really as I don't know what I'm looking for. It would be better if this window auto-filled after scanning the project for side objects that are imported to the project already.

    First goal is to create a 3 lane to 2 lane connection like this with proper road markings:
    Screenshot 2019-12-11 at 11.15.55.png

    To achieve this I think I have to:

    1) Create 3 lane road ideally using side-object dashed road markings
    a) Create dashed road marking side-object prefab - unsure how to do this currently as explained above.
    b) Create or find road texture/material with no centre road markings

    2) Create 2 lane primary road - ok this actually was easy to do!

    3) Connect the two roads... I have managed to drag one road type onto the other. What is the best way to make two roads with different widths and lane numbers merge reasonably nicely?

    I would need to use EasyRoads eventually to create far more advanced routes such as shown below.
    Screenshot 2019-12-11 at 11.17.02.png Screenshot 2019-12-11 at 11.18.04.png

    If you could point me to step by step and exact detailed instructions that would help me with any of the above that would be appreciated.

    So far I think EasyRoads is great value for money for basic routes, however, I'm not sure if what I'm trying to do is a bit beyond the scope of what can be done without a great deal of custom work?
     
  38. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi jdtec,

    Please see this post above in reply to your post https://forum.unity.com/threads/eas...-new-road-system.229327/page-155#post-5266995

    To resume, v3.2 and v3.3 features have been swapped, a v3.3 alpha with features in the video and the v3.2 features will be available again soon.

    The line marking in the demo package is used on specific road sections only, like in bends where overtaking is not allowed. That is why "Default marker active state" for this side object is switched off. It is easier to activate this type of side object for some sections only, then having to deactivate them on all other section.

    This type of line marking is actually something that works well with the new v3.2 feature auto generating side objects based on sharp turn angles.

    In your case indeed you want "Default marker active state" always switched on because the intention is to set the line markings for the road in general.

    This specific side object is a shape type of side object, with a decal material attached, the UVs to match the line are set through the UV Editor in the Shape Editor Window.

    What exactly did you change in this setup? In what way did you change the material? Changing the material will probably also mean the UVs must be updated in a similar way as described above.

    Is this in the same project? In that case, please try the "Add Project Side Objects" button. The Import option is for importing side object presets used in another project.

    About "scanning" that would be related to auto importing new presets that are not imported yet. It seems that is not involved here, but check the last line in this post earlier today https://forum.unity.com/threads/eas...-new-road-system.229327/page-155#post-5269806

    The HD Roads package includes asphalt textures with no line markings. There are many resources on the internet with free textures, also road textures.

    3) is, I think, covered in this post https://forum.unity.com/threads/eas...-new-road-system.229327/page-155#post-5266533

    If you want access to the previous 3.2 beta I can prepare a link. It will be available again soon anyway.

    This partially involves lane directions which I assume is AI related? That too is available in the mentioned beta.

    What do you mean with custom work?

    Roads are complex, google "streets" or something like "motorway overpasses". It is impossible to provide a tool that can handle all that out of the box instantly without having to setup anything. The images you posted, especially the last, are also specific. To achieve that "custom work" is required, setting up lane data, lane connectors.

    From a road creation point of view one of the first things that was added for v3 is the custom prefab system, you can bring in your own assets. That way you do not rely on what is built-in. Meanwhile the tool is developed further with new features, at least once a month an update with new features is released.

    So far I would think everything you want to do is already possible in the current v3.1 and otherwise the specific beta which includes more crossing and AI options. But indeed you are looking for more complex road setups which also requires more advanced features which require a learning curve. We are doing our best to provide a tool that can be used in different ways, different situations and will provide support whereever we can.

    Thanks,
    Raoul
     
  39. otomat

    otomat

    Joined:
    Nov 8, 2019
    Posts:
    15
    Hi to all,
    i just bought "easy roads pro" and "HD addon" and i want to use them in a 2019.1.10 unity version project with HDRP.
    till now i could not make materials work. i did some research but did not find an exact answer till now.
    I am a bit new to UNITY and its dependencies so any help is appreciated.
     
  40. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi otomat,

    HD RP requires the additional HD RP package with materials and shaders setup for HD RP. The package is located in /Assets/NatureManufacture Assets/HD Roads/SRP Support/. For Unity 2019.1.0 the 6.9+ version is required.

    Did you import this package?

    Thanks,
    Raoul
     
  41. otomat

    otomat

    Joined:
    Nov 8, 2019
    Posts:
    15
    Thanks a lot Raoul, i imported srp 5.7.2+ because in my package manager i can not upgrade HDRP more than 5.7.2.
    is it ok or can i load 6.9+ package ? (i tired and it did not work) but everything is ok now. Thanks for your fast reply, i enjoy easy roads very much :) good work.
     
    Last edited: Dec 11, 2019
  42. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    6.9+ could actually be Unity 2019.2. In any case, if the 5.7.2+ HD RP package works then all is good :)

    Glad to hear you like the tool!

    Raoul
     
  43. jdtec

    jdtec

    Joined:
    Oct 25, 2017
    Posts:
    302
    Hi Raoul, thanks for the reply, maybe my previous post wasn't worded so well so I'll try again.

    Ok I will wait for v3.3 or a link to the old v3.2. In the mean time I will try to make the 3 lane road with side objects.

    Are you able to link me to a tutorial that shows how to create a side object where the UV editor is used or provide *exact instructions* for how to make this 3 lane road using side objects? Please? :)

    My previous post might have sounded a bit like rant but I'm just trying to show you what my workflow/thought process is without exact instructions. I have to keep guessing where things are or stumbling through the interface. Based on the information you have provided this time I had another go adding a side object which I have documented below:

    1) Create new side object
    2) Try to find the shape editor window... can't see it in the side object manager, can't find it searching through Unity menus
    3) Go to http://unityterraintools.com/EasyRoads3D/v3/html/side_objects.html
    4) Find the create new side object button again, see an image which has the 'Open Shape Editor Window' button but it doesn't say where it is in the interface unless I missed it?
    5) Realise I need to change to shape object to show the window!
    6) Open shape editor with new 'Side object 1' selected
    7) UV editor is greyed out for some reason... ok let's try the demo scene instead to see if I can learn more.

    8) Open demo scene
    9) Click on a road
    10) Add the lane marking side object
    11) Click 'Select in side object manager'
    12) Open shape editor and UV Editor is greyed out in here too... was expecting to see something that would show the road decals texture with the relevant texture UVs.

    So the next question is why is the UV editor greyed out... however, I think at this point providing me with a tutorial that has step by step instructions for using the UV editor would be the best course of action? I've had a look over your website and didn't see anything yet, did I miss it?

    Of course I don't expect it to handle a motorway overpass similar to the model a user made a few pages back and it just work out of the box. I emphasise as I understand the complexity having made a OSM interpreter/renderer myself that processes for multiple lanes and other things.

    I am excited by the potential of EasyRoads and just need a little help figuring out how to use it! :)
     
  44. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi jdtec,

    There is no tutorial specific to creating a 3 lane road using line markings as side objects. The demo package includes a range of side objects, all using different setups. Tutorials can be found here: http://unityterraintools.com/tutorials.php

    There are three side object types, the "Side Object Type" dropdown just below the side object name near the top.

    1) Mesh Object, for objects like lampposts
    2) Shape Object, the shape can be defined in the Shape Editor window and will be created along the track
    3) Procedural Object, a mesh object that will be repeated along the track.

    In the case the line marking in the demo package, /Misc/Primary Road Line marking, the Shape side object type is used. "Shape Object" is selected in the Side Object Type dropdown. The material "road_decalMat" is assigned to the Material Slot. Is this material assignedon your end? And indeed just above the material slot the "Open Shape Editor Window" button is visible.

    After opening it two nodes are visible, hit the Z key to put focus on these nodes if they are not visible. This is a simple line so only two nodes are required. Do you see these two nodes with a black line between them?

    On the left in Shape Editor window there is indeed a button "UV Editor". This will open the UV editor window which will show the decal texture assigned to the specific "road_decalMat" material. Do you see the texture? The line for this side object is located on the left of the texture. At the bottom on the horizontal red line you will see two circle handles. These two circle handles represent the left and right node in the Shape Editor Window. These handles can be dragged. That way you can set the UV positions on the material for this side object. If you use your own material with line markings then this is how you can select the UV positions.

    next is the position on the road. This line marking is for sharp turns and is located just next of the stripes (which are part of the road texture) in the middle of the road. To achieve that "X Position", visible in the included screenshot, is set to -0.2 relative to the center of the road.

    In your case you can setup one line marking side object. Once it works well it can be duplicated (the "Duplicate Side Object" button near the top) afterwards and set the X Position for each line to the position where it should appear on the road. So you could start with duplicating this side object because a couple of settings you want are already set the way you want for this side object, like "Clamp To Road Geometry" and "Path Normal" alignment.

    lineMarking.jpg

    Thanks,
    Raoul
     
  45. jdtec

    jdtec

    Joined:
    Oct 25, 2017
    Posts:
    302
    Hi, thanks for the fast reply.

    I see no black line and pressing z doesn't seem to do anything (except toggle pivot/centre in the main Unity controls).

    Can you spot anything in the screenshot below that might suggest I've done something wrong?

    Screenshot 2019-12-11 at 16.10.12.png
     
  46. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    There are no nodes, that is probably also why the UV Editor is greyed out. Is the side object actually generated?

    Double clicking on the canvas will add nodes. For this side object the first node is on the left at (-0.1, 0) and one the right (0.1, 0)

    lineMarking2.jpg

    Thanks,
    Raoul
     
  47. otomat

    otomat

    Joined:
    Nov 8, 2019
    Posts:
    15
    Hi once again Raoul, firstly i must mention i am new to unity. i want to learn how to use easyroads in my rnd project with unity 2019.1.10.
    Firstly i create a new project with hdrp
    But when i import EasyRoads 3d pro everything is pink,
    its also pink with demo project imported.
    i am probably missing some steps but i can not get a solution from my searches.
    if you can help me with these steps i would be grateful.
     
  48. raoul

    raoul

    Joined:
    Jul 14, 2007
    Posts:
    6,722
    Hi otomat,

    As the description says, the provided demo package / project is more for learning purposes to get familiar with the tool, it is not optimized. This demo package works well in a standard 3D project which does not require RP specific materials. To make it work on HD RP, the materials / shaders must be updated. That is why all objects are pink.

    Is this still also related to the HD Roads package assets you asked about yesterday? Does this package work well now in your HD RP project?

    Thanks,
    Raoul
     
  49. otomat

    otomat

    Joined:
    Nov 8, 2019
    Posts:
    15
    Hi Raoul, thanks for your fast support, HD Roads package works well with my hdrp project, i have no issue with it.
    But to learn and apply i was testing with a new project which i lastly tried 3d project which you mentioned and see it works.
    There are some nice side assets from EasyRoads package (walls, Fences etc..) which i want to use with my HDRP project and i think with your help now i can see the workflow.
    i need to update the shaders (by recreating suitable HDRP shader) or replace with the suitable ones load from HD addon.

    Thanks a lot.
     
  50. jbaujb

    jbaujb

    Joined:
    Oct 17, 2019
    Posts:
    16
    Adding a new road network (shift + click) using 2019.3.0f3 doesn't seem to work. I am also still confused about how to use the HD roads plugins with urp/lwrp, do I need to set all the shaders to the srp ones then reset the materials manually?