Module vrController
[frames] | no frames]

Module vrController

Functions
 
vrLogInfo(text)
Displays a message of type info in the log window (below the render window).
 
vrLogInfo(nr, text)
Displays a message of type info in the log window (below the render window).
 
vrLogWarning(text)
Displays a message of type warning in the log window (below the render window).
 
vrLogWarning(nr, text)
Displays a message of type warning in the log window (below the render window).
 
vrLogError(text)
Display a message of type error in the log window (below the render window).
 
vrLogError(nr, text)
Display a message of type error in the log window (below the render window).
 
addExtProcWindow(exe_name, window_name)
Adds a external process window on top of the render window.
 
addModule(name, menu)
Adds custom python module plugin.
 
centerMainWindow()
Centers the main window on the screen.
 
changeScenegraph()
Emits a scenegraph changed message.
 
clearUndoStack()
Clear the undo/redo stack
 
closeStreams()
Close all open vred streams.
 
crashVred(type)
Crashes vred.
 
destroyScene()
Destroys the current scene.
 
enableSimulation(state)
Enables/disables global simulation.
int
getIdleTime()
Returns the idle time.
bool
getPresenterMode()
Returns true if VRED's presentation mode is currently enabeld, otherwise false.
float (64bit)
getSimulationTime()
Returns the simulation time in seconds.
float
getUnitScale()
Returns the unit scale factor.
bool
getVRender()
Returns the state of the vrender mode.
string
getVServerImagePath()
Returns the vserver image path.
int
getVServerState()
Returns the vserver state.
 
getVredBuildDate()
Return the vred build date.
 
getVredDisplayVersionYear()
Return the vred display year version.
 
getVredVersion()
Return the vred version number.
 
getVredVersionYear()
Return the vred year version.
 
getVredVersions()
Return the vred version number.
int
geterrno()
Returns the errno value.
 
hideModule(name)
Hides custom python module plugin.
bool
isViewer()
Returns true when running VREDPresenter.
 
newScene()
Creates a new scene and destroys the current scene.
 
reseterrno()
Resets the errno variable.
 
setEnvironmentVariable(name, value)
Sets an environment variable.
 
setLogEnabled(s)
Enable or disable terminal logging.
 
setNewSceneCB(fp)
Sets a python callback function which is called before executing newScene.
 
setPresenterMode(s)
Enable VRED's presentation mode.
 
setRenderUpdateEnabled(state)
Enables or disables the main render window update.
 
setShowQuickActionBars(state)
Show/hide all quick action bars.
 
setShowSurfaceAnalysisModule(show)
Show/hide Surface Analysis module in VREDPresenter.
 
setUnitScale(scale)
Sets the unit scale factor.
 
setVREDPresenterWebViewFixedHeight(height)
Changes the height of the VREDPresenter webview widget and disables vertical resizing.
 
setVREDPresenterWebViewFixedWidth(width)
Changes the width of the VREDPresenter webview widget and disables horizontal resizing.
 
setVREDPresenterWebViewWidth(width)
Changes the width of the VREDPresenter webview widget.
 
setVRender(state)
Enables vrender mode.
 
setVServerImagePath(path)
Sets vserver image path.
 
setVServerState(state)
Sets vserver state.
 
setViewerActiveXFixedHeight()
 
setViewerActiveXFixedWidth()
 
setViewerActiveXWidth()
 
setWIMergeCommands()
Merge duplicated python commands.
 
showLicenseDialog()
Show license dialog.
 
showModule(name)
Shows custom python module plugin.
 
showToolBars(state)
Shows or hides the main window toolbars.
 
subModule(name)
Subs custom python module plugin.
 
terminateVred()
Terminates vred.
 
togglePresenterMode()
Toggles VRED's presentation mode state.
 
updateRender(force)
Redraws the render widget.
 
updateRenderNoOCC(force)
Redraws the render widget.
 
updateScene()
Calculates new near/far clipping plane and new camera position.
 
updateTouchSensors()
Update touch sensor user interface.
 
vredLoop(count)
Calls the internal timer loop n times.
 
vred_click()
Deprecated.
 
vred_mousedown(x, y)
Simulates a mouse button-down event for the left mouse button.
 
vred_mouseup(x, y)
Simulates a mouse button-up event for the left mouse button.
 
vred_swipemove(x, y)
Simulates a mouse button move event for the left mouse button
 
writeTerminalOutput(filename)
Writes the terminal output as html out.
Variables
  AltButton = 134217728
  ControlButton = 67108864
  FULLSCREEN = 1
  GL_BLEND = 3042
  GL_CLAMP = 10496
  GL_CLAMP_TO_EDGE = 33071
  GL_COMBINE_EXT = 34160
  GL_DECAL = 8449
  GL_LINEAR = 9729
  GL_LINEAR_MIPMAP_LINEAR = 9987
  GL_LINEAR_MIPMAP_NEAREST = 9985
  GL_MODULATE = 8448
  GL_NEAREST = 9728
  GL_NEAREST_MIPMAP_LINEAR = 9986
  GL_NEAREST_MIPMAP_NEAREST = 9984
  GL_REPEAT = 10497
  KeyButtonMask = -33554432
  Key_0 = 48
  Key_1 = 49
  Key_2 = 50
  Key_3 = 51
  Key_4 = 52
  Key_5 = 53
  Key_6 = 54
  Key_7 = 55
  Key_8 = 56
  Key_9 = 57
  Key_A = 65
  Key_AE = 198
  Key_Aacute = 193
  Key_Acircumflex = 194
  Key_Adiaeresis = 196
  Key_Agrave = 192
  Key_Alt = 16777251
  Key_Ampersand = 38
  Key_Any = 32
  Key_Apostrophe = 39
  Key_Aring = 197
  Key_AsciiCircum = 94
  Key_AsciiTilde = 126
  Key_Asterisk = 42
  Key_At = 64
  Key_Atilde = 195
  Key_B = 66
  Key_BackSpace = 16777219
  Key_Backslash = 92
  Key_Backtab = 16777218
  Key_Bar = 124
  Key_BraceLeft = 123
  Key_BraceRight = 125
  Key_BracketLeft = 91
  Key_BracketRight = 93
  Key_C = 67
  Key_CapsLock = 16777252
  Key_Ccedilla = 199
  Key_Colon = 58
  Key_Comma = 44
  Key_Control = 16777249
  Key_D = 68
  Key_Delete = 16777223
  Key_Dollar = 36
  Key_Down = 16777237
  Key_E = 69
  Key_ETH = 208
  Key_Eacute = 201
  Key_Ecircumflex = 202
  Key_Ediaeresis = 203
  Key_Egrave = 200
  Key_End = 16777233
  Key_Enter = 16777221
  Key_Equal = 61
  Key_Escape = 16777216
  Key_Exclam = 33
  Key_F = 70
  Key_F1 = 16777264
  Key_F10 = 16777273
  Key_F11 = 16777274
  Key_F12 = 16777275
  Key_F13 = 16777276
  Key_F14 = 16777277
  Key_F15 = 16777278
  Key_F16 = 16777279
  Key_F17 = 16777280
  Key_F18 = 16777281
  Key_F19 = 16777282
  Key_F2 = 16777265
  Key_F20 = 16777283
  Key_F21 = 16777284
  Key_F22 = 16777285
  Key_F23 = 16777286
  Key_F24 = 16777287
  Key_F25 = 16777288
  Key_F26 = 16777289
  Key_F27 = 16777290
  Key_F28 = 16777291
  Key_F29 = 16777292
  Key_F3 = 16777266
  Key_F30 = 16777293
  Key_F31 = 16777294
  Key_F32 = 16777295
  Key_F33 = 16777296
  Key_F34 = 16777297
  Key_F35 = 16777298
  Key_F4 = 16777267
  Key_F5 = 16777268
  Key_F6 = 16777269
  Key_F7 = 16777270
  Key_F8 = 16777271
  Key_F9 = 16777272
  Key_G = 71
  Key_Greater = 62
  Key_H = 72
  Key_Help = 16777304
  Key_Home = 16777232
  Key_Hyper_L = 16777302
  Key_Hyper_R = 16777303
  Key_I = 73
  Key_Iacute = 205
  Key_Icircumflex = 206
  Key_Idiaeresis = 207
  Key_Igrave = 204
  Key_Insert = 16777222
  Key_J = 74
  Key_K = 75
  Key_L = 76
  Key_Left = 16777234
  Key_Less = 60
  Key_M = 77
  Key_Menu = 16777301
  Key_Meta = 16777250
  Key_Minus = 45
  Key_N = 78
  Key_Next = 16777239
  Key_Ntilde = 209
  Key_NumLock = 16777253
  Key_NumberSign = 35
  Key_O = 79
  Key_Oacute = 211
  Key_Ocircumflex = 212
  Key_Odiaeresis = 214
  Key_Ograve = 210
  Key_Ooblique = 216
  Key_Otilde = 213
  Key_P = 80
  Key_PageDown = 16777239
  Key_PageUp = 16777238
  Key_ParenLeft = 40
  Key_ParenRight = 41
  Key_Pause = 16777224
  Key_Percent = 37
  Key_Period = 46
  Key_Plus = 43
  Key_Print = 16777225
  Key_Prior = 16777238
  Key_Q = 81
  Key_Question = 63
  Key_QuoteDbl = 34
  Key_QuoteLeft = 96
  Key_R = 82
  Key_Return = 16777220
  Key_Right = 16777236
  Key_S = 83
  Key_ScrollLock = 16777254
  Key_Semicolon = 59
  Key_Shift = 16777248
  Key_Slash = 47
  Key_Space = 32
  Key_Super_L = 16777299
  Key_Super_R = 16777300
  Key_SysReq = 16777226
  Key_T = 84
  Key_THORN = 222
  Key_Tab = 16777217
  Key_U = 85
  Key_Uacute = 218
  Key_Ucircumflex = 219
  Key_Udiaeresis = 220
  Key_Ugrave = 217
  Key_Underscore = 95
  Key_Up = 16777235
  Key_V = 86
  Key_W = 87
  Key_X = 88
  Key_Y = 89
  Key_Yacute = 221
  Key_Z = 90
  Key_aacute = 193
  Key_acircumflex = 194
  Key_acute = 180
  Key_adiaeresis = 196
  Key_ae = 198
  Key_agrave = 192
  Key_aring = 197
  Key_atilde = 195
  Key_brokenbar = 166
  Key_ccedilla = 199
  Key_cedilla = 184
  Key_cent = 162
  Key_copyright = 169
  Key_currency = 164
  Key_degree = 176
  Key_diaeresis = 168
  Key_division = 247
  Key_eacute = 201
  Key_ecircumflex = 202
  Key_ediaeresis = 203
  Key_egrave = 200
  Key_eth = 208
  Key_exclamdown = 161
  Key_guillemotleft = 171
  Key_guillemotright = 187
  Key_hyphen = 173
  Key_iacute = 205
  Key_icircumflex = 206
  Key_idiaeresis = 207
  Key_igrave = 204
  Key_macron = 175
  Key_masculine = 186
  Key_mu = 181
  Key_multiply = 215
  Key_nobreakspace = 160
  Key_notsign = 172
  Key_ntilde = 209
  Key_oacute = 211
  Key_ocircumflex = 212
  Key_odiaeresis = 214
  Key_ograve = 210
  Key_onehalf = 189
  Key_onequarter = 188
  Key_onesuperior = 185
  Key_ordfeminine = 170
  Key_oslash = 216
  Key_otilde = 213
  Key_paragraph = 182
  Key_periodcentered = 183
  Key_plusminus = 177
  Key_questiondown = 191
  Key_registered = 174
  Key_section = 167
  Key_ssharp = 223
  Key_sterling = 163
  Key_thorn = 222
  Key_threequarters = 190
  Key_threesuperior = 179
  Key_twosuperior = 178
  Key_uacute = 218
  Key_ucircumflex = 219
  Key_udiaeresis = 220
  Key_ugrave = 217
  Key_unknown = 33554431
  Key_yacute = 221
  Key_ydiaeresis = 255
  Key_yen = 165
  Keypad = 536870912
  LeftButton = 1
  MidButton = 4
  MouseButtonMask = -1
  NOBORDER = 2
  NORMAL = 0
  NavigatorAxis = 3
  NavigatorFly = 1
  NavigatorTrackball = 0
  NavigatorWalk = 2
  NoButton = 0
  ONTOP = 4
  RightButton = 2
  SWITCH_OFF = 0
  SWITCH_ON = 1
  SWITCH_TOGGLE = -1
  ShiftButton = 33554432
  VRED_MSG_ARGV = 4096
  VRED_MSG_CHANGED_CAMERA_UP = 1048576
  VRED_MSG_CHANGED_MATERIAL = 65536
  VRED_MSG_CHANGED_PB_PARAMETERS = 33554432
  VRED_MSG_CHANGED_SCENEGRAPH = 32
  VRED_MSG_CONVERT_OSF_FILE = 1073741824
  VRED_MSG_DESELECTED_NODE = 524288
  VRED_MSG_EXPORTED_FILE = 262144
  VRED_MSG_IDLE = 4194304
  VRED_MSG_IMPORTED_FILE = 131072
  VRED_MSG_INIT = 2048
  VRED_MSG_KEY_PRESSED = 128
  VRED_MSG_KEY_RELEASED = 512
  VRED_MSG_LOADED_GEOMETRY = 32768
  VRED_MSG_LOOP = 1024
  VRED_MSG_NEW_SCENE = 16
  VRED_MSG_NONE = 1
  VRED_MSG_PRENEW_SCENE = 8388608
  VRED_MSG_PRE_QUIT = 16384
  VRED_MSG_PROJECT = 8192
  VRED_MSG_PROJECT_LOADED = 2097152
  VRED_MSG_PROJECT_MERGED = 67108864
  VRED_MSG_SAVED_GEOMETRY = 2147483648
  VRED_MSG_SELECTED_CAMERA = 268435456
  VRED_MSG_SELECTED_LIGHT = 536870912
  VRED_MSG_SELECTED_MATERIAL = 134217728
  VRED_MSG_SELECTED_NODE = 256
  VRED_MSG_SWITCH_MATERIAL_CHANGED = 16777216
  VRED_MSG_UPDATE_UI = 8
  VRED_MSG_USER = 64
  false = 0
  true = 1
Function Details

vrLogInfo(text)

 

Displays a message of type info in the log window (below the render window).

Parameters:
  • text (string) - The text to display.

vrLogInfo(nr, text)

 

Displays a message of type info in the log window (below the render window).

Parameters:
  • nr (integer) - The error number.
  • text (string) - The text to display.

vrLogWarning(text)

 

Displays a message of type warning in the log window (below the render window).

Parameters:
  • text (string") - The text to display.

vrLogWarning(nr, text)

 

Displays a message of type warning in the log window (below the render window).

Parameters:
  • nr (integer) - The error number.
  • text (string") - The text to display.

vrLogError(text)

 

Display a message of type error in the log window (below the render window).

Parameters:
  • text (string") - The text to display.

vrLogError(nr, text)

 

Display a message of type error in the log window (below the render window).

Parameters:
  • nr (integer) - The error number.
  • text (string") - The text to display.

addExtProcWindow(exe_name, window_name)

 

Adds a external process window on top of the render window.

Parameters:
  • exe_name (string) - The name of the executable.
  • window_name (string) - The name of the window.

addModule(name, menu)

 

Adds custom python module plugin.

Parameters:
  • name (string) - name of the module.
  • menu (string) - name of the menu where the plugin is inserted.

crashVred(type)

 

Crashes vred.

Parameters:
  • type (int) - The type of crash.

enableSimulation(state)

 

Enables/disables global simulation.

Parameters:
  • state (bool) - Global simulation: On/Off.

getIdleTime()

 

Returns the idle time.

Returns: int
The idle time.

getPresenterMode()

 

Returns true if VRED's presentation mode is currently enabeld, otherwise false.

Returns: bool
Presentation mode state.

getSimulationTime()

 

Returns the simulation time in seconds.

Returns: float (64bit)
The simulation time.

getUnitScale()

 

Returns the unit scale factor.

Returns: float
The scale factor.

getVRender()

 

Returns the state of the vrender mode.

Returns: bool
The state of the vrender mode.

getVServerImagePath()

 

Returns the vserver image path.

Returns: string
The vserver image path.

getVServerState()

 

Returns the vserver state.

Returns: int
The vserver state.

getVredBuildDate()

 

Return the vred build date.

Parameters:
  • version (string)
Returns:
The VRED build date.

getVredDisplayVersionYear()

 

Return the vred display year version.

Parameters:
  • version (string)
Returns:
year number.

getVredVersion()

 

Return the vred version number.

Parameters:
  • version (string)

getVredVersionYear()

 

Return the vred year version.

Parameters:
  • version (string)
Returns:
year number.

getVredVersions()

 

Return the vred version number.

Parameters:
  • version (string)
Returns:
version number.

geterrno()

 

Returns the errno value.

Returns: int
The errno value.

hideModule(name)

 

Hides custom python module plugin.

Parameters:
  • name (string) - name of the module.

isViewer()

 

Returns true when running VREDPresenter.

Returns: bool
true for viewer.

setEnvironmentVariable(name, value)

 

Sets an environment variable.

Parameters:
  • name (string) - The name of the variable.
  • value (string) - The value of the variable.

setLogEnabled(s)

 

Enable or disable terminal logging.

Parameters:
  • s (bool) - state true or false.

setNewSceneCB(fp)

 

Sets a python callback function which is called before executing newScene.

Parameters:
  • fp (function pointer) - The python function.

setPresenterMode(s)

 

Enable VRED's presentation mode. Only hotkeys from the Variants Sets module will work in this mode.

Parameters:
  • s (bool) - enable/disable.

setRenderUpdateEnabled(state)

 

Enables or disables the main render window update.

Parameters:
  • state (bool) - Main render window update: On/Off.

setShowQuickActionBars(state)

 

Show/hide all quick action bars.

Parameters:
  • state (bool) - visible state.

setShowSurfaceAnalysisModule(show)

 

Show/hide Surface Analysis module in VREDPresenter.

Parameters:
  • show (bool) - show/hide Surface Analysis module.

setUnitScale(scale)

 

Sets the unit scale factor.

Parameters:
  • scale (float) - The scale factor. 1.0 for mm, 10.0 for cm and 1000.0 for m.

setVREDPresenterWebViewFixedHeight(height)

 

Changes the height of the VREDPresenter webview widget and disables vertical resizing.

Parameters:
  • height (int (32bit)) - The height in pixels.

setVREDPresenterWebViewFixedWidth(width)

 

Changes the width of the VREDPresenter webview widget and disables horizontal resizing.

Parameters:
  • width (int (32bit)) - The width in pixels.

setVREDPresenterWebViewWidth(width)

 

Changes the width of the VREDPresenter webview widget.

Parameters:
  • width (int (32bit)) - The width in pixels.

setVRender(state)

 

Enables vrender mode.

Parameters:
  • state (bool) - The vrender mode: On/Off.

setVServerImagePath(path)

 

Sets vserver image path.

Parameters:
  • path (string) - The image path.

setVServerState(state)

 

Sets vserver state.

Parameters:
  • state (int) - The vserver state.

showModule(name)

 

Shows custom python module plugin.

Parameters:
  • name (string) - name of the module.

showToolBars(state)

 

Shows or hides the main window toolbars.

Parameters:
  • state (integer) - Main window toolbars: -1 = Toggle, 0 = Off, 1 = On.

subModule(name)

 

Subs custom python module plugin.

Parameters:
  • name (string) - name of the module.

updateRender(force)

 

Redraws the render widget.

Parameters:
  • force (bool) - Set true to update the render widget immediately, false otherwise (Optional). Default is false.

updateRenderNoOCC(force)

 

Redraws the render widget. This function is obsolete, use updateRender instead.

Parameters:
  • force (bool) - Set true to update the render widget immediately, false otherwise (Optional). Default is false.

vredLoop(count)

 

Calls the internal timer loop n times.

Parameters:
  • count (unsigned int (32bit)) - The number of calls.

vred_mousedown(x, y)

 

Simulates a mouse button-down event for the left mouse button.

The coordinates are in pixels and relative to the VRED main window, origin is upper-left corner.

Parameters:
  • x (int) - x coordinate.
  • y (int) - y coordinate.

vred_mouseup(x, y)

 

Simulates a mouse button-up event for the left mouse button.

The coordinates are in pixels and relative to the VRED main window, origin is upper-left corner.

Parameters:
  • x (int) - x coordinate.
  • y (int) - y coordinate.

vred_swipemove(x, y)

 

Simulates a mouse button move event for the left mouse button

The coordinates are in pixels and relative to the VRED main window, origin is upper-left corner.

Parameters:
  • x (int) - x coordinate.
  • y (int) - y coordinate.

writeTerminalOutput(filename)

 

Writes the terminal output as html out.

Parameters:
  • filename (string) - The absolute path of the .html file.