Fabric for 3ds Max beta (April 25 2016)

borjaborja Administrator, Fabric Employee Posts: 480 admin
edited October 2016 in Fabric for 3ds Max

We are pleased to announce that the closed beta of Fabric for 3ds Max is ready for testing!

If you find any bug, please file them by sending an email to bugs@fabricengine.com so we can track them properly. Feel free to discuss them here too!.

We are looking for feedback that will help us determine whether this integration is ready for a wider, open Beta.

Download

Download the Fabric Engine archive, built against the latest Fabric 2.2.0-dev daily build:

What's New:

April 25 2016:

  • FABMAX-9 DFG Port sliders only update when clicking out
  • FABMAX-38 CreateValue: 'EvalContext': type not registered when loading certain scenes with Fabric transforms
  • FABMAX-4 Changing parameter types will always delete stored data, even if it is compatible
  • FABMAX-13 Missing Vec2 representation in the value editors
  • FABMAX-22 Exposed in Array ports
  • FABMAX-14 Missing Color representation in the value editors
  • FABMAX-41 ERROR__No_Owner on custom attributes
  • FABMAX-35 Docking the canvas graph breaks the layout
  • FABMAX-29 Exposed port attributes don't inherit the port value
  • FABMAX-33 Outputing an invalid PolygonMesh (like null) to the outputValue of the Fabric Modifier crashes 3ds Max
  • FABMAX-28 Once a port is exposed, the value range can't be edited anymore
  • FABMAX-36 Remove Load Preset from Fabric Menu
  • FABMAX-37 Fabric Menu shouldn't fail when Fabric is not loaded
  • FABMAX-46 If first port is boolean, then it is impossible to click on it
  • FABMAX-48 Crash adding a Fabric Modifier to a Editable Poly
  • FABMAX-18 Once the outputValue of a FabMesh is disconnected, it should clean the mesh in the scene

Installation Instructions

Fabric for 3ds Max is supported in Autodesk 3ds Max 2014, 2015 and 2016.

Extract the package in the folder of your convenience.

Fabric for 3ds Max can be found in the DCCIntegrations folder and it expects certain environment variables to be set. To simplify the process, a batch file is included in each Fabric3dsmax* folder. Running the batch file should set-up the plugin and launch 3ds Max.

Please check the video fabric_for_3dsmax_run.mp4 video included in this message for a more detailed description of the steps required.

Fabric for 3ds Max comes with three main nodes: a Geometry node (Fabric Mesh), a deformer modifier (Fabric Modifier and Fabric WSModifier) and a transform controller (Fabric Transform).

The Fabric Mesh has a predefined PolygonMesh outputValue out port where the geometry computations should go.

The Fabric Modifier has a predefined PolygonMesh baseMesh in port and its World Space counterpart a Mat44 baseMeshTransform in port as well. Similar to the Fabric Mesh it also has a PolygonMesh outputValue out port where the output of the deformation should go.

Finally, the Fabric Transform has a Mat44 parentValue in port to take into account the parent Matrix of the object (if there is a hierarchy) and outputs a Mat44 outputValue.

Other than these, Fabric for 3ds Max also has a Rotation Controller, Position Controller, Float Controller, and FabricReferenceTarget (a generic container that has no "out-port" and is not directly linked to the 3ds Max scene graph, useful if you have a group of Fabric graphs dependent on a central entity).

It is convenient not to remove/rename this predefined ports.

Documentation

Please refer to the samples included in the Samples\Fabric3dsMax folder to learn from how each works.

While there is nothing specific to this integration, don't forget about the online documentation for Canvas which you can find here: http://docs.fabric-engine.com/FabricEngine/latest/HTML/CanvasUserGuide/index.html#canvasuserguide

Current/known limitations:

Since Fabric Engine's Inline Drawing only works with OpenGL, the batch file that does the setup and launches 3ds Max will automatically select OpenGL as a driver. If your graphic card doesn't fully support OpenGL (i.e. you see glitches when manipulating geometry in the viewport) go to Customize/Preferences/Viewports and try disabling the OpenGl optimizations as illustrated in the following picture

You can safely run Nitrous with Fabric as long as you don't need the inline drawing capabilities of Fabric. We have also found that OpenGL drivers can make the file dialog to lag some seconds every time you access it.

If the mouse has focus on the Canvas graph editor, 3ds Max shortcuts (such as Undo/Redo) won't work. As soon as you put the focus in any 3ds Max viewport they will work again.

Exposed port attributes don't inherit the port value.

Exposed in Array ports are only supported via Maxscript

Quick Tips:

Fabric for 3ds Max has full maxscript support. Enable the macrorecorder to check the actions generated. Check this sample script

    sm = FabricMesh pos:[-27.1141,-29.5166,0] isSelected:on
    sm.ShowDFGGraphEditor()

    epm = $.DFGInstPreset "Fabric.Exts.Geometry.PolygonMesh.EmptyPolygonMesh" [212.000000,39.000000]  execPath:""

    code =  "dfgEntry {
      // result = a + b;
    }"
    func = $.DFGAddFunc "func" code [412,167] execPath:""
    code_ = $.GetExecCode func

    $.DFGAddPort "inVal" 0 "$TYPE$" portToConnect:"" extDep:"" execPath:func

    code = "dfgEntry {
      report(inVal);
    }"

    $.DFGSetCode code execPath:func
    $.DFGConnect (epm + ".mesh") (func + ".inVal")  execPath:""

You can get/set port values directly in Maxscript, who handles conversions for you, so you can get/set anything via Maxscript that can be get/set in any other way (math classes, polymeshes, etc).

For exposed ports, in the EditPort dialog, you can set a 3ds max type equivalent for your port value. For example, if your input is a Mat44, you can set the input to either be Matrix3 (with no UI) or MaxNode. For example, with MaxNode, you can hook a node directly into that port to set it's transform. See the dna_helix_3dsmax_type.max sample that makes use of this functionality.

Borja Morales
Technical Product Manager
Fabric Software Inc.

Comments

This discussion has been closed.