All Classes Files Functions Variables Pages
sphericalJoint.h
Go to the documentation of this file.
1 //
2 // Copyright 2016 Pixar
3 //
4 // Licensed under the Apache License, Version 2.0 (the "Apache License")
5 // with the following modification; you may not use this file except in
6 // compliance with the Apache License and the following modification to it:
7 // Section 6. Trademarks. is deleted and replaced with:
8 //
9 // 6. Trademarks. This License does not grant permission to use the trade
10 // names, trademarks, service marks, or product names of the Licensor
11 // and its affiliates, except as required to comply with Section 4(c) of
12 // the License and to reproduce the content of the NOTICE file.
13 //
14 // You may obtain a copy of the Apache License at
15 //
16 // http://www.apache.org/licenses/LICENSE-2.0
17 //
18 // Unless required by applicable law or agreed to in writing, software
19 // distributed under the Apache License with the above modification is
20 // distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
21 // KIND, either express or implied. See the Apache License for the specific
22 // language governing permissions and limitations under the Apache License.
23 //
24 #ifndef USDPHYSICS_GENERATED_SPHERICALJOINT_H
25 #define USDPHYSICS_GENERATED_SPHERICALJOINT_H
26 
28 
29 #include "pxr/pxr.h"
30 #include "usdPhysics/api.h"
31 #include "usdPhysics/joint.h"
32 #include "pxr/usd/usd/prim.h"
33 #include "pxr/usd/usd/stage.h"
34 #include "usdPhysics/tokens.h"
35 
36 #include "pxr/base/vt/value.h"
37 
38 #include "pxr/base/gf/vec3d.h"
39 #include "pxr/base/gf/vec3f.h"
40 #include "pxr/base/gf/matrix4d.h"
41 
42 #include "pxr/base/tf/token.h"
43 #include "pxr/base/tf/type.h"
44 
45 PXR_NAMESPACE_OPEN_SCOPE
46 
47 class SdfAssetPath;
48 
49 // -------------------------------------------------------------------------- //
50 // PHYSICSSPHERICALJOINT //
51 // -------------------------------------------------------------------------- //
52 
66 {
67 public:
71  static const UsdSchemaType schemaType = UsdSchemaType::ConcreteTyped;
72 
77  explicit UsdPhysicsSphericalJoint(const UsdPrim& prim=UsdPrim())
78  : UsdPhysicsJoint(prim)
79  {
80  }
81 
85  explicit UsdPhysicsSphericalJoint(const UsdSchemaBase& schemaObj)
86  : UsdPhysicsJoint(schemaObj)
87  {
88  }
89 
91  USDPHYSICS_API
92  virtual ~UsdPhysicsSphericalJoint();
93 
97  USDPHYSICS_API
98  static const TfTokenVector &
99  GetSchemaAttributeNames(bool includeInherited=true);
100 
110  USDPHYSICS_API
112  Get(const UsdStagePtr &stage, const SdfPath &path);
113 
136  USDPHYSICS_API
138  Define(const UsdStagePtr &stage, const SdfPath &path);
139 
140 protected:
144  USDPHYSICS_API
145  UsdSchemaType _GetSchemaType() const override;
146 
147 private:
148  // needs to invoke _GetStaticTfType.
149  friend class UsdSchemaRegistry;
150  USDPHYSICS_API
151  static const TfType &_GetStaticTfType();
152 
153  static bool _IsTypedSchema();
154 
155  // override SchemaBase virtuals.
156  USDPHYSICS_API
157  const TfType &_GetTfType() const override;
158 
159 public:
160  // --------------------------------------------------------------------- //
161  // AXIS
162  // --------------------------------------------------------------------- //
172  USDPHYSICS_API
173  UsdAttribute GetAxisAttr() const;
174 
180  USDPHYSICS_API
181  UsdAttribute CreateAxisAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
182 
183 public:
184  // --------------------------------------------------------------------- //
185  // CONEANGLE0LIMIT
186  // --------------------------------------------------------------------- //
196  USDPHYSICS_API
197  UsdAttribute GetConeAngle0LimitAttr() const;
198 
204  USDPHYSICS_API
205  UsdAttribute CreateConeAngle0LimitAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
206 
207 public:
208  // --------------------------------------------------------------------- //
209  // CONEANGLE1LIMIT
210  // --------------------------------------------------------------------- //
220  USDPHYSICS_API
221  UsdAttribute GetConeAngle1LimitAttr() const;
222 
228  USDPHYSICS_API
229  UsdAttribute CreateConeAngle1LimitAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
230 
231 public:
232  // ===================================================================== //
233  // Feel free to add custom code below this line, it will be preserved by
234  // the code generator.
235  //
236  // Just remember to:
237  // - Close the class declaration with };
238  // - Close the namespace with PXR_NAMESPACE_CLOSE_SCOPE
239  // - Close the include guard with #endif
240  // ===================================================================== //
241  // --(BEGIN CUSTOM CODE)--
242 };
243 
244 PXR_NAMESPACE_CLOSE_SCOPE
245 
246 #endif
static USDPHYSICS_API const TfTokenVector & GetSchemaAttributeNames(bool includeInherited=true)
Return a vector of names of all pre-declared attributes for this schema class and all its ancestor cl...
USDPHYSICS_API UsdAttribute CreateAxisAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetAxisAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
A joint constrains the movement of rigid bodies.
Definition: joint.h:62
Predefined spherical joint type (Removes linear degrees of freedom, cone limit may restrict the motio...
USDPHYSICS_API UsdAttribute CreateConeAngle0LimitAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetConeAngle0LimitAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create...
virtual USDPHYSICS_API ~UsdPhysicsSphericalJoint()
Destructor.
USDPHYSICS_API UsdAttribute GetConeAngle0LimitAttr() const
Cone limit from the primary joint axis in the local0 frame toward the next axis.
USDPHYSICS_API UsdSchemaType _GetSchemaType() const override
Returns the type of schema this class belongs to.
USDPHYSICS_API UsdAttribute CreateConeAngle1LimitAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetConeAngle1LimitAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create...
static USDPHYSICS_API UsdPhysicsSphericalJoint Get(const UsdStagePtr &stage, const SdfPath &path)
Return a UsdPhysicsSphericalJoint holding the prim adhering to this schema at path on stage...
UsdPhysicsSphericalJoint(const UsdSchemaBase &schemaObj)
Construct a UsdPhysicsSphericalJoint on the prim held by schemaObj .
UsdPhysicsSphericalJoint(const UsdPrim &prim=UsdPrim())
Construct a UsdPhysicsSphericalJoint on UsdPrim prim .
USDPHYSICS_API UsdAttribute GetConeAngle1LimitAttr() const
Cone limit from the primary joint axis in the local0 frame toward the second to next axis...
static USDPHYSICS_API UsdPhysicsSphericalJoint Define(const UsdStagePtr &stage, const SdfPath &path)
Attempt to ensure a UsdPrim adhering to this schema at path is defined (according to UsdPrim::IsDefin...
USDPHYSICS_API UsdAttribute GetAxisAttr() const
Cone limit axis.
static const UsdSchemaType schemaType
Compile time constant representing what kind of schema this class is.