Announcement

Collapse
No announcement yet.

Mass-Loading V-Ray multisubTex plugin

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Mass-Loading V-Ray multisubTex plugin

    To try and shorten the time to this feature, and to collect some feedback, i'm sharing the scripted plugin below.

    *) What it does: It extends the normal vrayMultiSubTex adding a rollout with controls that allow mass-loading of texture maps.
    The buttons allow for the picking of a folder to recursively search into (for all valid image formats), or of files that can be multiple-picked.
    The images are loaded alphabetically, into vrayBitmap loaders.
    It is recommended to prefix image files accordingly to ensure they are loaded with the progressive IDs desired (f.e. 001_myTexture.tx, 002_myNewTexture.tx, and so on), without the need for later reordering.
    It will take care of matching the number of IDs to the number of loaded files.
    Click image for larger version  Name:	3dsmax_3uyFpON7N6.png Views:	0 Size:	103.6 KB ID:	1129352

    *) How to install it: The zip file is named eMST_001.zip. The script needs to sit in the max startup script folder: f.e. "C:\Program Files\Autodesk\3ds Max 2022\scripts".

    *) Where to find it: You'll find it in the *General* section of the texture maps, named "enhancedVrayMultiSubTex" (Because of a limitation in the way texmap plugins work, i cannot have the map show up in the V-Ray category.)
    Click image for larger version  Name:	3dsmax_n091b0CTpo.png Views:	0 Size:	28.7 KB ID:	1129351

    *) What happens if the plugin isn't found: The same as any other missing plugin class: on max file load the missing plugin name is presented in the usual dialog.
    So, the script *needs* to be copied over to all the relevant workstations, like any other plugin would have to.
    I understand this may limit the usefulness of the approach somewhat, but i haven't yet come up with a better solution.

    *) Future Plans: i'm planning on adding also the vraybitmap mass-controls, but that part is still being investigated for possible drawbacks.


    *) Why bother: I could surely do with feedback, in the while, on how this part is working, and what changes would need to happen to make it more useful.
    The final product will still be done by the devs and integrated with the original vrayMultiSubTex, but feedback on this will help speed up that process greatly.


    EDIT: For those preferring to not use the plugin node, i've made a mass loader which creates the multiSubTex anew each time.
    The only difference is that it'll need to put the map in a slot in the material editor.
    The user can pick a specific number between 1 and 24, or let the script put the map in the first non-assigned material slot (if there are none free, it'll put the texture in slot 1.)
    I have updated the script (not the map plugin) to optionally add a shared UVW randomizer to the loaded maps.
    The zip file is named MST_ML_002.zip, the script needs to just be run.

    Click image for larger version  Name:	ui.png Views:	264 Size:	6.7 KB ID:	1129582
    Attached Files
    Last edited by ^Lele^; 03-05-2022, 10:35 AM.
    Lele
    Trouble Stirrer in RnD @ Chaos
    ----------------------
    emanuele.lecchi@chaos.com

    Disclaimer:
    The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

  • #2
    Very convenient. Thank you!

    OakCorp Japan - Yuji Yamauchi
    oakcorp.net
    v-ray.jp

    Comment


    • #3
      Thanks for this Lele - very much appreciated.

      How are you proposing to handle missing DLLs when the script is ultimately removed, either purposefully or when moving to a new version of 3ds max?
      Set V-Ray class properties en masse with the VMC script
      Follow me for script updates: @ollyspolys

      Comment


      • #4
        Originally posted by olly View Post
        Thanks for this Lele - very much appreciated.

        How are you proposing to handle missing DLLs when the script is ultimately removed, either purposefully or when moving to a new version of 3ds max?
        This has been my daily nightmare today.
        I had started this utterly convinced the plugin would behave like these did, transparently.
        It turns out i presumed wrong, and in my book that limits the usefulness of the approach big time: it's better to handle this entirely differently: a procedure which creates a new multisubtex in some material slot.

        It's the safest, i think, way forward for now.
        But ofc, this would also complicate matters for the vraybitmap override: i can make a script to pick a multisubtex and edit the vraybitmaps from the UI, if i don't go the way of a plugin.

        I could also create an mzp to help with installing it, but then i'm not sure copying a single file over to network locations isn't simpler than opening max on each node, and dragging and dropping an MZP package in the UI.

        I'm all ear for ideas, knowing they are temporary, and that they are supposed to help, not hinder, workflow. (woe me, woe me.)
        Last edited by ^Lele^; 05-11-2021, 03:40 AM.
        Lele
        Trouble Stirrer in RnD @ Chaos
        ----------------------
        emanuele.lecchi@chaos.com

        Disclaimer:
        The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

        Comment


        • #5
          This is cool, and I may well use it as I don't work with a render farm, but if anyone wants to go down the scripting route this works ok.

          http://www.scriptspot.com/3ds-max/sc...isubtex-loader

          Comment


          • #6
            Never knew, but should have known, that joconnell had been here before to steal the thunder.
            Lele
            Trouble Stirrer in RnD @ Chaos
            ----------------------
            emanuele.lecchi@chaos.com

            Disclaimer:
            The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

            Comment


            • #7
              Your stuff is always waaaaaaaaaaaay more solid

              Comment


              • #8
                The liar you are! ^^
                Lele
                Trouble Stirrer in RnD @ Chaos
                ----------------------
                emanuele.lecchi@chaos.com

                Disclaimer:
                The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

                Comment


                • #9
                  I have updated the script (not the map plugin) to optionally add a shared UVW randomizer to the loaded maps.
                  The new zip file (MST_ML_002.zip) is attached to the top post.
                  Lele
                  Trouble Stirrer in RnD @ Chaos
                  ----------------------
                  emanuele.lecchi@chaos.com

                  Disclaimer:
                  The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

                  Comment


                  • #10
                    Please introduce this into an official release. It is much easier.
                    https://www.behance.net/Oliver_Kossatz

                    Comment


                    • #11
                      Working on it.
                      Lele
                      Trouble Stirrer in RnD @ Chaos
                      ----------------------
                      emanuele.lecchi@chaos.com

                      Disclaimer:
                      The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

                      Comment


                      • #12
                        When running the script I'm getting:

                        ---------------------------
                        MAXScript FileIn Exception
                        ---------------------------
                        -- Syntax error: at =, expected name
                        -- In line: uvwSource = u
                        -- File name: C:\​Program Files\​Autodesk\​3ds Max 2022\​scripts\​MST_ML_002.ms
                        -- Line number: 218
                        ---------------------------
                        OK
                        ---------------------------


                        Edit nevermind I can see the batch load function is in MultiSubTex from now on. My mistake.
                        Last edited by Vizioen; 01-12-2022, 04:45 AM.
                        A.

                        ---------------------
                        www.digitaltwins.be

                        Comment


                        • #13
                          Why not use the embedded loader?
                          EDIT: cross-posted.
                          Lele
                          Trouble Stirrer in RnD @ Chaos
                          ----------------------
                          emanuele.lecchi@chaos.com

                          Disclaimer:
                          The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

                          Comment

                          Working...
                          X