Getting C3D Vision Parameters
The command below is used to get an object with some parameters from a C3D Vision instance.
Common command example (TypeScript):
let result = view.runCommand({
name: "GetParametersCommand",
type: GetParametersTypes.AnnotationList
})
Available request types:
Constant name |
Value |
Optional parameters |
Description |
---|---|---|---|
|
|
|
Returns objects added to a model. |
|
|
– |
Returns current camera parameters (projection, orientation and up vector for the standard projection). Details. |
|
|
|
Returns node UUIDs selected by command. |
New in version 1.5.0: Optional filter
parameter added.
Common result type of command (TypeScript):
type GetParametersCommandResult = {
name: ResultTypes.Parameters // "Parameters"
result: Promise<{
name: GetParametersTypes // command run type
<RESULT>
}>
}
This command returns an object storing the following: a constant name which is ResultTypes.Parameters
or just "Parameters"
and a promise object with a command type name and
<RESULT> depending on a command type.
Command type |
<RESULT> |
---|---|
|
|
|
|
|
|
In some cases, a command is able to fail. Then it returns another result, with the message
containing an error message, for further excepting.
Error result type of command (TypeScript):
type ErrorResult = {
name: ResultTypes.Error // "Error"
message: string
}
Also, there might be an empty result (e.g. in case of an invalid type name) with the following type.
Empty GetParameters result type (TypeScript):
type NoneResult = {
name: ResultTypes.None // "None"
}