# Development

**URL:** https://discourse.slicer.org/c/dev/5.md?no_subcategories=false&page=36

[Latest](https://discourse.slicer.org/latest.md) · [Categories](https://discourse.slicer.org/categories.md) · [Tags](https://discourse.slicer.org/tags.md)

**Page:** 37

---

## [Building 3D Slicer for use in another C++ project](https://discourse.slicer.org/t/building-3d-slicer-for-use-in-another-c-project/29650)

<div class="topic-metadata">

**Author:** [@Robotech7](https://discourse.slicer.org/u/Robotech7)\
**Replies:** 6\
**Last updated:** [May 26, 2023, 6:53am UTC](https://discourse.slicer.org/t/building-3d-slicer-for-use-in-another-c-project/29650 "2023-05-26T06:53:50Z")

</div>

Hello, please let me know if it is possible to build the 3D Slicer source code as libraries for reuse in another C++ project without significant modifications to the CMakeLists.txt files. I only need the /Modules/Loadabl…

---

## [Centering on a segment from a script](https://discourse.slicer.org/t/centering-on-a-segment-from-a-script/6209)

<div class="topic-metadata">

**Author:** [@fedorov](https://discourse.slicer.org/u/fedorov)\
**Replies:** 18\
**Last updated:** [May 25, 2023, 3:56pm UTC](https://discourse.slicer.org/t/centering-on-a-segment-from-a-script/6209 "2023-05-25T15:56:07Z")

</div>

I would like to invoke in a script “Jump slices” functionality of Segment Editor. I found jumpSlices(), but have not figured out yet how to invoke it, given Segmentation node and ID of the segment that I need to jump to. …

---

## [Log window cannot be hidden in enviroments with no windows manager](https://discourse.slicer.org/t/log-window-cannot-be-hidden-in-enviroments-with-no-windows-manager/29633)

<div class="topic-metadata">

**Author:** [@Davide\_Punzo](https://discourse.slicer.org/u/Davide_Punzo)\
**Replies:** 3\
**Last updated:** [May 25, 2023, 8:05am UTC](https://discourse.slicer.org/t/log-window-cannot-be-hidden-in-enviroments-with-no-windows-manager/29633 "2023-05-25T08:05:27Z")

</div>

Hi all, the log messages widget is a separate window respect the main one of 3DSlicer. This is not optimal when Slicer is in an enviroment with no windows manager (e.g. Slicer running in a docker with vnc). For exam…

---

## [Running the python script without the opening of slicer window](https://discourse.slicer.org/t/running-the-python-script-without-the-opening-of-slicer-window/29629)

<div class="topic-metadata">

**Author:** [@Mani\_Barathi](https://discourse.slicer.org/u/Mani_Barathi)\
**Replies:** 1\
**Last updated:** [May 24, 2023, 1:44pm UTC](https://discourse.slicer.org/t/running-the-python-script-without-the-opening-of-slicer-window/29629 "2023-05-24T13:44:00Z")

</div>

I need to get output in my own developed UI not in the Slicer. Can you please help me with this ?

---

## [Can I reproduction of change in body shape](https://discourse.slicer.org/t/can-i-reproduction-of-change-in-body-shape/29579)

<div class="topic-metadata">

**Author:** [@sotarad](https://discourse.slicer.org/u/sotarad)\
**Replies:** 2\
**Last updated:** [May 24, 2023, 12:18am UTC](https://discourse.slicer.org/t/can-i-reproduction-of-change-in-body-shape/29579 "2023-05-24T00:18:20Z")

</div>

Hi all. I want to transform OAR volume into smaller in order to reproduct of change in body shape. Finaly, I want to get DVFs that shrink some OARs. I think if I could get DVF from contour base DIR, the challenge will …

---

## [compiler slicer error](https://discourse.slicer.org/t/compiler-slicer-error/29574)

<div class="topic-metadata">

**Author:** [@ma1282029525](https://discourse.slicer.org/u/ma1282029525)\
**Replies:** 6\
**Last updated:** [May 23, 2023, 10:17pm UTC](https://discourse.slicer.org/t/compiler-slicer-error/29574 "2023-05-23T22:17:09Z")

</div>

46\> moc\_qSlicerApplication.cpp 46\>E:\\Slicer\_all\\SlicerBuild\\Slicer-build\\Base\\QTGUI\\moc\_qSlicerApplication.cpp(280,20): error C2065: “ctkQtTestingUtility”: 未声明的标识符 \[E:\\Slicer\_all\\SlicerBuild\\Slicer-build\\Base\\QTGUI\\qSli…

---

## [MarkUps Angle measurement numerical value](https://discourse.slicer.org/t/markups-angle-measurement-numerical-value/29505)

<div class="topic-metadata">

**Author:** [@esomjai](https://discourse.slicer.org/u/esomjai)\
**Replies:** 2\
**Last updated:** [May 22, 2023, 12:20pm UTC](https://discourse.slicer.org/t/markups-angle-measurement-numerical-value/29505 "2023-05-22T12:20:01Z")

</div>

I was wondering if there’s an equivalent of the script used to assign linear measurement copying to keyboard shortcuts for angle measurement numerical values? def copyLineMeasurementsToClipboard(): measurements = \[\] …

---

## [Cannot import gmsh Python package](https://discourse.slicer.org/t/cannot-import-gmsh-python-package/29344)

<div class="topic-metadata">

**Author:** [@Saima](https://discourse.slicer.org/u/Saima)\
**Replies:** 13\
**Last updated:** [May 21, 2023, 12:17am UTC](https://discourse.slicer.org/t/cannot-import-gmsh-python-package/29344 "2023-05-21T00:17:23Z")

</div>

Hi Andras, Slicer exit abnormally when I try to initialize gmsh in an extension but it did work with the built version of slicer but not with the executable version of slicer. could you please help to resolve? Python …

---

## [How to make markupsnode follow mouse cursor](https://discourse.slicer.org/t/how-to-make-markupsnode-follow-mouse-cursor/29532)

<div class="topic-metadata">

**Author:** [@dsa934](https://discourse.slicer.org/u/dsa934)\
**Replies:** 4\
**Last updated:** [May 19, 2023, 4:54pm UTC](https://discourse.slicer.org/t/how-to-make-markupsnode-follow-mouse-cursor/29532 "2023-05-19T16:54:28Z")

</div>

Operating system: window 10 Slicer version: 5.2.1 When you click on the markup node above in Slicer’s GUI interface, the markup node will follow the mouse cursor until it generates a mouse click event in the 3D vi…

---

## [Printing in Python CLI modules](https://discourse.slicer.org/t/printing-in-python-cli-modules/29516)

<div class="topic-metadata">

**Author:** [@benzwick](https://discourse.slicer.org/u/benzwick)\
**Replies:** 5\
**Last updated:** [May 19, 2023, 6:15am UTC](https://discourse.slicer.org/t/printing-in-python-cli-modules/29516 "2023-05-19T06:15:41Z")

</div>

When I print in a Python CLI module, all the messages are displayed after the module has completed. Is there any way to print the messages as they occur in real time during execution?

---

## [Nearest Neighbor implementation](https://discourse.slicer.org/t/nearest-neighbor-implementation/29529)

<div class="topic-metadata">

**Author:** [@osmandogan](https://discourse.slicer.org/u/osmandogan)\
**Replies:** 2\
**Last updated:** [May 18, 2023, 10:23pm UTC](https://discourse.slicer.org/t/nearest-neighbor-implementation/29529 "2023-05-18T22:23:22Z")

</div>

Hello. I am doing a volume crop operation in a study I have been working on. And I want to use the “Nearest Neighborn” feature from the interpolator features in the “Volume Crop” module. How can I add the “Nearest Neighb…

---

## [How to use observer?](https://discourse.slicer.org/t/how-to-use-observer/29526)

<div class="topic-metadata">

**Author:** [@dsa934](https://discourse.slicer.org/u/dsa934)\
**Replies:** 1\
**Last updated:** [May 18, 2023, 7:14pm UTC](https://discourse.slicer.org/t/how-to-use-observer/29526 "2023-05-18T19:14:34Z")

</div>

Operating system: window 10 Slicer version: 5.2.1 Whenever a new node is added to the scene, I know that observer is used to process the function for the added node. (ref: Stanford bunny) I would like to implement…

---

## [segment statistics 123](https://discourse.slicer.org/t/segment-statistics-123/29530)

<div class="topic-metadata">

**Author:** [@Siva\_sai\_Kumar](https://discourse.slicer.org/u/Siva_sai_Kumar)\
**Replies:** 1\
**Last updated:** [May 18, 2023, 6:57pm UTC](https://discourse.slicer.org/t/segment-statistics-123/29530 "2023-05-18T18:57:36Z")

</div>

Good afternoon everyone, I wanted to know about what the 'segment statistics" are. how are it being useful in any bone segments. what is the inference about segment statistics thank u sir

---

## [How to import Qt in Python scripted CLI module?](https://discourse.slicer.org/t/how-to-import-qt-in-python-scripted-cli-module/29509)

<div class="topic-metadata">

**Author:** [@benzwick](https://discourse.slicer.org/u/benzwick)\
**Replies:** 5\
**Last updated:** [May 17, 2023, 5:12pm UTC](https://discourse.slicer.org/t/how-to-import-qt-in-python-scripted-cli-module/29509 "2023-05-17T17:12:23Z")

</div>

Is it possible to import Qt inside a Python scripted CLI module? I want to display an error message to tell the user to modify the input parameters. When I try to import qt I get the following error: Traceback (most rec…

---

## [Cloning a SegmentationNode segment in Python](https://discourse.slicer.org/t/cloning-a-segmentationnode-segment-in-python/29035)

<div class="topic-metadata">

**Author:** [@pearsonm](https://discourse.slicer.org/u/pearsonm)\
**Replies:** 4\
**Last updated:** [May 17, 2023, 4:23am UTC](https://discourse.slicer.org/t/cloning-a-segmentationnode-segment-in-python/29035 "2023-05-17T04:23:29Z")

</div>

I am working on a module where I make a make a binary labelmap on a 2d view with the scissors rectangle tool. The next step is to cut the rectangle into 3 regions for further processing. My first approach was to add 3 s…

---

## [About logic in Scissor tool](https://discourse.slicer.org/t/about-logic-in-scissor-tool/29469)

<div class="topic-metadata">

**Author:** [@phtran.dev](https://discourse.slicer.org/u/phtran.dev)\
**Replies:** 1\
**Last updated:** [May 16, 2023, 4:47am UTC](https://discourse.slicer.org/t/about-logic-in-scissor-tool/29469 "2023-05-16T04:47:03Z")

</div>

Hi, I am trying to dig out Slicer code into my Application with free cut feature. I am debugging Free cut feature in Scissor tool. When I run to function : bool qSlicerSegmentEditorScissorsEffectPrivate::updateBrushSte…

---

## [Totalsegmentator --- practise data](https://discourse.slicer.org/t/totalsegmentator-practise-data/29428)

<div class="topic-metadata">

**Author:** [@whu](https://discourse.slicer.org/u/whu)\
**Replies:** 5\
**Last updated:** [May 15, 2023, 11:23am UTC](https://discourse.slicer.org/t/totalsegmentator-practise-data/29428 "2023-05-15T11:23:27Z")

</div>

After installing the Totalsegmentator extensions successfully. I found little problem in the visualization. Firstly, when using the example CTA data, when “Show 3D”, the result is: and the local detail is like this,…

---

## [Obtaining/Creating 4x4 Transformation matrix to the location of a vtkMRMLCameraNode](https://discourse.slicer.org/t/obtaining-creating-4x4-transformation-matrix-to-the-location-of-a-vtkmrmlcameranode/29461)

<div class="topic-metadata">

**Author:** [@akumar81](https://discourse.slicer.org/u/akumar81)\
**Replies:** 1\
**Last updated:** [May 14, 2023, 1:56pm UTC](https://discourse.slicer.org/t/obtaining-creating-4x4-transformation-matrix-to-the-location-of-a-vtkmrmlcameranode/29461 "2023-05-14T13:56:03Z")

</div>

I’m currently working on a project where I control the position of a vtkCameraNode in 3D view with a robotic arm. To achieve this, I’ve been placing the camera node on top of a transform like so: camera\_node.SetNodeRef…

---

## [How to segment muscle in TotalSegmentator](https://discourse.slicer.org/t/how-to-segment-muscle-in-totalsegmentator/29425)

<div class="topic-metadata">

**Author:** [@jay1987](https://discourse.slicer.org/u/jay1987)\
**Replies:** 2\
**Last updated:** [May 13, 2023, 1:59pm UTC](https://discourse.slicer.org/t/how-to-segment-muscle-in-totalsegmentator/29425 "2023-05-13T13:59:22Z")

</div>

i use total segmentator to segment ct , the result is the doctor want to segment the muscule into the red area and the yellow area use total segmentator seems can’t Meeting the needs of doctors(Maybe the steps I u…

---

## [How to set VR camera position in Python?](https://discourse.slicer.org/t/how-to-set-vr-camera-position-in-python/29418)

<div class="topic-metadata">

**Author:** [@Gianluca\_De\_Lucia](https://discourse.slicer.org/u/Gianluca_De_Lucia)\
**Replies:** 1\
**Last updated:** [May 12, 2023, 10:02am UTC](https://discourse.slicer.org/t/how-to-set-vr-camera-position-in-python/29418 "2023-05-12T10:02:15Z")

</div>

Hi, I am trying to develop a Python script for viewing an STL file through your VR module for 3DSlicer. I need to set up the camera position, but as far I didn’t succeed. I tried with: slicer.modules.virtualreality.…

---

## [Maintenance of slicer-packages.kitware.com: Removed preview packages older than r30811 (v5.0.0)](https://discourse.slicer.org/t/maintenance-of-slicer-packages-kitware-com-removed-preview-packages-older-than-r30811-v5-0-0/29407)

<div class="topic-metadata">

**Author:** [@jcfr](https://discourse.slicer.org/u/jcfr)\
**Replies:** 2\
**Last updated:** [May 11, 2023, 9:44pm UTC](https://discourse.slicer.org/t/maintenance-of-slicer-packages-kitware-com-removed-preview-packages-older-than-r30811-v5-0-0/29407 "2023-05-11T21:44:24Z")

</div>

Preview application and extension packages older than r30811 (v5.0.0) have been removed from the slicer-packages.kitware.com server. 254 preview (aka draft) release folders removed. Before After List o…

---

## [How to release an extension](https://discourse.slicer.org/t/how-to-release-an-extension/26289)

<div class="topic-metadata">

**Author:** [@ebrahim](https://discourse.slicer.org/u/ebrahim)\
**Replies:** 7\
**Last updated:** [May 11, 2023, 7:22pm UTC](https://discourse.slicer.org/t/how-to-release-an-extension/26289 "2023-05-11T19:22:10Z")

</div>

When creating a purely scripted (i.e. python only) Slicer extension, what is a good release “object” to create and how do I create it? Ideally I want something that I can use with the extension manager’s Install from fi…

---

## [Issues separating logic, widget and main classes](https://discourse.slicer.org/t/issues-separating-logic-widget-and-main-classes/29204)

<div class="topic-metadata">

**Author:** [@asyeda](https://discourse.slicer.org/u/asyeda)\
**Replies:** 3\
**Last updated:** [May 9, 2023, 1:37pm UTC](https://discourse.slicer.org/t/issues-separating-logic-widget-and-main-classes/29204 "2023-05-09T13:37:54Z")

</div>

I am trying to separate my module into separate files for readability, and I’ve structured it similar to the Slicer DataProbe: Slicer/Modules/Scripted/DataProbe at 01984729eca68f0417ead58d87d3358912f094d4 · Slicer/Slicer…

---

## [Select point (user input) on 3D surface for 2000 surfaces automatically opening after user selects a point](https://discourse.slicer.org/t/select-point-user-input-on-3d-surface-for-2000-surfaces-automatically-opening-after-user-selects-a-point/29164)

<div class="topic-metadata">

**Author:** [@Saima](https://discourse.slicer.org/u/Saima)\
**Replies:** 3\
**Last updated:** [May 9, 2023, 8:39am UTC](https://discourse.slicer.org/t/select-point-user-input-on-3d-surface-for-2000-surfaces-automatically-opening-after-user-selects-a-point/29164 "2023-05-09T08:39:38Z")

</div>

Hi Andras, Would it be possible to select the point (x,y,z) location in a ply file, for all the ply files opening up one by one and closing once the point is selected. The point needed to be selected by the user on the…

---

## [Prevent extra folder on dicom export](https://discourse.slicer.org/t/prevent-extra-folder-on-dicom-export/19645)

<div class="topic-metadata">

**Author:** [@stephan13](https://discourse.slicer.org/u/stephan13)\
**Replies:** 4\
**Last updated:** [May 3, 2023, 1:59pm UTC](https://discourse.slicer.org/t/prevent-extra-folder-on-dicom-export/19645 "2023-05-03T13:59:52Z")

</div>

Hi there Exporting a volume to DICOM from the Data module does not place all DICOM files inside of the selected folder, but creates an extra one on the same level. Is there an option to prevent the extra folder?

---

## [Got the wrong color on the cell](https://discourse.slicer.org/t/got-the-wrong-color-on-the-cell/16645)

<div class="topic-metadata">

**Author:** [@jackxiong](https://discourse.slicer.org/u/jackxiong)\
**Replies:** 8\
**Last updated:** [May 3, 2023, 8:56am UTC](https://discourse.slicer.org/t/got-the-wrong-color-on-the-cell/16645 "2023-05-03T08:56:21Z")

</div>

Hi guys, I’m new to Slicer and VTK library, for some special requirements, I need to set different cell to different color on the surface, so I have such draft code as below: # Hide the cube v = slicer.util.getNode('Vi…

---

## [RAS Coordinate system != World Coordinate system?](https://discourse.slicer.org/t/ras-coordinate-system-world-coordinate-system/29024)

<div class="topic-metadata">

**Author:** [@dsa934](https://discourse.slicer.org/u/dsa934)\
**Replies:** 9\
**Last updated:** [May 3, 2023, 7:28am UTC](https://discourse.slicer.org/t/ras-coordinate-system-world-coordinate-system/29024 "2023-05-03T07:28:17Z")

</div>

Operating system: window 10 Slicer version: 5.2.1 Hi, I have a question about coordinate systems. After some experimentation, I found out that the direction of the x,y axis in the WCS( world coordinate system) and …

---

## [How to convert a model into a volume and then compress it into a plane (volume) in a direction?](https://discourse.slicer.org/t/how-to-convert-a-model-into-a-volume-and-then-compress-it-into-a-plane-volume-in-a-direction/28983)

<div class="topic-metadata">

**Author:** [@jumbojing](https://discourse.slicer.org/u/jumbojing)\
**Replies:** 6\
**Last updated:** [May 3, 2023, 4:07am UTC](https://discourse.slicer.org/t/how-to-convert-a-model-into-a-volume-and-then-compress-it-into-a-plane-volume-in-a-direction/28983 "2023-05-03T04:07:43Z")

</div>

How to convert a model into a volume and then compress it into a plane (a volume with one slice) in a direction? @lassoan@pieper@Juicy@jamesobutler @jcfr

---

## [Slowness when calling SetBackgroundVolumeID() to show data in Yellow slice view](https://discourse.slicer.org/t/slowness-when-calling-setbackgroundvolumeid-to-show-data-in-yellow-slice-view/29258)

<div class="topic-metadata">

**Author:** [@Mubariz\_Afzal](https://discourse.slicer.org/u/Mubariz_Afzal)\
**Replies:** 1\
**Last updated:** [May 2, 2023, 7:34pm UTC](https://discourse.slicer.org/t/slowness-when-calling-setbackgroundvolumeid-to-show-data-in-yellow-slice-view/29258 "2023-05-02T19:34:52Z")

</div>

Hi all, We are working on an extension to 3D Slicer that often uses a large number of small images (\>100). However I came across some consistent slowness that is seen when using the SetBackgroundVolumeID() function. I …

---

## [Let user place markups node](https://discourse.slicer.org/t/let-user-place-markups-node/29169)

<div class="topic-metadata">

**Author:** [@devD](https://discourse.slicer.org/u/devD)\
**Replies:** 1\
**Last updated:** [May 2, 2023, 10:36am UTC](https://discourse.slicer.org/t/let-user-place-markups-node/29169 "2023-05-02T10:36:45Z")

</div>

I am trying to make a simple script. I have created a button which the user can press. When the button is pressed, the user should then be prompted to place one markups node, when this node is placed the user should the…

[Previous page](https://discourse.slicer.org/c/dev/5.md?no_subcategories=false&page=35)

[Next page](https://discourse.slicer.org/c/dev/5.md?no_subcategories=false&page=37)
