25
DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Embed Size (px)

Citation preview

Page 1: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

DWGdirect Overview

ODA World Conference 2009Leiden, The Netherlands

Sergey SlezkinDWGdirect Development Team Lead

Page 2: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Early C++ Development Goals

Replace OpenDWG Toolkit/Viewkit ASAP.Provide API instead of direct access to all data in C structures.Implement commonly required functionality inside the libraries making them more user friendly.Provide extensible architecture able to incorporate new functionality and features.

Page 3: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Direct Access to Data without Error Checking

Not bad for read-only access.Modifying data or creating a new drawing required deep knowledge of data structures and relationships between objects.High risk of writing invalid file which cannot be loaded by any application – loss of data.

Page 4: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Extra Functionality Added at Early Stage

Conversions to/from different DWG/DXF versions and taking care of round-trip data through minor versions.Repairing corrupted files and auditing in-memory data.Building dimension blocks, blocks representing standard arrowheads, etc.

Page 5: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Conversions to/from Different DWG/DXF Versions

Supported versions: Release 2.5 up to 2009. 2010 format support to be released later this year.While file loading, drawing is always converted to the latest version. Round-trip data is processed.Client code always works with latest version. While saving, DWGdirect takes care of how new entities/properties should be saved.

Page 6: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Recover — We Did ItFrom: Sergey SlezkinSent: Monday, September 21, 1998 4:27 AMTo: 'OpenDWG'Subject: Duplicate handles in R12 DWG

Hello!

I came across a DWG file created by some

old version of VisualCADD. It has duplicate handles in entities section

and ODT refuses to load it. AutoCAD loads

thisfile. It's RECOVER command reports

thatit replaced the duplicate handle. CanODT behavior be changed to be the

sameas AutoCAD's?

Thanks,Sergey Slezkin

From: "OpenDWG Alliance Support“ To: 'Sergey Slezkin‘ Sent: Monday, September 21, 1998 8:26

PMSubject: RE: Duplicate handles in R12 DWG

Hi Sergey,

Well, this is an Alliance, and you guys have the source code, so if you wantwrite a "RECOVER" utility (and I doubt that when ACAD loads the file itreplaces the handle; I think ONLY "RECOVER" does that), please do so andsubmit it so that others can use it also.  It's not something I am going totake on.

Sincerely yours,M.R.

Page 7: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Defects that DWGdirect Repairs

Corrupted data inside an object (object can be skipped)Missing Table or Dictionary entries (Linetype ByBlock, ByLayer, Style Standard, etc.)Values of system variablesValues of various entity properties (such as text’s oblique angle, zero-length normal, zero scale, etc.)Invalid or duplicate handlesCyclic block referencesInvalid characters in namesAnd more

Page 8: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Some Examples of Error Messages for Entity Containers

“Cross references in entities list”“Multiple entries of reference”“Last entity does not match last reference in container”“Invalid subentity type”“Invalid vertex index”“Polyface Mesh has no valid faces”“Polyface Mesh vertex after face”

There are more than one hundred different error types which are detected and fixed.

Page 9: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Advanced Functionality AddedUndo/redo and transactions supportPartial file loading and paging objectsCustom object and command plug-insProtocol extensionsEvent notificationsACIS supportSupport for on-screen editingExport to DWF, SVG, PDF, SAT, HSF, etc.DWF and DGN underlay support

Page 10: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

DWGdirect Usage Areas

Simple DWG processing utilitiesImport/export plug-ins for CAD applicationsVisualizationRedliningFull CAD applications using DWGdirect as the core

Page 11: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Support

Support is performed by developers.Members take advantage of professional answers.Developers directly contacting clients get better idea of problems clients have.Everyday contacts with members help setting priorities for future development.

Page 12: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Supported Platforms

Windows 32-bitWindows 64-bitWindows CESGIMacintoshLinuxSolarisHPIBM AIX

Windows 32-bit compilers:

-MS VC 6 -MS VC 2002 -MS VC 2003 -MS VC 2005 -MS VC 2008 -Borland Builder 6 -Borland Builder 2006 -Borland Builder 2009

Page 13: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Customizing DWGdirect

Optimize application size by not including optional modulesProvide custom implementation for replaceable functionalityAdd custom functionality (commands and objects) up to creating custom vertical applications

Page 14: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Core Functionality

DatabaseDatabase

General Structure

Visualization Interface

Rendering Devices

Rendering Devices ExportsExports

DWG/DXF File I/O

DWG/DXF File I/O

ACIS Solids Support

ACIS Solids Support

Other Optional Modules

Other Optional Modules

Page 15: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Optional Modules

Rendering devicesEnablers for Inventor and MDT entitiesACIS supportExports (DWF, SVG, PDF, HOOPS, STL, …)DGN & DWF underlay supportDWF importDynamic blocks

Old-styled materials (AVE) supportFields evaluationPlot styles supportRaster files supportDimension blocks recomputingGrip/stretch/snap points supportOLE support

Page 16: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Alternative Implementations Provided by ODA

Rendering devices (WinGDI/OpenGL/DirectX/Bitmap)ACIS support (in-house/Spatial ACIS)Raster support

(in-house/JPEG-6B/Snowbound)TTF support (Windows API/FreeType)

Page 17: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Rendering Devices

Visualization Interface

DirectX

DWGdirect Core

DWGdirect Core

OpenGLWinGDI Bitmap

Page 18: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

ACIS Support

Modeler Interface

Pure In-House

Implementation

Rendering / Read / Write / Convert / Limited Creation

DWGdirect Core

DWGdirect Core

Spatial ACISFull Solid Modeling

Support

Page 19: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Raster File Handling

Raster Services Interface

Pure In-House

Implementation

BMP files support

Implementation using JPEG-6B

BMP & JPG files support

Implementation using

SnowboundMultiple raster file formats support

DWGdirect Core

DWGdirect Core

Page 20: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

True Type Font Support

Font Engine Interface

Implementation using

Windows API

DWGdirect Core

DWGdirect Core

Implementation using FreeType

library

Page 21: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

DWG Functionality

DWG Database

DWG Database

General Structure

Visualization Interface

Rendering Devices

Rendering Devices ExportsExports

DWG/DXF File I/O

DWG/DXF File I/O

ACIS Solids Support

ACIS Solids Support

DWF Underlay Support

DWF Underlay Support

Page 22: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

General Structure

Visualization Interface

Rendering Devices

Rendering Devices ExportsExports

ACIS Solids Support

ACIS Solids Support

DWF Underlay Support

DWF Underlay Support

Page 23: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Universal Viewer / Converter

Visualization Interface

Rendering Devices

Rendering Devices ExportsExports

DWG DWG DWF DWF ACIS ACIS Parasolid

Parasolid DGN DGN

Page 24: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

ConclusionDWGdirect is a powerful cross-platform tool for any DWG processing application development — from simple utilities to full CAD applications.Its flexibility and extensibility provide great opportunities for customization to meet specific needs.Man-years put into its development save a lot of effort for all ODA members.Functionality initially developed as an optional part of DWGdirect can be used outside of it to support other file formats.

Page 25: DWGdirect Overview ODA World Conference 2009 Leiden, The Netherlands Sergey Slezkin DWGdirect Development Team Lead

Questions