Perfect Tile System - Do you guys want this for the Marketplace?

I need textures that fit a zoomed out look you get when looking at a tile(regular hexagon) in a civilization game. Grasslands, deserts, forests, mountains, etc. Also need the tiles UV’d for hexagons and to look smooth and continuous when placed next to each other.

I haven’t really nailed down an art style yet and may not for a good long time, but if I saw something reasonable on the marketplace I would probably pick it up just for prototyping uses. :slight_smile:

If you feel like making the assets PM me and I can try to come up with a more comprehensive list. You can create a separate UV that can be applied separately inside the material editor right? I wouldn’t want you to spend too much time creating textures that are aligned to hexes and then have me be the only person buying the asset. :stuck_out_tongue:

Zestiak - It is possible to map textures on meshes without any UVs at all, just through world space in the material. The benefit is it tiles seamlessly across all pieces, but the texture is not mapped to any one object at all. I could make a variant of this system for such a project, but it would require a shader more specific to your needs. This tile system is just my side project, but it’s eating up all my time!

That being said, I did make hexagonal presets using this system. Unfortunately, they are not as well optimized as the more gridded presets, and it requires a special procedure to make assets, but it does work. The following example is unfinished and contains errors:

ab28385edb7bd1f8192e8a8dc72440c88bcd0475.jpeg

Huh, you mean one material that covers my entire map and tiles each as I specify in blueprint?

Looks pretty neat! I’d love to try it out just to play around with what you can do. Too bad there’s not an “Auto Arrange” button for those material nodes, heh.

Zeustiak - Yes. You can move meshes around, and the material can planar map textures from the top down.

Thokash - Sigh, I know. But I love working with materials and figuring this stuff out, so it really doesn’t bother me. It’s just the spider web of options that gets out of hand! You can spend days just messing with the options, colors, and different looks to see what’s possible by playing with it, but if you have a goal in mind, it really shouldn’t take more than a few minutes to import your assets and set it up.

That sounds pretty sweet. All the textures would be in one material and the whole thing would only have 1 draw call, which could then be instanced? Would that also work for non-flat hexagons that have hill and mountain shapes?

One suggestion, try to split that material into modular functions (if possible).
It would have more uses that way, for eg if i do not need “Bricks” i could just remove that block from material etc.
Or if i need only hex i could just leave this patter generating function and remove everything else.

Zeustiak - What I was thinking is to have separate materials, and maybe use one blend as a special effect if you ever need to change the material on one hexagon, but keep the game running on one material per object. Draw calls are much better to deal with performance-wise then layered materials, and the end result is the same, if you just want one particular shader for each hexagon. The benefit to a top-down planar map is you completely remove the necessity to make the assets tileable at odd angles, and just set whatever resolution you want for the texture at large. It works best on flat surfaces, but suffers on deep cliffs in the geometry.

Nawrot - It would definitely be possible to set up this system as a layered material and keep its instancing, but I’m sure you know those can get quite expensive. It’s already using layers just by itself to achieve the never-tiling look, so setting it up to have even more layers on top of that will definitely hurt the performance dramatically. But, hey, we live in a parallax occluded world, and we are also the master race, so, I’ll see what I can do! But if I can’t finish this soon, I’d much rather get this material into other people’s hands than to wait for a complete rewiring into a material function. That can be saved for version 1.1 :slight_smile:

Also, just to clarify, this system is pseudo-procedural, not actually procedural. Nothing is really “generated,” it is just a smart tiling of high-quality assets, like the hexagon mask, with high-density texture maps (TMs) that mimics the effect of procedural generation with more practical techniques. It’s the same concept as using detail textures, but taken to the utmost extreme where two pixels on the low detail map is all you need to generate variation for a single brick. A 2k Tile Map (just a texture) can supply the variation necessary for a million bricks. This is an important distinction to make because artists have control of everything in the finished product, and it’s all done in realtime. There is no special coding required to get a new generator: just make a new TM. Whether you use a noise generator in Photoshop or you paint pixels by hand, the end result is 100% defined by the artist, and it’s extremely simple in concept and execution.

I won’t need any cliff formations, just mountain/hill formations that should have all of their surface facing the sky.

So I could use data from a few arrays in blueprint and drive what texture gets mapped to whichever hexagon?

If you get a fully working hexagon tiler I would love to test it out. :slight_smile:

By modularity i did not mean layers, and making it more complicated. What i meant is making as many parts of graph as possible into independent functions. This way your “final” graph would be much smaller, calling functions only, with good design and some description those functions could be used by buyers in their own more specialized shaders. This would raise usefulness of project.

Zeustiak - No. If you want to use separate hexagon parts, you can use a shader that tiles seamlessly across all the hexagons, so no matter where the hexagon is in space, it tiles appropriately. If you want actual mountains and hills and the ability to change the surface of just a hexagon portion on that mountain or hill, you’d probably need some specialized code to separate the individual hexagons, and then blend between the layers of a layered material setup. I know UE3 landscape had interesting techniques to lessen the impact of multiple layers, but I’m not sure if that kind of efficiency works in realtime.

Nawrot - Ah, yes, I see. There’s really not much that’s special in here, except the glass, scattering, falloff blending, and dual algorithms: those arrangements are pretty cool, but also useless on their own. I can definitely make those pieces modular functions, it’s easy, but it would also be quite useless: it’s only when you combine these features together in the right way that you get an appreciable result. And because of how complicated it is to combine all these different functions together, it just makes a lot more sense to have it all in one system. For instance, the glass scattering by itself will just lower the Mip level of a texture. It will make your texture blurrier. That’s not cool. Make it blurrier via a texture-defined scatter map, slightly more cool. Make it blurrier via texture map and combine it with translucency, then you simulate the effect of frosted and smooth glass over a textured backdrop and cut out the grout from the glass equations, and that’s when it finally looks interesting. I’ll see if I can turn some of my stuff into functions for you, but I will say, they most likely really won’t be very useful on their own.

OK, more updates!:

I turned my advanced image adjustment features into a material function so you guys can use it in any material you want to adjust contrast, color, saturation, and hue in textures. You can even turn off features you don’t want to use in the function, so it is optimized for games! Pretty useful tool if you ask me.

I also rearranged and rewired the texture mapping and roughness nodes because they weren’t set up properly. Now the order is correct and should function as intended. The guide is almost fully complete. I wrote a ton of notes for optimizations and best practices if you want to make your own assets from scratch.

And here’s another Hexagon preset for you guys! This one’s titled “New Earth:”

Did you ever finish the guide? I would be interested to take a look at it! :slight_smile:

OK, sorry for the lack of updates. I just rewrote the entire texturing and roughness systems to be more procedural. In the past, a direct branching system was used, and it was causing major problems with accuracy. The end result won’t look any different for you folks, but it will make future upgrades to this system much easier to handle, and it will always be correct. I’m also taking advantage of shared texture nodes in UE4.6 to save on the cost of using many texture samplers. Be warned, however, that any game releases to Open GL, tile maps, metallic maps, glass maps, and scattering maps cannot be shared, so depending on which features you wish to use, there will be required samplers. I also put in a basic clear coat setting if you like to use it.

I was also in the process of finalizing my assets. I found a method to get hexagonal tile maps with a much cleaner result, but unfortunately there’s still a lot of individual hand-painting the some several hundred thousand pixels. The end result - no pixel bleeding.

I will make updates to this system as time goes on. I would like to implement a dual-texturing solution, a clear-coat map, I’d like to fix an issue where falloff blending will blend metallic colors into the grout, and there are some errors with different areas of different assets, but that can be fixed in due time. I’m working very hard to get everything finished. The guide is complete, but I will need to review the samples once again to make sure nothing is broken or out of place. Thank you for your patience!

OK, everything is almost production-ready. New feature: Dual Texture! You can specify two different textures to be split between all the tiles in a manner similar to dual color, but you can also put the texture just on Tile A, just on Tile B, and take advantage of the solid tile rendering/colors as well! I’m going to go ahead and release the guide ahead of schedule so you guys can take a look at how this system works and read a bit into it. The guide is VERY descriptive on how to make your own pseudo-procedural materials.

https://www.dropbox.com/s/qm3w20eg9vm61nd/perfect_tile_guide.pdf?dl=0

52 presets. Wow. I will admit a couple of them are not my favorites, but making so many of them was intense. With any luck, everything should be completely 100% finished by Monday, and submitted to Epic for review by then. I’m not sure how long it will take to put up on the Marketplace, but if you guys want it, please vote for me! Let’s make this happen!

OK, after putting reflections in the environment, a lot of the colors on metallic surfaces got pretty messed up. Metals render the way they’re supposed to now, with actual reflections from the environment, supported by skylight reflections. Here is a production-ready metallic preset prepped for final lighting:

9099a5721b65a97cbcf990b6e70cb9e830507372.jpeg

OK, you guys will like this feature: I rewrote the dual color algorithm to allow you to set the midpoint: it will automatically shift the values on both ends to whatever midpoint you set. It only costs one extra instruction for all this flexibility. There’s even a feature to animate this. I also finished the debug features. You will be able to visualize the different maps that overlay each other when working with complex glass/scattering/metallic materials. I also managed to save a few instructions for materials using a metal map and included more parameters for greater flexibility while doing all this.

Unfortunately, there are a few known bugs and limitations with the system in its current state:

1 - Textures and Glass features combined are currently untested: may be unstable (medium priority)
2 - “Lerp” functions should be replaced with “If” functions/parameters and be tested for optimum performance (medium priority)
3 - Debug scattering map checkerboard pattern blows out colors and does not cancel out wrong parameters (low priority)
4 - Dual tile implementation is very broad, but not universal, and more can be done with it (low priority)
5 - Clear Coat implementation is very basic at the moment (low priority)
6 - Roughness implementation is good, but more could be done with it (low priority)
7 - Specularity currently has no implementation. This saves on instructions, but more can be done (low priority)
8 - AO implementation is OK for its purpose, but it’s pretty basic at the moment (low priority)

It’s taking a lot longer than I realized to get everything finished. I also want to demonstrate these shaders in a video before my final submission to Epic. Would you guys like me to release this system right now and make these adjustments in the future?

Looking good.

After spending some time in the material editor getting projection to work, I have a new found appreciation for materials. I may have to give your system a shot when you release it just to see if I can make it work for my map. :slight_smile:

Materials are awesome!

Just recently, I tried implementing a code for parallax occlusion mapping from Ehamloptiran in this thread: https://forums.unrealengine.com/showthread.php?49169-POM-material. There are some big issues with it (grout doesn’t work, silhouette clipping doesn’t work, tiling issues with multiple textures, etc), but I’m glad it’s integrated with the system at all. I’ve spent a few days trying to integrate it properly, and it’s still not finished… but if it works, it will basically be the single greatest realtime solution for rendering bricks. Stay tuned!

&d=1423597337

Alright, got the Parallax Occlusion to work with grout! The Perfect Tile System now supports Parallax Occlusion!