User Tools

Site Tools


keckcaves:wand_button_assignment_fragment

Here is an example of a fragment for VruiConfig that pre-assigns tools to buttons on the wand.

VruiConfigurationFragmentType Tool

section Vrui
    section "*"
        tools VruiConfigTools

    	section VruiConfigTools
            toolClassNames (WandNavigationTool, ValuatorFlyTurnNavigationTool, RayMenuTool, MeasurementTool)
            toolNames      (WandNavTool1, WandNavTool2, WandMenuTool, WandMeasurementTool)

			section WandNavTool1
				toolClass WandNavigationTool
				deviceName0 Wand
				device0ButtonIndex0 0
				device0ButtonIndex1 1
			endsection
			
			section WandNavTool2
				toolClass ValuatorFlyTurnNavigationTool
				deviceName0 Wand
				device0ValuatorIndex0 1
				device0ValuatorIndex1 0
			endsection
			
			section WandMenuTool
				toolClass RayMenuTool
				deviceName0 Wand
				device0ButtonIndex0 3
			endsection
			
			section WandMeasurementTool
				toolClass MeasurementTool
				deviceName0 Wand
				device0ButtonIndex0 4
			endsection
			
		endsection
    endsection
endsection

The button numbers for device0ButtonIndex0 may be: yellow = 0, red = 1, green = 2, blue = 3, the trigger = 4. device0ValuatorIndex0 and device0ValuatorIndex1 refer to the joy stick.

keckcaves/wand_button_assignment_fragment.txt · Last modified: 2009/07/01 09:49 by sumner