MJCF importer not pasring contype/conaffinity values correctly?

Hi,

I’m having trouble getting the contype/conaffinity working properly in Isaac Gym.

I’ve created a minimal MJCF example which reproduces my issue:

<worldbody>
	<body name="root" pos="0 0 0">
		<body name="box1" pos="0 0 0">
			<geom name="box1" type="box" size="0.1 0.1 0.1" contype="1" conaffinity="2"/>
		</body>
		<body name="box2" pos="0 0 0.4">
			<joint type="slide" axis="0 0 1"/>
			<geom name="box2" type="box" size="0.1 0.1 0.1" contype="4" conaffinity="8"/>
		</body>
	</body>
</worldbody>

From Mujoco’s collision documentaion, two geoms will collide if the expression (contype1 & conaffinity2) || (contype2 & conaffinity1) evaluates to true. From the above example, it should evaluate to false since none of the contype and conaffinity from both geoms share a common bit. When I run this in Mujoco, I’m getting the expected behaviour where box2 phases through box1.

However, when I import and run this in Isaac Gym, box2 collides right on top of box1. I’ve made sure to set the collision_filter to -1 when I called gym.create_actor().

Is this a bug or am I misunderstanding how contype/conaffinity work?