This page has been translated automatically.
视频教程
界面
要领
高级
实用建议
UnigineEditor
界面概述
资产工作流程
设置和首选项
项目开发
调整节点参数
Setting Up Materials
Setting Up Properties
照明
Landscape Tool
Sandworm (Experimental)
使用编辑器工具执行特定任务
Extending Editor Functionality
嵌入式节点类型
Nodes
Objects
Effects
Decals
Light Sources
Geodetics
World Objects
Sound Objects
Pathfinding Objects
Players
编程
基本原理
搭建开发环境
Usage Examples
UnigineScript
C++
C#
UUSL (Unified UNIGINE Shader Language)
File Formats
Rebuilding the Engine Tools
GUI
双精度坐标
应用程序接口
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Node-Related Classes
Objects-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
IG Plugin
CIGIConnector Plugin
Rendering-Related Classes
注意! 这个版本的文档是过时的,因为它描述了一个较老的SDK版本!请切换到最新SDK版本的文档。
注意! 这个版本的文档描述了一个不再受支持的旧SDK版本!请升级到最新的SDK版本。

Unigine.WorldBoundSphere Class

This class serves to construct the bounding sphere in double precision coordinates.

By using this class you can easily find the common bounding sphere for several objects by expanding the bounding sphere.

WorldBoundSphere Class

Properties

double Radius#

The bounding sphere radius.

dvec3 Center#

The bounding sphere center.

bool IsValid#

Checks the bounding sphere status.

Members


static WorldBoundSphere ( ) #

Constructor. Creates an empty bounding sphere.

WorldBoundSphere ( dvec3 center, double radius ) #

Constructor. Initializes bounding sphere by the center and radius of the bounding sphere.

Arguments

  • dvec3 center - The bounding sphere center.
  • double radius - The bounding sphere radius.

WorldBoundSphere ( WorldBoundSphere bs ) #

Constructor. Initializes by given bounding sphere.

Arguments

  • WorldBoundSphere bs - The bounding sphere.

WorldBoundSphere ( WorldBoundBox bb ) #

Constructor. Initializes by given bounding box.

Arguments

WorldBoundSphere ( BoundSphere bs, dmat4 transform ) #

Initialization by the bounding sphere and setting the given transformation matrix to the new bounding sphere.

Arguments

void Clear ( ) #

Clears the bounding sphere.

void Set ( dvec3 center, double radius ) #

Sets the bounding sphere by its center and radius.

Arguments

  • dvec3 center - The bounding sphere center.
  • double radius - The bounding sphere radius.

void Set ( WorldBoundSphere bs ) #

Sets the bounding sphere.

Arguments

  • WorldBoundSphere bs - The bounding sphere.

void Set ( WorldBoundBox bb ) #

Sets the bounding sphere by the bounding box.

Arguments

void Set ( BoundSphere bs, dmat4 transform ) #

Sets the bounding sphere by a bounding sphere with a transformation matrix taken into account.

Arguments

void Expand ( dvec3 point ) #

Expands the current bounding sphere for including given point.

Arguments

  • dvec3 point - Point coordinates.

void Expand ( WorldBoundSphere bs ) #

Expands the current bounding sphere for including given bounding sphere.

Arguments

  • WorldBoundSphere bs - The bounding sphere.

void Expand ( WorldBoundBox bb ) #

Expands the current bounding sphere for including given bounding box.

Arguments

int Inside ( dvec3 point ) #

Checks if the given point is inside the current bounding sphere.

Arguments

  • dvec3 point - Point coordinates.

Return value

1 if the given point is inside the bounding sphere; otherwise, 0.

int Inside ( dvec3 point, double radius ) #

Checks if the sphere is inside the bounding sphere.

Arguments

  • dvec3 point - The coordinates of the center of the sphere .
  • double radius - The sphere radius.

Return value

1 if the sphere is inside the bounding sphere; otherwise, 0.

int Inside ( dvec3 min, dvec3 max ) #

Checks if the box is inside the bounding sphere.

Arguments

  • dvec3 min - The box minimum coordinates.
  • dvec3 max - The box maximum coordinates.

Return value

1 if the box is inside the bounding sphere; otherwise, 0.

int Inside ( WorldBoundSphere bs ) #

Checks if the specified bounding sphere is inside the current bounding sphere.

Arguments

  • WorldBoundSphere bs - The bounding sphere.

Return value

1 if the specified bounding sphere is inside the current bounding sphere; otherwise, 0.

int Inside ( WorldBoundBox bb ) #

Checks if the bounding box is inside the bounding sphere.

Arguments

Return value

1 if the bounding box is inside the bounding sphere; otherwise, 0.

int InsideAll ( WorldBoundSphere bs ) #

Checks if the whole specified bounding sphere is inside the current bounding sphere.

Arguments

  • WorldBoundSphere bs - The bounding sphere.

Return value

1 if the whole specified sphere is inside the current bounding sphere; otherwise, 0.

int InsideAll ( WorldBoundBox bb ) #

Checks if the whole bounding box is inside the bounding sphere.

Arguments

Return value

1 if the whole box is inside the bounding sphere; otherwise, 0.
Last update: 2020-11-24
Build: ()