Jump to content

Extrusions, intersections progress...


Clyde

Recommended Posts

I have been working on intersections for the "Early Access" Extrusion Pro plugin for GeNa Pro.

As I progress, I will put snapshots here for public comment.

image.thumb.png.330a8219a434aa594914d57ecc390df1.pngWorking on UV's at the moment...

UVsNeedWork_01.png.0f6f91b95963c3e1b03b485c5462b2bd.png

  • Like 3
Link to comment
Share on other sites

I've added separate materials/submeshes for the top, ceiling, floor, and the bottom of the intersection mesh.

image.thumb.png.58f6189d5733aeb7984b1c9c1df030a1.png

Before ^^

image.thumb.png.5e9ddfaa507351de64be4799b14d3845.png

After ^^

If any material is not specified (none or null), then the Extrusion Material is used and no submesh for that part is created.

NOTE: in the above case, what appears as a floor is seen by the code as the top, since the cross-section profile is a single shell.   If an inner shell and outer shell had been created, then the floor would be part of the inner shell.  I'll have a think about this since I can tell whether I am working with an inner shell vs an outer shell at any time during the mesh creation.

Link to comment
Share on other sites

  • 2 weeks later...

I had to modify the Mesh Splitting code to handle multiple submeshes/materials, so that the "Split Meshes At Terrains" option would work with the advanced material settings.

 

image.png.53d68c4a04e528f5885511695cf2cc4b.png

Link to comment
Share on other sites

One BREAKING CHANGE from the previous versions of the Early Access to this project is the orientation of the Texture(s) within materials.

Previously, the textures were oriented such that the textures were rotated counterclockwise when looking at them from the point of view of a wall texture.  This has changed so that now it is not rotated, and the V coordinate is what separates parts of the texture as a horizontal atlas.  

Below shows the current orientation:
image.thumb.png.8928e442239ee1fd637588d22f093e20.png

I should be able to swap the U and V coordinate when detecting an older version of the data, but the textures would still need to be rotated on an older project that used the previous versions.

The reasoning for changing the orientation has to do with the normal maps and their orientation. Just rotating them counterclockwise does not 'just work', unfortunately.

Link to comment
Share on other sites

I have added some features to the Cross Section Editor.  

  •  Shift+Click Calc Normals button - Recalculate Normals for ALL UV Sets.
  • Context Menu Item "Separate UV Set" - will create a separate UV Set from each pair of points in selected UV Set.
  • Added a Diamond Shape to the first UV Coordinate in a UV Set in the UV Editor.

Documentation is complete, waiting a review.

Link to comment
Share on other sites

For those using the previous versions (prior to Extrusion Pro being a GeNa Pro Plugin), you will need to make change(s) to the orientation of textures in a material used as the Extrusion Material.  Also, you can select the Cross Section Asset in Unity, and set the DataVersion to 0, then load the Cross Section into the Cross Section Editor. It will then swap the UV's as (uv.x, uv.y) = (uv.y, 1.0 - uv.x), which essentially rotates the UV clockwise 90 degrees.  Then, rotate the textures clockwise 90 degrees.

This decision was made for better lighting, since most wall textures are made to where the wall is sitting in the texture as you would see it on a wall.  At first, the textures were treated like the road textures, where the V coordinate was generated on the fly per the length of the road.  But, since normal maps don't work well when rotated, Extrusion Pro was changed to generate the U coordinate along the length of the extrusion.

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

I have added a second method for UV creation for horizontal surfaces (top, bottom, ceiling, and floor) to give a better blend and scale match to the incoming extrusions:
image.thumb.png.8fc0fc4665bcbface18887a72cdc5c4b.png

image.thumb.png.f0950fdb908956861b77caa7fd609fea.png

In the above image, a different material is used for the "top" material, which appears to be the floor.

Link to comment
Share on other sites

Due to the changes in the Material Texture orientation, I have added a data version.  If you have already created extrusions with the early access version prior to the v1.0.0 version of Extrusion Pro plugin, you can select the Cross Section asset and set it's data version to 0, then open it in the Cross Section Editor. That will swap the UV coordinates, so the you can rotate the textures 90 degress clock-wise (normals may have to be regenerated, but you can test the lighting visually).

Link to comment
Share on other sites

  • Tell a friend

    Love Canopy - Procedural Worlds? Tell a friend!
  • Need help?

    We work with some of the biggest brands in global gaming, automotive, technology, and government to create environments, games, simulations, and product launches for desktop, mobile, and VR.

    Our unique expertise and technology enable us to deliver solutions that look and run better at a fraction of the time and cost of a typical project.

    Check out some of our non-NDA work in the Gallery, and then Contact Us to accelerate your next project!

×
×
  • Create New...