Point

No example available.

Declaration

class declaracad.occ.geom.Point(x=0, y=0, z=0, **kwargs)[source]

Bases: Atom

Attributes:
proxy
x
y
z

Methods

angle(other)

Returns the angle value between 0 and pi in radians

angle2d(other)

Angle between the x and y components Returns the angle value between 0 and pi in radians

angle_with_ref(other, ref)

Computes the angle, in radians, between this vector and vector ref.

clip(low, high)

Clip to the given range

coordinates_in_range(low, high)

Check if all coordinates are in the given range

freeze

Freeze the atom to prevent further modifications to its attributes.

get_member

Get the named member for the atom.

has_observer

Get whether the atom has the given observer for a given topic.

has_observers

Get whether the atom has observers for a given topic.

members()

Get the members dictionary for the type.

notifications_enabled

Get whether notification is enabled for the atom.

notify

Call the registered observers for a given topic with positional and keyword arguments.

observe

Register an observer callback to observe changes on the given topic(s).

offset(distance, direction)

Create a point offset by distance in the given direction

replace(**kwargs)

Create a copy with the value replaced with the given parameters.

set_notifications_enabled

Enable or disable notifications for the atom.

suppress_notifications()

Disable member notifications within in a context.

unobserve

Unregister an observer callback for the given topic(s).

cross

distance

distance2d

dot

is_equal

magnitude

midpoint

angle(other) float[source]

Returns the angle value between 0 and pi in radians

angle2d(other) float[source]

Angle between the x and y components Returns the angle value between 0 and pi in radians

angle_with_ref(other, ref) float[source]

Computes the angle, in radians, between this vector and vector ref. The result is a value between -pi and pi.

clip(low: float, high: float) Point[source]

Clip to the given range

coordinates_in_range(low: float, high: float) bool[source]

Check if all coordinates are in the given range

offset(distance: float, direction: Direction) Point[source]

Create a point offset by distance in the given direction

Parameters:
distance: float

The offset distance

direction: Union[Tuple[float, …], Direction, gp_Dir]

The direction to offset. Will be coerced

Returns:
p: Point

Point offset from this point

replace(**kwargs) Point[source]

Create a copy with the value replaced with the given parameters.

No implementation found