Difference between revisions of "MGED CMD db"

From BRL-CAD
(New page: Category:MGED =db= __TOC__ ==Syntax== :db command [args...] ==Argument(s)== : '''commands''' :: Valid Subcommand : '''[args…. ]''' :: Arguments are Subcommand dependant ==Retu...)
 
m
 
Line 1: Line 1:
[[Category:MGED]]
+
[[Category:MGED|Db]]
  
 
=db=
 
=db=

Latest revision as of 08:30, 18 November 2009


db[edit]

Syntax[edit]

db command [args...]


Argument(s)[edit]

commands
Valid Subcommand
[args…. ]
Arguments are Subcommand dependant


Return Value(s)[edit]

No Return Values for this command.


Description[edit]

The "db" command provides an interface to a number of database manipulation routines. Note that this command always operates in units of millimeters. The command must be one of the following with appropriate subcommands:

match <regular_exp>
Return a list of all objects in that database that match the list of regular expressions.
get shape_or_path [attribute]
Return information about the primitive shape at the end of the shape_or_path. If a path is specified, the transformation matrices encountered along that path will be accumulated and applied to the leaf shape before displaying the information. If no attribute is specified, all the details about the shape are returned. If a specific attribute is listed, then only that information is returned.
put shape_name shape_type attributes
Create shape named shape_name of type shape_type with attributes as listed in attributes. The arguments to the put command are the same as those returned by the get command.
adjust shape_name attribute new_value1 [new_value2 new_value3...]
Modify the shape named shape_name by adjusting the value of its attribute to the new_values.
form object_type
Display the format used to display objects of type object_type.
tops
Return all top-level objects.
close
Close the previously opened database and delete the associated command.
get_type object
Returns the object type for object. e.g. bot , sph , arb8 , etc.

Example(s)[edit]

mged> db get cone.s
Get a list of all the attributes and their values for shape cone.s.
mged> db get cone.s V
Get the value of the V (vertex) attribute of shape cone.s.
mged> db put new_cone.s tgc V {0 0 0} H {0 0 1} A {1 0 0} B {0 1 0} C {5 0 0} D {0 5 0}
Create a new TGC shape named new_cone.s with the specified attributes.
mged> db adjust new_cone.s V {0 0 10}
Adjust the V (vertex) attribute of new_cone.s to the value {0 0 10}.
mged> db form tgc
Display the format used by the get and put commands for the TGC shape type


See Also[edit]

No related commands.



Page Generated by David Loman on: 10/11/2007 at: 12:19:35 PM