# {py:mod}`simvx.core.physics.shapes2d` ```{py:module} simvx.core.physics.shapes2d ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d :allowtitles: ``` ## Module Contents ### Classes ````{list-table} :class: autosummary longtable :align: left * - {py:obj}`Shape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.Shape2D :summary: ``` * - {py:obj}`CircleShape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.CircleShape2D :summary: ``` * - {py:obj}`RectangleShape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.RectangleShape2D :summary: ``` * - {py:obj}`CapsuleShape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.CapsuleShape2D :summary: ``` * - {py:obj}`SegmentShape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.SegmentShape2D :summary: ``` * - {py:obj}`ConvexPolygonShape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.ConvexPolygonShape2D :summary: ``` * - {py:obj}`ConcavePolygonShape2D ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.ConcavePolygonShape2D :summary: ``` ```` ### Data ````{list-table} :class: autosummary longtable :align: left * - {py:obj}`__all__ ` - ```{autodoc2-docstring} simvx.core.physics.shapes2d.__all__ :summary: ``` ```` ### API ````{py:data} __all__ :canonical: simvx.core.physics.shapes2d.__all__ :value: > ['Shape2D', 'CircleShape2D', 'RectangleShape2D', 'CapsuleShape2D', 'SegmentShape2D', 'ConvexPolygonS... ```{autodoc2-docstring} simvx.core.physics.shapes2d.__all__ ``` ```` `````{py:class} Shape2D :canonical: simvx.core.physics.shapes2d.Shape2D Bases: {py:obj}`abc.ABC` ```{autodoc2-docstring} simvx.core.physics.shapes2d.Shape2D ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.Shape2D.build :abstractmethod: ```{autodoc2-docstring} simvx.core.physics.shapes2d.Shape2D.build ``` ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.Shape2D.__slots__ :value: > () ```` ````` `````{py:class} CircleShape2D(radius: float = 0.5) :canonical: simvx.core.physics.shapes2d.CircleShape2D Bases: {py:obj}`simvx.core.physics.shapes2d.Shape2D` ```{autodoc2-docstring} simvx.core.physics.shapes2d.CircleShape2D ``` ```{rubric} Initialization ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d.CircleShape2D.__init__ ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.CircleShape2D.build ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.CircleShape2D.__slots__ :value: > () ```` ````` `````{py:class} RectangleShape2D(half_extents: simvx.core.math.Vec2 | tuple[float, float] = (0.5, 0.5)) :canonical: simvx.core.physics.shapes2d.RectangleShape2D Bases: {py:obj}`simvx.core.physics.shapes2d.Shape2D` ```{autodoc2-docstring} simvx.core.physics.shapes2d.RectangleShape2D ``` ```{rubric} Initialization ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d.RectangleShape2D.__init__ ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.RectangleShape2D.build ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.RectangleShape2D.__slots__ :value: > () ```` ````` `````{py:class} CapsuleShape2D(radius: float = 0.5, height: float = 2.0) :canonical: simvx.core.physics.shapes2d.CapsuleShape2D Bases: {py:obj}`simvx.core.physics.shapes2d.Shape2D` ```{autodoc2-docstring} simvx.core.physics.shapes2d.CapsuleShape2D ``` ```{rubric} Initialization ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d.CapsuleShape2D.__init__ ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.CapsuleShape2D.build ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.CapsuleShape2D.__slots__ :value: > () ```` ````` `````{py:class} SegmentShape2D(a: simvx.core.math.Vec2 | tuple[float, float] = (-0.5, 0.0), b: simvx.core.math.Vec2 | tuple[float, float] = (0.5, 0.0), radius: float = 0.0) :canonical: simvx.core.physics.shapes2d.SegmentShape2D Bases: {py:obj}`simvx.core.physics.shapes2d.Shape2D` ```{autodoc2-docstring} simvx.core.physics.shapes2d.SegmentShape2D ``` ```{rubric} Initialization ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d.SegmentShape2D.__init__ ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.SegmentShape2D.build ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.SegmentShape2D.__slots__ :value: > () ```` ````` `````{py:class} ConvexPolygonShape2D(points: collections.abc.Sequence[simvx.core.math.Vec2 | tuple[float, float]]) :canonical: simvx.core.physics.shapes2d.ConvexPolygonShape2D Bases: {py:obj}`simvx.core.physics.shapes2d.Shape2D` ```{autodoc2-docstring} simvx.core.physics.shapes2d.ConvexPolygonShape2D ``` ```{rubric} Initialization ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d.ConvexPolygonShape2D.__init__ ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.ConvexPolygonShape2D.build ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.ConvexPolygonShape2D.__slots__ :value: > () ```` ````` `````{py:class} ConcavePolygonShape2D(segments: collections.abc.Sequence[object] | numpy.ndarray) :canonical: simvx.core.physics.shapes2d.ConcavePolygonShape2D Bases: {py:obj}`simvx.core.physics.shapes2d.Shape2D` ```{autodoc2-docstring} simvx.core.physics.shapes2d.ConcavePolygonShape2D ``` ```{rubric} Initialization ``` ```{autodoc2-docstring} simvx.core.physics.shapes2d.ConcavePolygonShape2D.__init__ ``` ````{py:method} build(world: simvx.core.physics.world2d.Physics2DWorld) -> simvx.core.physics.world2d.ShapeHandle :canonical: simvx.core.physics.shapes2d.ConcavePolygonShape2D.build ```` ````{py:attribute} __slots__ :canonical: simvx.core.physics.shapes2d.ConcavePolygonShape2D.__slots__ :value: > () ```` `````