new features of the brl-cad database format · •the dbupgrade command creates a new database in...

14
New Features of the BRL-CAD Database Format Lee A. Butler

Upload: others

Post on 22-Sep-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

New Featuresof the

BRL-CAD Database Format

Lee A. Butler

Page 2: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 2

New Database Outline• Introduction & Upgrading• Machine Independence• Attributes• New ASCII form• Binary objects• Hiding• Unlimited length names• Neu-Speak terms

Page 3: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 3

Introduction• New format introduced in Release 6.0• mged will edit either old or new format

– Note that new capabilities only work on newversion databases

• New format is more compact than previousversion

• New capabilities for storing attributes andarbitrary data.

Page 4: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 4

Databases Are Smaller Now Objects are no longer stored in 128-byte granules

Size (Mbytes)Model Rel. 5.x Rel. 6.0 D

A-10 12.5 3.8 .69CH-47D 5.8 2.8 .51LAV 3R 107.0 101.8 .05M60A3 2.5 1.3 .50SCUD 6.5 3.1 .53T-72 M1 4.1 2.0 .51

Page 5: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 5

Upgrading• The dbupgrade command creates a new

database in the new format from an existingdatabase.– Usage: dbupgrade old.g new.g5

• Users should convert databasesas soon as possible.– Old format remains machine-specific– Old format does not support new features such

as attributes

Page 6: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 6

Machine Independent• All floating point stored in big-endian IEEE

double precision.– More accurate geometry– Larger geometry possible– On-disk units are still in millimeters

• Integers stored as big-endian– In 16-, 32-, and 64-bit representations

Page 7: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 7

Attributes• Associate arbitrary text data with any object• Some attribute names already reserved/in-

use:– MUVES_Component– Comment– Traditional region flags: region_id, los air_code

Page 8: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 8

Simple Uses of Attributesmged> attr set piston3.r comment “is material right?”mged> attr set piston3.r RoleModel Elvismged> attr get piston3.r commentis material right?mged> attr get piston3.rcomment {is material right?} RoleModel {Elvis}mged> attr set piston3.r MUVES_Component enginemged> attr set ember rgb [glow [attr ember get T]]mged> db adjust sphere V [attr get sphere posn(5)]mged>

Page 9: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 9

New ASCII Form• Optimized for processing with Tcl

command interpreter

• Note: special “bwish” and “btclsh” versionsof interpreters– Contain BRL-CAD extensions to the interpreter

Page 10: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 10

Binary Objects• Store arbitrary information in a database

object.– Textures– Dsp data for “height fields”– User data

• Pro/E database• Reports

Page 11: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 11

Hidden Objects• The mged “hide” command will remove

object from “ls” displays– note: ls -a shows ALL objects, even hidden

ones• The mged “unhide” command will make

object visible again

Page 12: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 12

New Database Object• Called _GLOBAL• Stores database global information such as

units, tolerances, title, etc.• Ordinarlily “hidden”• Auto-recreated if it is ever deleted

– Of course, old values are lost

Page 13: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

BRL-CAD User’s Group Meeting 2002 13

Neu-Speak• Some changes in terminology:

– “Primitive Shape” not “Solid”• Originally, BRLCAD supported only platonic solids

– “Assembly Combination” not “Group”• No database object called group.• A special “comb” command that inserted “u” operators for you

Page 14: New Features of the BRL-CAD Database Format · •The dbupgrade command creates a new database in the new format from an existing database. –Usage: dbupgrade old.g new.g5 •Users

Thank you

Lee A. [email protected]

410 278 9200