// synchronized with TransformStructure
  synchronized void setNodeData(SetLiveState s) {
    int i;

    super.setNodeData(s);

    childTrans = new Transform3D[s.currentTransforms.length][2];
    childTransIndex = new int[s.currentTransforms.length][2];

    for (i = 0; i < s.currentTransforms.length; i++) {
      childTrans[i][0] = new Transform3D();

      childTrans[i][0].mul(
          s.currentTransforms[i][s.currentTransformsIndex[i][CURRENT_LOCAL_TO_VWORLD]],
          currentTransform);
      childTrans[i][1] = new Transform3D(childTrans[i][0]);
      childTransIndex[i][0] = 0;
      childTransIndex[i][1] = 0;
    }

    if (!s.inSharedGroup) {
      s.transformLevels[0] += 1;
      maxTransformLevel = s.transformLevels[0];
    } else {
      for (i = 0; i < s.keys.length; i++) {
        s.transformLevels[i] += 1;
        if (s.transformLevels[i] > maxTransformLevel) {
          maxTransformLevel = s.transformLevels[i];
        }
      }
    }

    if (!inSharedGroup) {
      if (childLocalToVworld == null) {
        // If the node is a transformGroup then need to keep
        // the child transforms as well
        childLocalToVworld = new Transform3D[1][];
        childLocalToVworldIndex = new int[1][];
        transformLevels = new int[1];
        // Use by TransformStructure
        cachedTargets = new CachedTargets[1];
        perPathData = new TransformGroupData[1];
      }
      childLocalToVworld[0] = childTrans[0];
      childLocalToVworldIndex[0] = childTransIndex[0];
      transformLevels[0] = s.transformLevels[0];

      setAuxData(s, 0, 0);
    } else {

      // For inSharedGroup case.
      int j, len;

      if (childLocalToVworld == null) {
        childLocalToVworld = new Transform3D[s.keys.length][];
        childLocalToVworldIndex = new int[s.keys.length][];
        transformLevels = new int[s.keys.length];
        cachedTargets = new CachedTargets[s.keys.length];
        perPathData = new TransformGroupData[s.keys.length];
        len = 0;
      } else {

        len = localToVworld.length - s.keys.length;

        int newLen = localToVworld.length;

        Transform3D newChildTList[][] = new Transform3D[newLen][];
        int newChildIndexList[][] = new int[newLen][];
        int newTransformLevels[] = new int[newLen];
        CachedTargets newTargets[] = new CachedTargets[newLen];
        TransformGroupData newPerPathData[] = new TransformGroupData[newLen];

        System.arraycopy(childLocalToVworld, 0, newChildTList, 0, childLocalToVworld.length);
        System.arraycopy(
            childLocalToVworldIndex, 0, newChildIndexList, 0, childLocalToVworldIndex.length);
        System.arraycopy(transformLevels, 0, newTransformLevels, 0, transformLevels.length);

        System.arraycopy(cachedTargets, 0, newTargets, 0, cachedTargets.length);

        System.arraycopy(perPathData, 0, newPerPathData, 0, perPathData.length);

        childLocalToVworld = newChildTList;
        childLocalToVworldIndex = newChildIndexList;
        transformLevels = newTransformLevels;
        cachedTargets = newTargets;
        perPathData = newPerPathData;
      }

      int hkIndex;
      int hkIndexPlus1, blkSize;

      for (i = len, j = 0; i < localToVworld.length; i++, j++) {
        hkIndex = s.keys[j].equals(localToVworldKeys, 0, localToVworldKeys.length);

        if (hkIndex < 0) {
          MasterControl.getCoreLogger().severe("Can't Find matching hashKey in setNodeData.");
          break;
        } else if (hkIndex >= i) { // Append to last.
          childLocalToVworld[i] = childTrans[j];
          childLocalToVworldIndex[i] = childTransIndex[j];
          transformLevels[i] = s.transformLevels[j];
        } else {
          hkIndexPlus1 = hkIndex + 1;
          blkSize = i - hkIndex;

          System.arraycopy(childLocalToVworld, hkIndex, childLocalToVworld, hkIndexPlus1, blkSize);

          System.arraycopy(
              childLocalToVworldIndex, hkIndex, childLocalToVworldIndex, hkIndexPlus1, blkSize);

          System.arraycopy(transformLevels, hkIndex, transformLevels, hkIndexPlus1, blkSize);

          System.arraycopy(cachedTargets, hkIndex, cachedTargets, hkIndexPlus1, blkSize);

          System.arraycopy(perPathData, hkIndex, perPathData, hkIndexPlus1, blkSize);

          childLocalToVworld[hkIndex] = childTrans[j];
          childLocalToVworldIndex[hkIndex] = childTransIndex[j];
          transformLevels[hkIndex] = s.transformLevels[j];
        }

        setAuxData(s, j, hkIndex);
      }
    }
    if (s.childTransformLinks != null) {
      // do not duplicate shared nodes
      synchronized (s.childTransformLinks) {
        if (!inSharedGroup || !s.childTransformLinks.contains(this)) {
          s.childTransformLinks.add(this);
        }
      }
    }

    s.localToVworld = childLocalToVworld;
    s.localToVworldIndex = childLocalToVworldIndex;
    s.currentTransforms = childTrans;
    s.currentTransformsIndex = childTransIndex;

    s.childTransformLinks = childTransformLinks;
    s.parentTransformLink = this;
  }