[Solved]Components not mirroring and error in apply canvas_operator

Hello, I'm actually testing Kraken-1.2 in Maya 2016 on Ubuntu.
I found two problem I was able to solve:
-some components was not symmetrizing properly: Vec3 data was not mirrored in utility_method.py so I changed
if isinstance(jsonData, Vec3): return jsonData
to
if isinstance(jsonData, Vec3): newVec3 = Vec3(jsonData) if plane == 0: newVec3.x = -newVec3.x elif plane == 1: newVec3.y = -newVec3.y elif plane == 2: newVec3.z = -newVec3.z return newVec3

-an error occured when apply canvas_operator because of NULL argument in canvas_operator.py so I changed:
validateArg(rtVal, portName, portDataType) self.binding.setArgValue(portName, rtVal, False)
to
validateArg(rtVal, portName, portDataType) if not rtVal == None: self.binding.setArgValue(portName, rtVal, False)
I was not able to make a pull request on Git, so I post here...
Keep the good work!

Ben

Comments

  • EricTEricT Administrator, Moderator, Fabric Employee Posts: 305 admin

    @benmalartre Thanks for these suggestions. I'll test these out. Was there a particular component that wasn't working for you that you tested these against?

    Eric Thivierge
    Kraken Developer
    Kraken Rigging Framework

  • benmalartrebenmalartre Posts: 16

    for the mirroring problem some generic components are affected(DynamicChain,Tentacle,FKChain)
    for the second problem, components based on CanvasSolver (Hand, Eyelid)

    I'm also trying the framework on Softimage 2015 Windows, and encountering errors building Canvas based Components(Hand, Eyelid)
    KL based components are working fine...

  • EricTEricT Administrator, Moderator, Fabric Employee Posts: 305 admin

    @benmalartre If you can post those Softimage Canvas build errors / build problems to the Github Issues that would be helpful:
    https://github.com/fabric-engine/Kraken/issues

    Eric Thivierge
    Kraken Developer
    Kraken Rigging Framework

  • benmalartrebenmalartre Posts: 16

    After some trial and errors I got it working by modifying slighlty si_plugin/builder.py

    Here are the modification and the complete file
    -line 1111
    si.FabricCanvasSetExtDeps(canvasOpPath, "", kOperator.getExtension())
    to
    si.FabricCanvasSetExtDeps(canvasOpPath, "", "Kraken")
    as CanvasOperator don't have getExtension() function
    solution taken from maya_plugin/builder.py

    -line 1114
    solverNodeName = uniqueNodeName
    to
    solverSolveNodeName = uniqueNodeName
    as the variable solverSolveNodeName was undefined later in the script

    -line 820
    def addPortConnection(canvasOpPath, portName, portDataType, portConnectionType): if portDataType in ('EvalContext', 'DrawingHandle', 'InlineDebugShape'): return
    to
    def addPortConnection(canvasOpPath, portName, portDataType, portConnectionType): if portDataType in ('Execute','EvalContext', 'DrawingHandle', 'InlineDebugShape'): return

    as the script failed Adding Port Connection with "exec" port...

  • EricTEricT Administrator, Moderator, Fabric Employee Posts: 305 admin

    @benmalartre Just wanted to check and see if you tested with the latest develop branch of Kraken? Much of that code you posted looks pretty familiar, in that, it was code that may have been worked on recently.

    Eric Thivierge
    Kraken Developer
    Kraken Rigging Framework

  • benmalartrebenmalartre Posts: 16
    edited November 2016

    I downloaded directly from git-hub, it was named kraken-chagall two days ago
    Anyway, I redownload it and see what's happen :)

    Edit: I dowloaded the Kraken(develop) from the fabric-engine.github.io/Kraken/ page and still get the errors

  • EricTEricT Administrator, Moderator, Fabric Employee Posts: 305 admin

    OK thanks just wanted to double check

    Eric Thivierge
    Kraken Developer
    Kraken Rigging Framework

  • EricTEricT Administrator, Moderator, Fabric Employee Posts: 305 admin

    Thanks again for the fixes. I've pushed them to the develop and chagall branches.

    Eric Thivierge
    Kraken Developer
    Kraken Rigging Framework

  • benmalartrebenmalartre Posts: 16

    Cool , just tested it, all is fine;)
    Found another bug in insectLeg_component.py(error while building guide)
    changed

        jointPositions = self.generateGuidePositions(numJoints)
    
        for i in xrange(numJoints):
            self.jointCtrls.append(Control('leg' + str(i + 1).zfill(2), parent=self.ctrlCmpGrp, shape="sphere"))
    
        data = {
           "location": "L",
           "jointPositions": jointPositions,
           "numJoints": self.numJoints.getValue()
          }
    

    to

        jointPositions = self.generateGuidePositions(numJoints)
    
        for i in xrange(numJoints):
            self.jointCtrls.append(Control('leg' + str(i + 1).zfill(2), parent=self.ctrlCmpGrp, shape="sphere"))
    
        jointXfos = []
        for i in xrange(numJoints):
            jointXfos.append(Xfo(jointPositions[i]))
    
        data = {
           "location": "L",
           "jointPositions": jointXfos,
           "numJoints": self.numJoints.getValue()
          }
    

    as data['jointPositions'] need to be of Xfo Type

Sign In or Register to comment.