Class PhysicsSimulator.CppProxy

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void _djinni_private_destroy()  
      protected void finalize()  
      void reset()
      Reset simulator to default state
      void setBonesInMvSpace​(boolean bonesInMvSpace)
      Sets bonesInMvSpace flag false for legacy effects with special vertex shaders true for using same vertex shaders as for non-physics meshes
      void setConstraint​(java.lang.String bone1Name, java.lang.String bone2Name, float distance)
      Add constraint between bone1 and bone2.
      void setDamping​(float damping)
      Sets damping value.
      void setGravity​(Vec3 gravity)
      Sets gravitation vector.
      void setInvMass​(java.lang.String boneName, float value)
      Sets inverse bone mass.
      void setSphereCollider​(int sphereIndex, Vec3 center, float radius)
      Add sphere collider.
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • _djinni_private_destroy

        public void _djinni_private_destroy()
      • finalize

        protected void finalize()
                         throws java.lang.Throwable
        Overrides:
        finalize in class java.lang.Object
        Throws:
        java.lang.Throwable
      • setGravity

        public void setGravity​(Vec3 gravity)
        Description copied from interface: PhysicsSimulator
        Sets gravitation vector.
        Specified by:
        setGravity in interface PhysicsSimulator
        Parameters:
        gravity - (vec3): gravity value
      • setDamping

        public void setDamping​(float damping)
        Description copied from interface: PhysicsSimulator
        Sets damping value.
        Specified by:
        setDamping in interface PhysicsSimulator
        Parameters:
        damping - (float): damping value
      • setInvMass

        public void setInvMass​(java.lang.String boneName,
                               float value)
        Description copied from interface: PhysicsSimulator
        Sets inverse bone mass.
        Specified by:
        setInvMass in interface PhysicsSimulator
        Parameters:
        boneName - (string): bone name
        value - (float): inverse bone mass
      • setSphereCollider

        public void setSphereCollider​(int sphereIndex,
                                      Vec3 center,
                                      float radius)
        Description copied from interface: PhysicsSimulator
        Add sphere collider.
        Specified by:
        setSphereCollider in interface PhysicsSimulator
        Parameters:
        sphereIndex - (int): index for sphere
        center - (vec3): sphere center in world space
        radius - (float): sphere radius
      • setConstraint

        public void setConstraint​(java.lang.String bone1Name,
                                  java.lang.String bone2Name,
                                  float distance)
        Description copied from interface: PhysicsSimulator
        Add constraint between bone1 and bone2.
        Specified by:
        setConstraint in interface PhysicsSimulator
        Parameters:
        bone1Name - (string): from bone name
        bone2Name - (string): to bone name
        distance - (float): constaint length
      • setBonesInMvSpace

        public void setBonesInMvSpace​(boolean bonesInMvSpace)
        Description copied from interface: PhysicsSimulator
        Sets bonesInMvSpace flag false for legacy effects with special vertex shaders true for using same vertex shaders as for non-physics meshes
        Specified by:
        setBonesInMvSpace in interface PhysicsSimulator