OrsPlugins

orsdicomloader

Imports and manages DICOM image files

Portions dcmtk

Portions OpenJPEG

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Feb 12 2016 08:35
dragonflyVersion:
 3.0
UUID:e8712846762511e790fb448a5b5d70c0
class OrsPlugins.orsdicomloader.OrsDICOMLoader(varname=None, managed=True)
lib = None
libName = 'OrsDICOMLoader.dll'
interfacemethod loadFiles(fileNames)

Loads the set of files.

Parameters:fileNames (file) [count=[0, None]] – fully qualified file names
Returns:output (ORSModel.ors.Group) [count=1] – Group with all datasets created
interfacemethod loadFolderContents(path, recurse=True)

Loads the contents of a folder.

Parameters:
  • path (str) – fully qualified file path
  • recurse (bool) – True to recurse into subfolders, False to do only specified folder
Returns:

output (ORSModel.ors.Group) [count=1] – Group with all datasets created

startGui()

orsimageloader

Imports image files

Portions LIBTIFF

Portions CTK

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Feb 23 2015 15:44
dragonflyVersion:
 3.0
UUID:396311c8762611e7879a448a5b5d70c0
class OrsPlugins.orsimageloader.OrsImageLoader(varname=None, managed=True)
classmethod OpenUIOnRecentFileEntry(entry)

Helper interface to start the gui, prepopulating the files list :param entry: a saved recent file entry :return: None

classmethod StartGuiWithFiles(stringifiedFiles='')
createCroppedDatasetDeterminingGeometryFromFiles(fileNames, minX, maxX, minY, maxY, minZ, maxZ)
createCroppedDatasetDeterminingGeometryFromFolderContents(folderPath, searchFilter, minX, maxX, minY, maxY, minZ, maxZ)
interfacemethod createDatasetDeterminingGeometryFromFiles(fileNames)

Creates a dataset from a set of files.

Parameters:fileNames (file) [count=[0, None]] – fully qualified file names
Returns:output (ORSModel.ors.Channel) – Created dataset
interfacemethod createDatasetDeterminingGeometryFromFolderContents(folder, searchFilter) → Channel

Creates a dataset from the files found within a folder (not going through its sub-folders).

Parameters:
  • folder (folder) – fully qualified folder
  • searchFilter (str) – string search filter
Returns:

output (ORSModel.ors.Channel) – Created dataset

classmethod createDatasetDeterminingGeometryFromFolderContentsAndPublish(folder)
classmethod createDatasetDeterminingGeometryFromStringifiedFiles(fileNames)
interfacemethod createDatasetFromFiles(fileNames, xSize, ySize, zSize, tSize, minX, maxX, minY, maxY, minZ, maxZ, xSampling, ySampling, zSampling, tSampling, xSpacing, ySpacing, zSpacing, slope, offset, dataUnit, invertX, invertY, invertZ, axesTransformation, datasetName, convertFrom32To16bits, dataRangeMin, dataRangeMax, frameCount, additionalInfo)

Creates a dataset from a set of files.

Parameters:
  • fileNames (file) [count=[0, None]] – fully qualified file names
  • xSize (int) – X size
  • ySize (int) – Y size
  • zSize (int) – Z size
  • tSize (int) – T size
  • minX (int) – lower X index (for cropping)
  • maxX (int) – upper X index (for cropping)
  • minY (int) – lower Y index (for cropping)
  • maxY (int) – upper Y index (for cropping)
  • minZ (int) – lower Z index (for cropping)
  • maxZ (int) – upper Z index (for cropping)
  • xSampling (int) – sampling in X
  • ySampling (int) – sampling in Y
  • zSampling (int) – sampling in Z
  • tSampling (int) – sampling in T
  • xSpacing (float) – X spacing (in meters)
  • ySpacing (float) – Y spacing (in meters)
  • zSpacing (float) – Z spacing (in meters)
  • slope (float) –
  • offset (float) –
  • dataUnit (str) – unit of the data
  • invertX (bool) – True to invert the X axis
  • invertY (bool) – True to invert the Y axis
  • invertZ (bool) – True to invert the Z axis
  • axesTransformation (int) – 0-> XYZ, 1->XZY, 2->YXZ, 3->YZX, 4->ZXY, 5->ZYX
  • datasetName (str) – name of created dataset
  • convertFrom32To16bits (bool) – True to convert from 32 bits to 16
  • dataRangeMin (float) – minimum of data range
  • dataRangeMax (float) – maximum of data range
  • frameCount (int) – number of frames
  • additionalInfo (str) – an XML supplying additional model information
Returns:

output (ORSModel.ors.Channel) [count=[0, None]] – Created dataset

interfacemethod createDatasetFromRAWFiles(fileNames, xSize, ySize, zSize, tSize, type, reverseByteOrdering, signedData, dataOffset, minX, maxX, minY, maxY, minZ, maxZ, xSampling, ySampling, zSampling, tSampling, xSpacing, ySpacing, zSpacing, slope, offset, dataUnit, invertX, invertY, invertZ, axesTransformation, datasetName)

Creates a dataset from a set of RAW files.

Parameters:
  • fileNames (file) [count=[0, None]] – fully qualified file names
  • xSize (int) – X size
  • ySize (int) – Y size
  • zSize (int) – Z size
  • tSize (int) – T size
  • type (int) – 0->unsigned byte, 1->unsigned short, 2->unsigned int, 3->float
  • reverseByteOrdering (int) –
  • signedData (int) –
  • dataOffset (int) – offset into the file where the data begins (for files that have a header)
  • minX (int) – lower X index (for cropping)
  • maxX (int) – upper X index (for cropping)
  • minY (int) – lower Y index (for cropping)
  • maxY (int) – upper Y index (for cropping)
  • minZ (int) – lower Z index (for cropping)
  • maxZ (int) – upper Z index (for cropping)
  • xSampling (int) – sampling in X
  • ySampling (int) – sampling in Y
  • zSampling (int) – sampling in Z
  • tSampling (int) – sampling in T
  • xSpacing (float) – X spacing (in meters)
  • ySpacing (float) – Y spacing (in meters)
  • zSpacing (float) – Z spacing (in meters)
  • slope (float) –
  • offset (float) –
  • dataUnit (str) – unit of the data
  • invertX (int) – True to invert the X axis
  • invertY (int) – True to invert the Y axis
  • invertZ (int) – True to invert the Z axis
  • axesTransformation (int) – 0-> XYZ, 1->XZY, 2->YXZ, 3->YZX, 4->ZXY, 5->ZYX
  • datasetName (str) – name of created dataset
Returns:

output (ORSModel.ors.Channel) [count=[0, None]] – Created dataset

interfacemethod createDatasetsDeterminingGeometryFromFiles(fileNames)

Creates one of more datasets from a set of files.

Parameters:fileNames (file) [count=[0, None]] – fully qualified file names
Returns:output (ORSModel.ors.Channel) [count=[0, None]] – Created dataset(s)
createImagesFromFiles(fileNames)
hideOtherLoadersControl()
lib = None
libName = 'OrsImageLoader.dll'
openUIOnFiles(stringifiedFileNames)
populateImageFromFile(image=None, filename=None)
startGui()
classmethod startOtherLoader(pluginName)

Helper method to instantiate another loader plugin :param pluginName: a plugin name :return: bool

orsimagesaver

Exports datasets to various file formats

Portions LIBTIFF

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:May 20 2015 16:46
dragonflyVersion:
 3.0
UUID:2e2f8cd2762711e79e3c448a5b5d70c0
class OrsPlugins.orsimagesaver.OrsImageSaver(varname=None, managed=True)
interfacemethod exportChannel(channel, fileName, extension='tif')

Exports a dataset to file.

Parameters:
  • channel (ORSModel.ors.Channel) – dataset to export
  • fileName (file saving) – fully qualified file name
  • extension (str) – image file format extension
Returns:

output (bool) – True or False

interfacemethod exportDatasetToFile(dataset, fileName, outputType, showProgress)

Exports a dataset to file.

Parameters:
  • dataset (str) – dataset to export
  • fileName (file saving) – fully qualified file name
  • outputType (str) – Type of file (‘raw’, ‘orsobject’, ‘hdr’)
  • showProgress (bool) – True to show a progress bar
Returns:

output (bool) – True or False

interfacemethod exportDatasetToGDT1(dataset, fileName)

Exports a dataset to GDT1.

Parameters:
  • dataset (str) – dataset to export
  • fileName (file saving) – fully qualified file name
Returns:

output (bool) – True or False

interfacemethod exportDatasetToJpegFile(dataset, fileName, imageQuality, showProgress)

Exports a dataset to jpeg.

Parameters:
  • dataset (str) – dataset to export
  • fileName (file saving) – fully qualified file name
  • imageQuality (int) – image quality of export file
  • showProgress (bool) – True to show a progress bar
Returns:

output (bool) – True or False

interfacemethod exportDatasetToRAWFile(dataset, fileName, exportMultiFrameFile, showProgress)

Exports a dataset to RAW.

Parameters:
  • dataset (str) – dataset to export
  • fileName (file saving) – fully qualified file name
  • exportMultiFrameFile (bool) – True to export all data into one output file (multi-frame)
  • showProgress (bool) – True to show a progress bar
Returns:

output (bool) – True or False

interfacemethod exportDatasetToTiffFile(dataset, fileName, useLZWCompression, exportMultiFrameFile, showProgress)

Exports a dataset to TIFF.

Parameters:
  • dataset (str) – dataset to export
  • fileName (file saving) – fully qualified file name
  • useLZWCompression (bool) – True to compress the output file
  • exportMultiFrameFile (bool) – True to export all slices into one output file (multi-frame)
  • showProgress (bool) – True to show a progress bar
Returns:

output (bool) – True or False

interfacemethod exportImageCollectionToFilePattern(imageCollection, fileNamePattern)

Exports all the images contained in the image collection using a file name pattern

Parameters:
  • imageCollection (ORSModel.ors.ImageCollection) – image collection containing all the images to export
  • fileNamePattern (file saving) – file name pattern. It has the format of a regular file. If there is exactly 1 image in the image collection, the output file corresponding to that image will have that name. If there are more than 1 image in the image collection, the output file corresponding to each image will use the provided file name as a root, and the suffix “i” will be added, where “i” is the index (1 based) of the image in the image collection.
Returns:

output (bool) – True if successful; False otherwise

interfacemethod exportImageToFile(image, fileName)

This is the official interface to export an image (scriptable)

Parameters:
  • image (ORSModel.ors.Image) – image to export
  • fileName (file saving) – fully qualified file name
Returns:

output (bool) – True or False

lib = None
libName = 'OrsImageSaver.dll'
setOutputToAutomaticallyIncludeWLValues()
startGuiForDataset(datasetGUID)

orsmeshloader

Imports meshes from files

Portions VTK

Portions Open CASCADE

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Nov 12 2015 14:38
dragonflyVersion:
 3.0
UUID:3e44f376762711e79f3c448a5b5d70c0
class OrsPlugins.orsmeshloader.OrsMeshLoader(varname=None, managed=True)
classmethod OpenUIOnRecentFileEntry(entry)

Helper interface to start the gui, prepopulating the files list :param entry: a saved recent file entry :return: None

classmethod convertVTKToORSForLoader(outOrsMesh, vtkPolyDataAddr, itIndex=0)

This method convert a vtk mesh to an ORS one. It’s a simplified call for the loader. For the full helper, please use VtkPolyDataToFromOrsMeshHelper class

lib = None
libName = 'OrsMeshLoader.dll'
interfacemethod loadMeshFromFile(filename, showProgress, progress=None)

Import a mesh from a file.

Parameters:
  • filename (file) – fully qualified file name
  • showProgress (bool) – show a progress bar while exporting
  • progress (ORSModel.ors.Progress) – progress bar
Returns:

output (ORSModel.ors.Mesh) – mesh created

startGui()

orsmeshsaver

Exports meshes to various file formats

Portions VTK

Portions Open CASCADE

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Nov 13 2015 08:34
dragonflyVersion:
 3.0
UUID:64c8741e762711e7a9b1448a5b5d70c0
class OrsPlugins.orsmeshsaver.OrsMeshSaver(varname=None, managed=True)
interfacemethod exportMeshToFile(mesh, lut, filename, centerAtOrigin, outputUnitID, exportAsASCII, exportColors, showProgress)

Exports a mesh to a file.

Parameters:
  • mesh (ORSModel.ors.Mesh) – source mesh
  • lut (ORSModel.ors.LookupTable) – mesh lookup table
  • filename (file saving) – fully qualified file name
  • centerAtOrigin (bool) – center the mesh at origin or not
  • outputUnitID (int) – output unit ID
  • exportAsASCII (bool) – export as ASCII or binary
  • exportColors (bool) – export colors
  • showProgress (bool) – show a progress bar while exporting
Returns:

output (int) – Return code (0 if succeeded)

lib = None
libName = 'OrsMeshSaver.dll'
startGuiForDataset(datasetGUID, lutGUID)
classmethod writeVTKFile(vtkMesh, fileName)

Write a .vtk with a vtk mesh.

Returns:output – 0 if worked, else 1
classmethod writeVTPFile(vtkMesh, fileName)

Write a .vtk with a vtk mesh.

Returns:output – 0 if worked, else 1

orspreferences

Manages user preferences

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Nov 15 2015 11:40
dragonflyVersion:
 3.0
UUID:76e108c0762711e79e58448a5b5d70c0
class OrsPlugins.orspreferences.OrsPreferences(varname=None, managed=True)
lib = None
libName = 'OrsPreferences.dll'

orsqtemptyloader

Tool to create datasets from scratch

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Feb 23 2015 15:44
dragonflyVersion:
 3.0
UUID:8ac6fda4762711e78298448a5b5d70c0
class OrsPlugins.orsqtemptyloader.OrsQtEmptyLoader(varname=None, managed=True)
interfacemethod createChannel(title, dataType, sizeX, sizeY, sizeZ, sizeT, spacingX, spacingY, spacingZ, offset, slope, addNoise, gaussian, noiseStdDev, initValue, progress)

Creates a dataset from parameters.

Parameters:
  • title (str) – title of the dataset
  • dataType (int) – data type. 0: unsigned byte; 2: unsigned short; 4: unsigned int; 6: float.
  • sizeX (int) – X size
  • sizeY (int) – Y size
  • sizeZ (int) – Z size
  • sizeT (int) – T size
  • spacingX (float) – X spacing (in meters)
  • spacingY (float) – Y spacing (in meters)
  • spacingZ (float) – Z spacing (in meters)
  • offset (float) –
  • slope (float) –
  • addNoise (bool) – if True, noise will be added
  • gaussian (bool) – if True, the added noise will have a gaussian distribution
  • noiseStdDev (float) – noise standard deviation
  • initValue (float) – initial value put in each voxel
  • progress (ORSModel.ors.Progress) – progress object
Returns:

output (ORSModel.ors.Channel) [count=1] – Created dataset

classmethod getMainFormTitle()
lib = None
libName = 'OrsQtEmptyLoader.dll'
showInToolbar = True
startGui()

orsqthelp

Manages help

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Jun 15 2015 11:18
dragonflyVersion:
 3.0
UUID:d66b0064762711e78289448a5b5d70c0
class OrsPlugins.orsqthelp.OrsQtHelp(varname=None, managed=True)
lib = None
libName = 'OrsQtHelp.dll'

orsqtlayout

Manages the renderer and window layouts

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Feb 23 2015 15:44
dragonflyVersion:
 3.0
UUID:f3b5d226762711e78923448a5b5d70c0
class OrsPlugins.orsqtlayout.OrsQtLayout(varname=None, managed=True)
addMovieKeyFrame(timeFrame)
classmethod addMovieKeyFrameActionCall()
interfacemethod addMovieKeyFrameInCurrentView(timeFrame=-3, timeInSeconds=True)

Adds a key frame to the Movie Maker for the current selected view

Parameters:
  • timeFrame (int) – time of the new key frame. If <0, the new key frame will be appended at the end by the passed offset. Default: -3.
  • timeInSeconds (bool) – True if the timeFrame parameter is specified as seconds and not frames Default: True.
addMovieRotationKeyFrame(direction, angle, duration)
interfacemethod addMovieRotationKeyFrameInCurrentView(direction, angle, duration=3)

Adds a key frame to the Movie Maker for the current selected view

Parameters:
  • direction (int) – direction of the rotation. 1,2: roll +/-, 3,4: Yaw +/-, 5,6: Pitch +/-
  • angle (int) – the angle of rotation in degrees.
  • duration (int) – duration of the rotation. Default: 3 seconds.
canDisplayMeshWithNumberOfTriangles(nbTriangles, bScalarMesh)
interfacemethod closeMovieMaker()

Closes the Movie Maker

deleteMovie()
interfacemethod deleteMovieInCurrentView()

Removes all key frames and deletes the movie

deleteSelectedKeyframe()
deleteSelectedKeyframeInCurrentView()
displayCanDisplayAnotherVolume(displayGUID)
enableSeriesLayoutControls(bEnable)
exportAVI(foldername, width, height, fps, startFrame, endFrame)
interfacemethod exportAVIInCurrentView(filename, width, height, fps=30, startFrame=0, endFrame=-1)

Export a sequence of images from the Movie Maker for the current selected view

Parameters:
  • filename (file saving) – file name of the movie
  • width (int) – the width of the movie.
  • height (int) – the height of the movie.
  • fps (int) – frame rate of the movie. Default is 30 fps.
  • startFrame (int) – time of the start of the movie. Default: 0 seconds.
  • endFrame (int) – time of the end of the movie. Default: -1 seconds.
exportFrameSequence(foldername, width, height, startFrame, endFrame)
interfacemethod exportFrameSequenceInCurrentView(foldername, width, height, startFrame=0, endFrame=-1)

Export a sequence of images from the Movie Maker for the current selected view

Parameters:
  • foldername (folder saving) – folder were the images will be exported
  • width (int) – the width of the movie.
  • height (int) – the height of the movie.
  • startFrame (int) – time of the start of the movie. Default: 0 seconds.
  • endFrame (int) – time of the end of the movie. Default: -1 seconds.
forceDraw()

Forces a draw on the current view

getAxisIndicatorIsShownInCurrentDisplay()
getFrameForAddMovieKeyFrame()
getIsMovieSaverVisibleInCurrentView()
getProperty(visualGUID, displayGUID, propertyName)
isDelayRespectedToCallAddMovieKeyFrame()
isDelayRespectedToCallShowMovieSaver()
lib = None
libName = 'OrsQtLayout.dll'
interfacemethod openMovieMaker()

Opens the Movie Maker

pluginContainsDisplayGUID(displayGUID)
setAxisIndicatorIsShownInCurrentDisplay(bEnable)
setAxisIndicatorModeInCurrentDisplay(iMode)
setOrthoModeInCurrentDisplay(bUse)
setProperty(visualGUID, displayGUID, propertyName, value, applyToAllDisplays, logAction)
setRotationInCurrentView(bStop)
showMovieSaver()

Toggles the visibility of the Movie Maker

showRenderTargetViewer()
startServer(address, iPort)
toggleExclusiveMode()
classmethod toggleExclusiveModeInCurrentView()
toggleMovieSaverVisibility()

Toggles the visibility of the Movie Maker

toggleVisibilityMovieSaverInCurrentView()

orsqtmaincontext

Manages the main window of the application

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Mar 30 2015 12:26
dragonflyVersion:
 3.0
UUID:1234279e762811e7b42e448a5b5d70c0
class OrsPlugins.orsqtmaincontext.OrsQtMainContext(modalContext=False, restrictPlugins=False, privateObjects=False)

Context plugin, supporting central, left, right, up and down plugin dispositions.

libName = 'OrsQtMainContext.dll'
loadFromLastAutosave()
classmethod loadFromLastAutosaveFor(varName)
loadWorkspace()
classmethod loadWorkspaceFor(varName)
loadWorkspaceFrom()
classmethod loadWorkspaceFromFor(varName)
resetWorkspace()
classmethod resetWorkspaceFor(varName)
saveWorkspace()
saveWorkspaceAs()
classmethod saveWorkspaceAsFor(varName)
classmethod saveWorkspaceFor(varName)
setState(state)

orsqtplugingenerator

Plugin used to generate the basic files of a new C++ plugins

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:Jun 01 2015 12:58
dragonflyVersion:
 3.0
UUID:3683c3ca762811e79bdd448a5b5d70c0
class OrsPlugins.orsqtplugingenerator.OrsQtPluginGenerator(varname=None, managed=True)
lib = None
libName = 'OrsQtPluginGenerator.dll'

orsqtpluginviewer

Debugging tool to analyze plugin contents

author:ORS Team
contact:http://theobjects.com
email:info@theobjects.com
organization:Object Research Systems (ORS), Inc.
address:760 St-Paul West, suite 101, Montréal, Québec, Canada, H3C 1M4
copyright:Object Research Systems (ORS), Inc. All rights reserved 2020.
date:May 15 2015 12:16
dragonflyVersion:
 3.0
UUID:712dea4c762911e79a03448a5b5d70c0
class OrsPlugins.orsqtpluginviewer.OrsQtPluginViewer(varname=None, managed=True)
lib = None
libName = 'OrsQtPluginViewer.dll'