Class Shape

    Definition

    Namespace:
    Tizen.NUI.Physics2D.Chipmunk
    Assembly:
    Tizen.NUI.Physics2D.dll

    Abstract Chipmunk Shape

    public abstract class Shape : IDisposable
    Inheritance
    object
    Shape
    Derived
    Box
    Circle
    Polygon
    Segment

    Constructors

    View Source

    Shape(IntPtr)

    Create a Shape with the given shapeHandle.

    Declaration
    protected Shape(System.IntPtr shapeHandle)
    Parameters
    Type Name Description
    System.IntPtr shapeHandle

    The native shape handle.

    Properties

    View Source

    Area

    Get the calculated area of the shape.

    Declaration
    public double Area { get; }
    Property Value
    Type Description
    double
    View Source

    Body

    The body that this shape is associated with.

    Declaration
    public Body Body { get; set; }
    Property Value
    Type Description
    Body
    View Source

    BoundingBox

    Get the bounding box that contains the shape, given it's current position and angle.

    Declaration
    public BoundingBox BoundingBox { get; }
    Property Value
    Type Description
    BoundingBox
    View Source

    CenterOfGravity

    Get the center of gravity of the shape.

    Declaration
    public Vect CenterOfGravity { get; }
    Property Value
    Type Description
    Vect
    View Source

    CollisionType

    An arbitrary value representing the collision type of this shape. Only shapes with like collision types will collide.

    Declaration
    public int CollisionType { get; set; }
    Property Value
    Type Description
    int
    View Source

    Data

    Arbitrary user data.

    Declaration
    public object Data { get; set; }
    Property Value
    Type Description
    object
    View Source

    Density

    Density of the shape if you are having Chipmunk calculate mass properties for you.

    Declaration
    public double Density { get; set; }
    Property Value
    Type Description
    double
    View Source

    Elasticity

    The elasticity of the shape. A value of 0.0 is perfectly inelastic (no bounce). A value of 1.0 is perfectly elastic. Due to simulation inaccuracy, values of 1.0 or greater are not recommended.

    Declaration
    public double Elasticity { get; set; }
    Property Value
    Type Description
    double
    View Source

    Filter

    An arbitrary value representing the collision type of this shape. Only shapes with like collision types will collide.

    Declaration
    public ShapeFilter Filter { get; set; }
    Property Value
    Type Description
    ShapeFilter
    View Source

    Friction

    The friction coefficient, following the Coulomb friction model. A value of 0.0 is frictionless. https://en.wikipedia.org/wiki/Friction#Coefficient_of_friction

    Declaration
    public double Friction { get; set; }
    Property Value
    Type Description
    double
    View Source

    Handle

    The native handle.

    Declaration
    public System.IntPtr Handle { get; }
    Property Value
    Type Description
    System.IntPtr
    View Source

    Mass

    Mass of the shape to have Chipmunk calculate mass properties for you.

    Declaration
    public double Mass { get; set; }
    Property Value
    Type Description
    double
    View Source

    Moment

    Get the calculated moment of inertia for the shape.

    Declaration
    public double Moment { get; }
    Property Value
    Type Description
    double
    View Source

    Sensor

    Whether the shape is a sensor.

    Declaration
    public bool Sensor { get; set; }
    Property Value
    Type Description
    bool
    View Source

    Space

    Gets the space that this shape is registered within.

    Declaration
    public Space Space { get; }
    Property Value
    Type Description
    Space
    View Source

    SurfaceVelocity

    The surface velocity of the object. Useful for creating conveyor belts or players that move around. This value is only used when calculating friction, not resolving the collision.

    Declaration
    public Vect SurfaceVelocity { get; set; }
    Property Value
    Type Description
    Vect

    Methods

    View Source

    CacheBB()

    Update, cache and return the bounding box of a shape based on the body it's attached to.

    Declaration
    public BoundingBox CacheBB()
    Returns
    Type Description
    BoundingBox
    View Source

    Collide(Shape)

    Get the contact information between two shapes.

    Declaration
    public ContactPointSet Collide(Shape other)
    Parameters
    Type Name Description
    Shape other
    Returns
    Type Description
    ContactPointSet
    View Source

    Dispose()

    Destroy and free the shape.

    Declaration
    public void Dispose()
    View Source

    Dispose(bool)

    Dispose the shape.

    Declaration
    protected virtual void Dispose(bool dispose)
    Parameters
    Type Name Description
    bool dispose
    View Source

    Free()

    Destroy and free the shape.

    Declaration
    public void Free()
    View Source

    FromHandle(IntPtr)

    Get a managed Shape from a native handle.

    Declaration
    public static Shape FromHandle(System.IntPtr shape)
    Parameters
    Type Name Description
    System.IntPtr shape
    Returns
    Type Description
    Shape
    View Source

    PointQuery(Vect)

    Finds the point on the surface of the shape which is closest to the given point.

    Declaration
    public PointQueryInfo PointQuery(Vect point)
    Parameters
    Type Name Description
    Vect point
    Returns
    Type Description
    PointQueryInfo
    View Source

    SegmentQuery(Vect, Vect, double)

    Perform a segment query against a shape.

    Declaration
    public SegmentQueryInfo SegmentQuery(Vect a, Vect b, double radius)
    Parameters
    Type Name Description
    Vect a
    Vect b
    double radius
    Returns
    Type Description
    SegmentQueryInfo
    View Source

    Update(Transform)

    Update, cache and return the bounding box of a shape with an explicit transformation.

    Declaration
    public BoundingBox Update(Transform transform)
    Parameters
    Type Name Description
    Transform transform
    Returns
    Type Description
    BoundingBox

    Extension Methods

    EXamlExtensions.LoadFromEXamlByRelativePath<T>(T, string)
    Extensions.LoadFromXaml<TXaml>(TXaml, string)
    Extensions.LoadFromXaml<TXaml>(TXaml, Type)
    Extensions.LoadFromXamlFile<TXaml>(TXaml, string)
    • View Source
    Back to top Copyright © 2016-2025 Samsung
    Generated by DocFX