Home Technical Talk

3ds Max: Texture Atlas with repeatables

ColMatrix
polycounter lvl 2
Online / Send Message
ColMatrix polycounter lvl 2
Hello Everyone,

I require assistance, I have spent at least 8 hours reading articles, watching videos, scoured the Texture Atlas articles on polycount and tested...nothing.

I wish to have a texture Atlas containing repeatable textures. I understand the principle, but I am unsure how to implement it. The methos is as follows:

UV Map Channel 1: the selected objects UV islands are placed in the correct space on the Atlas texture.
UV Map Channel 2: The UV islands are scaled to achieve the required result, saving texture space.

How on earth can one achieve this result in 3ds Max and setup a shader to view the results without working blind, whilst reducing bleeding from neighbouring pixels.

This is for a VR Project within Unity. 

I have 3ds Max, Substance Painter and Photoshop at my disposal. 

All answers are welcome. 

Thanks



Replies

  • Eric Chadwick
    Options
    Online / Send Message
    One way I’ve done this is to use a single uv in atlas layout. 

    Ambient occlusion texture uses this layout, no tiling.

    Diffuse and normal map are tiled, and are using same layout except each bitmap has Tiling values so they are scaled within the atlas.

    One uv, but use tiling values in the individual bitmaps to tile them.

    example: https://ericchadwick.com/img/ecommerce.html#GlamVelvetSofa
  • ColMatrix
    Options
    Online / Send Message
    ColMatrix polycounter lvl 2
    Hi Eric,

    Thank you for taking the time to respond. I will try opening the gTifs in work on monday to see the UV's in 3ds Max. 

    I think, this is similar to what I am supposed to do...except I am to have one texture Atlas containing repeatable and non-repeatable textures. 

    The first UV channel is to place the islands over the specific texture space in the Atlas - for example a repeatable stone texture - standard procedure.
    The second UV channel is to specify the scale for the same islands on the stone texture - to ensure a good texel density. Unity only uses this map channel for scaling purposes, no maps information will be used.

    Other than the obvious reason, of reducing textures and draw calls, our goal, is to be able to add assets at any time without requiring Unity developers to manually add and setup new assets. This requires that all scaling/tiling of all materials stays within the expected parameters. Therefore this needs to be controlled/setup through the scaling of the UV's.

    Setting up the UV channels is not an issue - my issue is setting up the shader within 3ds Max, to achieve an accurate representation so I can see the result of the UV island scaling, without this am blind. The latest, I have been experimenting (unsuccessfully) with OSL in the material slate editor. 

    Any suggesttions?

    Oh and Eric, those assets in your link are gorgeous!!! Will be studying them once am through this shit storm.

    Thanks!
  • Eric Chadwick
    Options
    Online / Send Message
    Here's a demo to get you started, it's a Max 2024 file.

    You just need a shader in Unity that supports per-texture scaling, so you can scale (tile) only the normal map and not the occlusion. I think the Standard Shader does allow this.

    With the viewport set to High Quality, you'll see the untiled occlusion and tiled bump. I disabled the dynamic Ambient Occlusion here, so you can see only the AO texture.


    If you set the viewport to Active Shade it will be slower, but you'll get to use effects like Sheen to create fabrics like velvet. In Unity I think you have to build your own shader to do stuff like Sheen, Clearcoat, Anisotropy, etc.

  • Eric Chadwick
    Options
    Online / Send Message
    That is using the glTF Material in 3ds Max, but if you have a custom Unity shader you can replicate it in 3ds Max using the node based shader editor Shader FX which creates a shader that works in the Max viewport. 

  • ColMatrix
    Options
    Online / Send Message
    ColMatrix polycounter lvl 2
    Hi Eric, thanks for the help and willing to share your data! I will check out the 2024 file as soon as I have the trial installed!

    As for ShaderFX, currently starting to check out the Max help on the subject. Is there a big difference between OSL and ShaderFX? 
    And can you recommend a good place for tutorials and guidance on the subject? I have come accross an issue already following the Max help ShaderFX Intro Sample Workflow:
    https://help.autodesk.com/view/3DSMAX/2022/ENU/?guid=GUID-32B0ECB1-F1F7-4DB6-9B8E-27DCC9D54BF0

    Thanks
  • Eric Chadwick
    Options
    Online / Send Message
    I remember having to search the internets quite a bit to find solutions, but also just doing a lot of tinkering to get past roadblocks.

    It can also help sometimes to post your progress here for assistance.
  • Eric Chadwick
    Options
    Online / Send Message

    OSL is a shading language, while Shader FX is a node based shader editor. 

    AFAIK there isn’t a node based editor for OSL. 
    Shader FX can save out a couple different shader languages I think, check the help. The shaders you create with it are only for real-time rendering, they won’t work if you hit the Render button.

    OSL works with offline rendering, but is not specifically for realtime rendering. Although 3ds Max has pretty good support for previewing it in the viewport.
Sign In or Register to comment.