graphene.sphere
Module for [Sphere] class
class Sphere
Types 1
classSphere : gobject.boxed.Boxed
A sphere, represented by its center and radius.
Methods
bool containsPoint(graphene.point3_d.Point3D point) nothrowChecks whether the given point is contained in the volume of a #graphene_sphere_t.float distance(graphene.point3_d.Point3D point) nothrowComputes the distance of the given point from the surface of a #graphene_sphere_t.void getBoundingBox(out graphene.box.Box box) nothrowComputes the bounding box capable of containing the given #graphene_sphere_t.void getCenter(out graphene.point3_d.Point3D center) nothrowRetrieves the coordinates of the center of a #graphene_sphere_t.graphene.sphere.Sphere init_(graphene.point3_d.Point3D center, float radius) nothrowInitializes the given #graphene_sphere_t with the given center and radius.graphene.sphere.Sphere initFromPoints(graphene.point3_d.Point3D[] points, graphene.point3_d.Point3D center) nothrowInitializes the given #graphene_sphere_t using the given array of 3D coordinates so that the sphere includes them.graphene.sphere.Sphere initFromVectors(graphene.vec3.Vec3[] vectors, graphene.point3_d.Point3D center) nothrowInitializes the given #graphene_sphere_t using the given array of 3D coordinates so that the sphere includes them.bool isEmpty() nothrowChecks whether the sphere has a zero radius. Returns: `true` if the sphere is emptyvoid translate(graphene.point3_d.Point3D point, out graphene.sphere.Sphere res) nothrowTranslates the center of the given #graphene_sphere_t using the point coordinates as the delta of the translation.