基于ACIS/HOOPS的3D应用开发简介 【转】
(整理)
平台:
造型引擎——ACIS
3D 造型
modeling类库,只要你掌握了这个库就可以完成所有的建模工作(基本上所有3D造型软件的功能他都有),但是这个库的易用性不够,所以在其上又开发
了一些API进一步对底层的acis类库进行封装,而最上层则是现在非常流行的一中类lisp的解释器平台,应用scheme语言作为上层的开发语言,经
过这么多步骤的封装,你只需要输入(block(0,0,0),(10,10,10))这个命令就能建立一个立方体,其他相似的简单命令就能完成很复杂的
操作,已经相当于AutoCAD里面的命令行模式了。
而是对OpenGL、DirectX这些图形引擎进行封装和扩展的结果。他的最大优势是对大模型操作和显示的优化以及一种压缩比高,适合网络传输的
stream模式。这两者都可以理解为对原有图形引擎的优化,使文件更小,运行更快。当然,灵活的对OpenGL和directX的支持也是其卖
点,HOOPS保证自己能同步跟上OpenGL和DirectX的发展步伐并在其上做有益的改进。
Body。Body可以有任何数目的Lumps。Lumps代表空间中一个约束的连接的区域。一个Lumps是一系列整个相连点集,而不论它们是三维、二
维、一维或是它们的混合。因此一个实体带有一个悬挂面的是一个Lumps,而两个不相连的薄面则代表两个Lumps。Shell是一系列整个相连的面。一
个实体带有一个悬挂面的是一个Shell,而一个实体带有一个不相连的面则是两个Shell。Subshells
不能够通过API来访问,它基本上不直间使用。一个FACE是空间一个几何表面,Face的边界是由Loops构成的。Loops是由一系列相连的
Coedge所组成。Coedge记录的是一个面Loops的中的一条边。引入是Coedge为了表示多个面共边,这就使得流体和非流体的造形成为可能。
对于Coedge很重要的一点是要理解它的方向性。在Coedge类中有很多指针,可指向它的相邻,前一个,后一个等等,这就使得在进行模型的遍历时是很
方便的。拓扑模型的遍历就是一个从上到下的循环查找的过程。
可以满足一般的可视化需要,但如果3D应用程序需要更加高级的图形功能(如隐藏线消除,高级渲染和贴图、动画、文字处理、2D矢量图输出、高级动画等)或
需要对图形性能进行优化时,开发人员还需要做大量的工作,如建立自己的图形数据库以及对包括OpenGL、Direct3D在内的多种硬件驱动提供支持
等,而这些图形功能的实现需要很多专业图形开发人员通过多年的努力才可能完成。
ACIS造型组件、InterOp数据接口组件,还和著名的可视化组件开发商美国TSA公司进行紧密合作,提供HOOPS可视化组件的授权和技术服务,使
用户可以在更高层次的图形平台上开发3D软件,从而提升软件产品的竞争力,降低开发成本并加快产品上市。
互、包括OpenGL和Direct3D在内的多种渲染管道的支持、高级渲染、2D图形的矢量化输出、动画、动态干涉检查以及图形数据流化处理等,此外
HOOPS中还内嵌了多边形优化和大模型处理等技术,能够大大提高3D可视化的性能。另外HOOPS开发包中提供的大量应用程序级的实例源码,可以帮助用
户在很短的时间内搭建出商业级的3D图形应用程序。
H O O P S / N E
T三个子组件,其中HOOPS/3dAF组件是一个3D图形应用程序框架,采用了保留模式的图形数据库和多种渲染管道来管理和绘制图形对象;HOOPS
/Stream组件可以用来对场景图数据进行流化处理;而HOOPS/NET组件则可以用于网络协同。这三个子组件既可以单独授权,也可以结合在一起使
用。
HOOPS 3D Application Framework (HOOPS/3dAF) consists of an integrated
suite of toolkits that are used to build commercial 3D graphics
applications. HOOPS/3dAF provides a flexible architectural foundation
based on a series of modular application components, which enable the
rapid development and maintenance of high-performance design,
visualization, and engineering packages. HOOPS/3dAF maintains platform
independence within each component, providing comprehensive
cross-platform solutions on Windows, UNIX, LINUX, Mac OS X and the
Internet.
diagram below illustrates how these components are connected to each
other and how user generated events flow from the GUI Toolkit to the
HOOPS/3dAF.
events are collected by a GUI Tool's event queue. The HOOPS/GUI
integration module monitors the event queue and dispatches appropriate
events to either the HOOPS/MVO objects, HOOPS/Net client objects, or
directly to HOOPS/3dGS. The HOOPS/MVO application objects in turn engage
the API of either the geometric modeler, HOOPS/GMB, HOOPS/Net, or
HOOPS/3dGS itself to interact with the data stored in each component.
The Graphical User Interface Integrations
encapsulate the work needed to connect the HOOPS/3dAF to several
different Graphical User Interface (GUI) toolkits. Currently HOOPS/GUI
modules exist for:
bridge provides an API for controlling the manner in which ACIS'
geometric tessellation is mapped to HOOPS primitives, and for finding
exactly which HOOPS segment entity corresponds to which ACIS entity and
vice versa. The HOOPS/ACIS Bridge is supplied as a dynamic linked
library (dll) with an exposed API.
a two-way connection between ACIS and the HOOPS/3dGS involves accessing
the geometric data in ACIS and mapping it the appropriate set of
geometric primitives in HOOPS
<outcome>= api_make_sphere(<radius>, <sphere_body>);
|
{
BODY* sphere_body;
vector translate_vector;
transf delta_transf;
outcome o;
translate_vector.set_x(center.x);
translate_vector.set_y(center.y);
translate_vector.set_z(center.z);
delta_transf = translate_transf(translate_vector);
o = api_make_sphere(radius, sphere_body);
o = api_transform_entity(sphere_body, delta_transf);
assert(o.ok());
// before rendering bodies, check if this view is in 'merge faces'
// mode or not, and ensure that the rendering option is set
// accordingly. This is necessary because the HOOPS/GM Rendering
// Options are procedural; they set the current state of the bridge,
// and we need to make sure that all parts in each view object are
// rendered in a consistent mode
if (((HSolidView*)GetView())->GetOptimizations())
HA_Set_Rendering_Options("merge faces");
else
HA_Set_Rendering_Options("no merge faces");
// now put it in the HOOPS database
HA_Render_Entity((ENTITY*)sphere_body);
((HSolidModel*)m_pView->GetModel())->AddAcisEntity(sphere_body);
return sphere_body;
}
void HSolidModel::DeleteAcisEntity( ENTITY* entity)
{
ENTITY_LIST elist;
elist.add(entity);
HA_Delete_Entity_Geometry(elist);
api_del_entity(entity);
}
HOOPS/ACIS Bridge maps the tessellation of all ACIS entities to HOOPS
geometric primitives, inserting zero or more new HOOPS geometric
primitives into the HOOPS database for each ACIS entity encountered.
While each ACIS entity uses a pointer for access, HOOPS entities have
“keys” that are long integers and are passed to routines when accessing
the entity. The HOOPS/ACIS Bridge routines HA_Compute_Entity_Pointer and HA_Compute_Geometry_Keys can be used for converting ACIS pointers to HOOPS keys and vice versa.
performing operations that modify ACIS entities, it is necessary to
keep the HOOPS representation of the model synchronized with its ACIS
representation. Because such operations are typically initiated by
selecting (hit testing) HOOPS geometric objects, it is necessary to
determine which ACIS entity(s) correspond with the selected HOOPS
entities, and vice versa. The HOOPS/ACIS Integration includes routines
that support this requirement.
geometric entities are identified by a HOOPS 'key'. Recall that ACIS
entities are referred to by an ACIS pointer. Given a HOOPS key, the HA_Compute_Entity_Pointer function will return the ACIS pointer for the ACIS entity associated with that key. Conversely, given an ACIS pointer, the HA_Compute_Geometry_Keys
function will return all the HOOPS keys for the tessellated geometry or
the HOOPS segment associated with the ACIS entity. (Recall that an ACIS
entity might be represented by more than one HOOPS geometric entity.)
on the HOOPS scene returns the key(s) of HOOPS geometry, requiring us
to find the ACIS entity that is associated with the selected HOOPS
geometry. If we wanted to access the ACIS 'body' entity given the key of
a selected HOOPS geometric primitive, we would call:
BODY* entity = (BODY*)HA_Compute_Entity_Pointer(key, BODY_TYPE);
|
can now use the pointer of the ACIS entity to perform ACIS operations,
or to access the HOOPS geometric primitives that represent the ACIS
entity.
View : Representations of the application data
Operator : Algorithms that operate on the application data
of the application operates on the model via the views of the model.
Views are designed specifically to facilitate a given model interaction
such as data creation or editing. Views can "look at" multiple models
and models can "be seen" by multiple views (a many to many mapping).
Operators are associated with views.
3D objects are organized into segments containing geometry, attributes
and sub-segments. For each application, the 3D model maps to some
section of the HOOPS segment tree, typically in the Include Library.
Views are mapped to HOOPS driver instance segments with camera and
window attributes. The model is either directly built under the driver
instance segment or included from another spot in the segment tree. This
relationship of HOOPS model to HOOPS views is generic and applicable to
most applications built with HOOPS.
consist of the application code that manipulates the application data.
When building HOOPS-MVO applications, the operators use the HOOPS API,
along with other component or application-specific APIs, to manipulate
the data stored in both HOOPS and application-specific data structures.
HOOPS/MVO Classes provide a HOOPS-specific implementation of the
model/view/operator paradigm, which may be directly incorporated into an
application and extended.
library builds higher level objects for the model and view out of HOOPS
segment structures. The HBaseModel object is built out of the include
library and the HBaseView object is built out of HOOPS driver segment
instances. View objects also build an initial segment structure for
managing the inclusion of model objects, interacting with user input,
lighting of the scene, etc...
provides the algorithms for creating, editing, manipulating, and
querying the graphics information stored in the database
HOOPS/3dGS Graphics System, illustrated in Figure 1, consists of 2
major subcomponents: a graphical object database called the HOOPS/3dGS
Segment Tree, and a rendering pipeline called the HOOPS/3dGS Structured
Device Interface.
HOOPS/3dGS database stores graphical data in objects called "segments".
Think of a segment as a container for geometry and attributes that
describe how the geometry is to be drawn..
which lends itself naturally to organizing graphics information. In
terms of object-oriented programming, think of a segment as an object.
is a set of platform and GUI-independent C++ classes that provide
support for creating and reading HOOPS Stream Files (HSF's) or data
streams containing 2D & 3D scene-graph objects, attributes, and any
kind of specialized application-specific data.
open architecture allows developers to create and read custom,
stream-enabled HSF files that are tailored to a particular application's
needs. Its flexibility of design enables the creation of an endless
variety of streaming formats, file extensions, file interaction
strategies (including client/server interaction), data transfer
techniques, and more...all with advanced data compression and full
object and attribute support.
is independent from other HOOPS modules, in that its usage does not
require the application's architecture to be based on HOOPS/3dAF. Any
application using a proprietary scene graph, as well as those that use
HOOPS/3dAF, can implement HOOPS/Stream.
基于ACIS/HOOPS的3D应用开发简介 【转】的更多相关文章
- 一款基于HTML5的Web 3D开发工具
在我们协助客户进行3D应用的开发过程中,客户遇到的最头疼的问题是如何在短时间内学会使用TWaver 3D引擎,以及使用TWaver 3D来创建和导入项目所需的各种3D业务模型.由于项目涵盖的行业繁多. ...
- 基于Lua的游戏服务端框架简介
基于Lua的游戏服务端框架简介 [转]https://gameinstitute.qq.com/community/detail/106396 基于lua的游戏服务端框架简介 1. 引言 笔者目前在参 ...
- 5 个最好的3D游戏开发工具(转)
转自:http://www.open-open.com/news/view/33a4f0 5 个最好的3D游戏开发工具 jopen 2012-11-19 22:56:21 • 发布 摘要:UDK(th ...
- 基于HTML5的燃气3D培训仿真系统
最近上线了的基于HTML5的燃气3D培训仿真系统,以前的老系统是采用基于C++和OpenGL的OpenSceneGraph引擎设计的,OSG引擎性能和渲染效果各方面还是不错的,但因为这次新产品需求要求 ...
- 基于 HTML5 WebGL 的 3D 网络拓扑图
在数据量很大的2D 场景下,要找到具体的模型比较困难,并且只能显示出模型的的某一部分,显示也不够直观,这种时候能快速搭建出 3D 场景就有很大需求了.但是搭建 3D 应用场景又依赖于通过 3ds Ma ...
- Unity 3D游戏开发引擎:最火的插件推荐
摘要:为了帮助使用Unity引擎的开发人员制作更完美的游戏.我们精心挑选了十款相关开发插件和工具.它们是:2D Toolkit.NGUI.Playmaker.EasyTouch & EasyJ ...
- 基于Azure的软件部署和开发系列沙龙
活动简介: Azure是一种灵活和支持互操作的平台,它可以被用来创建云中运行的应用或者通过基于云的特性来加强现有应用.它开放式的架构给开发者提供了Web应用.互联设备的应用.个人电脑.服务器.或者提供 ...
- Webservice WCF WebApi 前端数据可视化 前端数据可视化 C# asp.net PhoneGap html5 C# Where 网站分布式开发简介 EntityFramework Core依赖注入上下文方式不同造成内存泄漏了解一下? SQL Server之深入理解STUFF 你必须知道的EntityFramework 6.x和EntityFramework Cor
Webservice WCF WebApi 注明:改编加组合 在.net平台下,有大量的技术让你创建一个HTTP服务,像Web Service,WCF,现在又出了Web API.在.net平台下, ...
- 基于 webGL 的元素周期表 3D 交互展示
前言 之前在网上看到别人写的有关元素周期表的文章,深深的勾起了一波回忆,记忆里初中时期背的“氢氦锂铍硼,碳氮氧氟氖,钠镁铝硅磷,硫氯氩钾钙”.“养(氧)龟(硅)铝铁盖(钙),哪(钠)家(钾)没(镁)青 ...
随机推荐
- Python 基础(一)
本章内容 1.编译和解释型语言的区别 2.Python的解释器 3.pyc文件 4.运行环境 5.变量 6.数据类型 7.字符编码 8.三元运算 编译和解释型语言的区别 编译器是把源程序的每一条语句都 ...
- BugBash活动分享
此文已由作者夏君授权网易云社区发布. 欢迎访问网易云社区,了解更多网易技术产品运营经验. BugBash源至微软概念,翻译为<缺陷大扫除>,顾名思义是集中大家力量全面清扫Bug,确保产品质 ...
- Python面试题(练习一)
1.Python的可变类型和不可变类型? 可变类型:list.dict(列表和字典) 不可变类型:数字.字符串.元组 2.求结果: v = dict.fromkeys(['k1','k2'],[]) ...
- SpringMVC对于跨域访问的支持
原文地址:http://docs.spring.io/spring/docs/5.0.0.RC2/spring-framework-reference/web.html#mvc-introductio ...
- Scrum基础知识图谱
啰嗦一下 最近在学习scrum项目管理的知识,书上知识点分散,很难有整体的视角来看scrum有哪些核心知识,故制作了思维导图,望给和我一样容易迷失的人一样,起到一个指引作用,废话不多说,直接上图 图谱
- Linux Shell系列教程之(四)Shell注释
本文是Linux Shell系列教程的第(四)篇,更多shell教程请看:Linux Shell系列教程 与许多的编程语言一样,Shell中也有注释符号,今天就为大家来介绍下Shell中的注释的语法及 ...
- hdu6085[压位+暴力] 2017多校5
/*hdu6085[压位+暴力] 2017多校5*/ /*强行优化..*/ #include <bits/stdc++.h> using namespace std; struct bit ...
- hihoCoder #1157 建造金字塔
这道题我想了一天才想清楚做法.AC 了之后去看别人写的题解,都是三言两语意识流式描述,我并不能读懂.我觉得很自卑,为何人家解这道题如此轻松.不过,我还是决定把我的解法写下来,并且一定要写清楚. 思路 ...
- [LOJ#114]k 大异或和
[LOJ#114]k 大异或和 试题描述 这是一道模板题. 给由 n 个数组成的一个可重集 S,每次给定一个数 k,求一个集合 T⊆S,使得集合 T 在 S 的所有非空子集的不同的异或和中,其异或和 ...
- Spring Boot 必须先说说 Spring 框架!
现在 Spring Boot 非常火,各种技术文章,各种付费教程,多如牛毛,可能还有些不知道 Spring Boot 的,那它到底是什么呢?有什么用?今天给大家详细介绍一下. Spring Boot ...