So, I tried having the names the same and the setup still did not mirror. The deformation setup I am using is the one Miquel recently did, adding a Blended Joint and a Support Joint to get elbow deformations. Seems like the system doesn’t recognize the broken hierarchy when creating blended joints and support joints. How can I send you a scene file? Thanks
@mberrouet I am afraid that the mirror doesn’t work yet on joints.
If you need to use mirror, just use control_01 for your gimmick joints. After you can hide the controls shapes. So the animator don’t animate it.
Appreciate the tip thanks, Miquel
I got this error when using the rbf mirror setup.
// mGear.flex : Adding isCtl attribute on control_R0_driven // // mGear.flex : Adding uiHost attribute on control_R0_driven // // Error: root : Uncaught exception Traceback (most recent call last): File "C:\Users\Administrator\Documents\maya\scripts\mgear_3.4.0\scripts\mgear\rigbits\rbf_manager_ui.py", line 1513, in mirrorSetup dstValues)) File "C:\Users\Administrator\Documents\maya\scripts\mgear_3.4.0\scripts\mgear\core\anim_utils.py", line 1085, in calculateMirrorData "val": srcNode.attr(attrName).get() * inv}) TypeError: unsupported operand type(s) for *: 'NoneType' and 'int' //
Check the driven controls after an error occurs and find that the “.RBF_Multiplier” property value is 0, and setting the “.RBF_Multiplier” property to 1 will work fine
I tested the biped guide provided by mgear and the guide defined by myself, both have this error.
Tested on mGear 3.4.0, Maya 2018.4.
I did not find related problems and solutions after searching the relevant rbf feedback on the forum.
And as you have found the mirror is set correctly but only the RBF_multiplier property is left to 0
I seem to have resolved the error, I queried the ‘isCtl’ and ‘uiHost’ attributes in the return value of the res in the listAttrForMirror function in anim_utils.py.
I simply added two lines of code, saved and tested the rig asset with errors before, and it successfully mirrored.
Thanks @fury_Night I will check your solution ASAP
hi! following this issue symmetry related…
I can’t figure out how to get a perfect symmetry from L to R side.
As you can see in the image, the initial bone position changes when importing the RBF, just after building rig. The behaviour is the one expected, but can’t keep the original position. .
Setting mirror to any of those setups gets the influence value to 0 as described…but when setting the attribute to 1 the control/bone is pushed to the non default position.
Is it something im doing wrong? i have the Mirror behaviour set in control01 setting.
Any help is really appreciated, this is stopping me using the stunning help of RBF for solving all this extra deformation controls.
The mirror mechanics works like in synoptic mirror. It is using the mirror configuration in the controls
Sometimes depending of your setting, you have to adjust this options. Remember to do it in both sides. To check that if is working use the synoptic, anim_picker or the new right click context menu, l before doing the RBF
I hope this helps.
Hi Miquel! Gracias!
But mirroring works perfectly fine in synoptic, all axis are getting mirrored fine but still losing the position when creating the mirror setup. 8-(
In the dropbox link, I’ve included a brand new built rig, rbf imported (left side only)…all working fine.
If you don’t mind, can you try it out, setting the mirror of any of the three setups for the skirt?
This is happening in every single setup I’m doing, not only in this particular rig.
just ran in the same problem. @fury_Night 's fix worked for me, thanks!
I have tried to download the file but dropbox said that file s uploading
oh no!! The link is alive and working fine though!
Cool, but did fix the influence set to 1 issue or the position of the bones changing when mirroring?
google drive link
the set to 1 issue, havent had problems with mirroring so far.
I’m facing the same issues - could you please help me how to setup RBF so that’s mirroring correctly?
In the main rig, I’ve started using blended joints as a base - I know that’s not mirroring by default - so my first question is If there is any easy way that I could force RBF Manager to mirror those?
- I’ve tried to add mirror attributes, but that’s not solving the issue
for obj in objs:
attribute.add_mirror_config_channels(obj, conf=[1, 1, 1, 0, 0, 0, 0, 0, 0])
attribute.addAttribute(ctl, “isCtl”, “bool”, keyable=False)
# Traceback (most recent call last): # File "D:\Dropbox (Siekiera)\maya_scripts\mgear\latest\scripts\mgear\rigbits\rbf_manager_ui.py", line 1497, in mirrorSetup # mirrorWeightInfo = self.gatherMirroredInfo(self.currentRBFSetupNodes) # File "D:\Dropbox (Siekiera)\maya_scripts\mgear\latest\scripts\mgear\rigbits\rbf_manager_ui.py", line 1431, in gatherMirroredInfo # mrDrvnCtl = mString.convertRLName(weightInfo["drivenControlName"]) # File "D:\Dropbox (Siekiera)\maya_scripts\mgear\latest\scripts\mgear\core\string.py", line 74, in convertRLName # reMatch = re.search(rePattern, name) # File "C:\Program Files\Autodesk\Maya2018\bin\python27.zip\re.py", line 146, in search # TypeError: expected string or buffer
If anyone knows how to makes this works I’d appreciate any help!
Secondly, I’ve switched to control01 - just to test if that’s working better, and indeed - mirroring works but not as it should. I’ve checked and my controls are mirroring correctly using right-click menu - but RBF can’t handle that somehow. What I’m doing wrong here?
I’m trying to understand it, so sorry if I’m doing some simple mistakes that I can’t see.
Thanks in advance!
Any chance for support with that one?
Wonder if I should look for another solution or stick with RBF manager
I will post a little update here, just in case someone would be interested too.
Long story short - Thanks to great support from @Rafael it sorted out as a super simple issue - what I was missing is to set mirror attributes on the parent node that the rbf node drives.
Here’s the full message from Rafael:
I figured it out!
I recreated the scene as per your video and then attempted to get the mirroring working. It was very annoying and time consuming(This should be fixed in the future, hopefully).
But the issue seems to be that the invert attrs need to be correctly applied to the controls BEFORE the RBF setups are created.
Here are some images.
The reason for this is that the invert mirror attributes get copied to the parent node that the rbf node drives. Like here.
So if the invert mirror attrs are not filled in, or wrong before the rbf node setup is created, they will continue to be in the mirroring process because the RBF manager factors in the parents invert attrs as well.
This is exciting because I have forgotten all about this when I created this. Wow, it has been a long day trying to figure this out.
I attached a scene with the mirrored behavior, Maya 2020.2. Let me know if this works for you!
Also, if you have existing setups you can just go to the _driven node above it and correctly apply the invert mirror attributes.
I saw in your video that you were scrolling through the entire list of attributes while creating RBF nodes, you can right click to display different types of attrs.
Let me know if you can replicate this behavior or if anything I said was not clear.
Besides that, I was trying to use simple joints instead of the control_01 (I ended up creating control_01(without the shape in PRE script) to keep RBF Manager working correctly).
But here’s the simple script I managed to copy from rigbits.rbf_manager_ui, maybe it would be helpful for someone
from mgear import rigbits import maya.cmds as mc import pymel.core as pm def addRBFToSetup(driverControl, driverNode, drivenNode, setupName, driverAttrs, drivenAttrs, rbfType="weightDriver"): """query the user in case of a new setup or adding additional RBFs to existing. Returns: TYPE: Description """ ### Check function parameters # try: pm.PyNode(driverControl) except pm.MayaNodeError: pm.displayWarning( "Driver control not found") return # try: pm.PyNode(driverNode) except pm.MayaNodeError: pm.displayWarning( "Driver node/joint not found") return if driverNode == "": return # try: pm.PyNode(drivenNode) except pm.MayaNodeError: pm.displayWarning( "Driven node not found") return # if not setupName: pm.displayWarning("Please provide setup name: NAME_R0") return # if not drivenAttrs: drivenAttrs = [ "translateX", "translateY", "translateZ", "rotateX", "rotateY", "rotateZ" ] # if not driverAttrs: driverAttrs = [ "rotateX", "rotateY", "rotateZ" ] ##### for check in driverControl, driverNode, drivenNode, setupName, driverAttrs, drivenAttrs, rbfType: print check # This does prevents a driver to be its own driven if not drivenNode or drivenNode == driverNode: pm.displayWarning("Select Node to be driven!") return drivenNodeType = mc.nodeType(drivenNode) # smart display all when needed if drivenNodeType in ["transform", "joint"]: attrType = "keyable" else: attrType = "all" parentNode = False drivenType = mc.nodeType(drivenNode) if drivenType in ["transform", "joint"]: parentNode = True drivenNode = rigbits.rbf_node.addDrivenGroup(drivenNode) # create RBFNode instance, apply settings rbfNode = rigbits.rbf_manager_ui.sortRBF(drivenNode, rbfType=rbfType) rbfNode.setSetupName(setupName) rbfNode.setDriverControlAttr(driverControl) rbfNode.setDriverNode(driverNode, driverAttrs) defaultVals = rbfNode.setDrivenNode(drivenNode, drivenAttrs, parent=parentNode) rbfNode.applyDefaultPose() return rbfNode def addPose(rbfNode, poseInput, poseValue): if not rbfNode: return driverNode = rbfNode.getDriverNode() driverAttrs = rbfNode.getDriverNodeAttributes() #covert transforms to list: poseValue = [item for sublist in poseValue for item in sublist] rbfNode.addPose(poseInput=poseInput, poseValue=poseValue) return ######################################### ## LOAD THE DATA driverControl = "arm_R0_fk0_ctl" driverNode = "blend_arm_R0_0_jnt" drivenNode = "rbf01_R0_ctl" setupName = "test_R0" driverAttrs = [ "rotateX", "rotateY", "rotateZ" ] drivenAttrs = [ "translateX", "translateY", "translateZ", "rotateX", "rotateY", "rotateZ" ] ## create RBF rbfNode = addRBFToSetup(driverControl, driverNode, drivenNode, setupName, driverAttrs, drivenAttrs) ## addPose addPose(rbfNode, [0.0, 90.0, 0.0], [ [0.0, 10.0, 0.0] , [0.0, 0.0, 0.0]]) addPose(rbfNode, [0.0, -90.0, 0.0], [ [10.0, 0.0, 0.0] , [0.0, 0.0, 0.0]])
Workflow I’m using it in order:
- Manually test joint positions/skinning
- Export RBF settings (Driver transform, Joints transform, Required attrs etc.)
- On build create RBF nodes, add poses
Please be aware that this might need some tests, I’m not checking how it’s related to other RBFs. But it works on a clean scene.
So if anyone would like to use joints it is as simple as that:
- Add mirror attributes to the joint:
attribute.add_mirror_config_channels(obj, conf=[0, 0, 1, 1, 1, 0, 0, 0, 0])
- Rename the joints before RBF creation to match CTLs naming
Mirror works perfect.
Thank you so much!!!