| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
- //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
- #pragma once
- #include "BsPhysXPrerequisites.h"
- #include "BsSliderJoint.h"
- #include "PxPhysics.h"
- #include "extensions\PxPrismaticJoint.h"
- namespace BansheeEngine
- {
- /** @addtogroup PhysX
- * @{
- */
- /** PhysX implementation of a SliderJoint. */
- class BS_PHYSX_EXPORT PhysXSliderJoint : public SliderJoint
- {
- public:
- PhysXSliderJoint(physx::PxPhysics* physx, const SLIDER_JOINT_DESC& desc);
- ~PhysXSliderJoint();
- /** @copydoc SliderJoint::getPosition */
- float getPosition() const override;
- /** @copydoc SliderJoint::getSpeed */
- float getSpeed() const override;
- /** @copydoc SliderJoint::getLimit */
- LimitLinearRange getLimit() const override;
- /** @copydoc SliderJoint::setLimit */
- void setLimit(const LimitLinearRange& limit) override;
- /** @copydoc SliderJoint::setFlag */
- void setFlag(Flag flag, bool enabled) override;
- /** @copydoc SliderJoint::hasFlag */
- bool hasFlag(Flag flag) const override;
- private:
- /** Returns the internal PhysX representation of the slider (prismatic) joint. */
- inline physx::PxPrismaticJoint* getInternal() const;
- };
- /** @} */
- }
|