1 /******************************************************************************* 2 * Copyright (c) 2013, Daniel Murphy 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without modification, 6 * are permitted provided that the following conditions are met: 7 * * Redistributions of source code must retain the above copyright notice, 8 * this list of conditions and the following disclaimer. 9 * * Redistributions in binary form must reproduce the above copyright notice, 10 * this list of conditions and the following disclaimer in the documentation 11 * and/or other materials provided with the distribution. 12 * 13 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 14 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 15 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 16 * IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 17 * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 18 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 19 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 20 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 21 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 22 * POSSIBILITY OF SUCH DAMAGE. 23 ******************************************************************************/ 24 /** 25 * Created at 5:20:39 AM Jan 22, 2011 26 */ 27 package org.jbox2d.dynamics.joints; 28 29 /** 30 * Gear joint definition. This definition requires two existing revolute or prismatic joints (any 31 * combination will work). The provided joints must attach a dynamic body to a static body. 32 * 33 * @author Daniel Murphy 34 */ 35 public class GearJointDef extends JointDef { 36 /** 37 * The first revolute/prismatic joint attached to the gear joint. 38 */ 39 public Joint joint1; 40 41 /** 42 * The second revolute/prismatic joint attached to the gear joint. 43 */ 44 public Joint joint2; 45 46 /** 47 * Gear ratio. 48 * 49 * @see GearJoint 50 */ 51 public float ratio; 52 53 public GearJointDef() { 54 super(JointType.GEAR); 55 joint1 = null; 56 joint2 = null; 57 } 58 } 59