# RT-VIEWER **Repository Path**: clementz/RT-VIEWER ## Basic Information - **Project Name**: RT-VIEWER - **Description**: Web/App based DICOM RT Viewer - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2024-06-30 - **Last Updated**: 2024-06-30 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # RT VIEWER ![fullscreen](https://user-images.githubusercontent.com/44565579/100818642-e57ade80-348d-11eb-9b5b-e9dd6bebb0d9.PNG) RT Viewer - Can overlay CT IMAGE, DOSE, and RT STRUCTURE - This project based on TEST849 ## Getting Started 1. Git Clone : https://github.com/choijinkyung/DICOM-RT-VIEWER 2. Installing Node.js 3. Installing npm or yarn 4. Run Scripts
4-1) npm run install or yarn install
-> install package json 5. For start
5-1 ) npm run start or yarn start
-> Create a Web page through the local host and port 3000 ## Prerequisites 1. PreKnowledge
1) Coordinate transformation
We can get two matrices.
1-1) Dose - > Patient matrix
1-2) CT -> Patient matrix

In other words, to convert coordinates to Dose -> CT, Dose -> Patient -> CT is required.
-> To obtain -> Patient -> CT, CT -> Patient matrix must be inverse.
-> Dose2CT transformation matrix = (Dose 2Patient) * (Patinet2CT)
-> Dose2CT * (x, y, z, 1) converts the coordinates (x, y, z).
-> 1 is the vector and 0 is the point.
-> See c7.6.2.1.1 of DICOM standard for more information.
(requires knowledge of the transform or scaling side of a three-dimensional matrix) 2) Obtain Dose Value
-> RT DOSE pixelData(x7fe00010)
-> RT DOSE Dose Grid Scaling (x3004000e)
-> DOSE Value = pixelData * DoseGridScaling 3) Import Sub-Data in DICOM file
-> Original : DB import & use Class
-> Present : cornerstone.js (GitHub) - > dicomParser -> liveExample -> DICOM DUMP
-> https://rawgit.com/cornerstonejs/dicomParser/master/examples/index.html
-> click F12 & show developer tool
-> We analyzed this source and imported the data in the hierarchy.
-> In Project, Referenced Code Like getROIList -> structFile , ROIListHierarchy , getContourData
(Output to output shows hierarchical) 4) Cornerstone
-> Github : https://github.com/cornerstonejs
-> Example : https://cornerstonejs.org/ 5) Zoom, pan event
-> Use React-map-Interaction opensource
-> After, Divided mouse event 6) Open Source
-> Dcmjs : DICOM parser library like cornerstone
-> Mathjs : Can be used like python for matrix operations
-> Jsdoc : Documentation Tool 7) Document
-> Word : WebViewer_API_document
-> JSDOC API documentation (Recommended)
: Easier to see when Developing 2. Environment setting 1) Window 2) Webstorm 3) Node.js
- Version :12.18.3 4) Package Manager 1) yarn
- version : 1.22.5 2) npm
- version : 6.14.6 ## Module install 1. npm install cornerstone 2. npm install cornerstone-core
version : "cornerstone-core": "^2.3.0" 3. npm install cornerstone-math
version : "cornerstone-math": "^0.1.9" 4. npm install cornetstone-tools
version : "cornerstone-tools": "^5.0.0" 5. npm install conrnerstone-wado-image-loader
version : "cornerstone-wado-image-loader": "^3.1.2" 6. npm install hammerjs
version :"hammerjs": "^2.0.8" 7. npm install mathjs
version :"mathjs": "^8.0.1" 8. npm install cross
version : "cross": "^1.0.0" 9. npm install gh-pages
version : "gh-pages" : "^3.1.0" 10. npm install react
version : "react": "^16.14.0" 11. npm install react-dom
version : "react-dom": "^16.14.0" 12. npm install react-map-interatcion
version : "react-map-interaction": "^2.0.0" 13. npm install react scripts
version : "react-scripts": "^3.4.3" 14. npm install webkit
version :"webkit": "^0.0.0" 15. npm install jsdoc docdash
version :"jsdoc" : "^3.6.6" 16. npm install jquery
version : "jquery" : "^3.5.1" To install at once
-> npm install or yarn install ## Deployment 1. npm install gh-pages 2. In package.json,
"scripts": {
"build": "react-scripts build",
"deploy": "gh-pages -d build"
}
"devDependencies": {
"gh-pages": "^3.1.0"
}, "homepage": "https://choijinkyung.github.io/RT-VIEWER/" ## API documentation Use JSDOC Install : npm install jsdoc template : docdash Update : npm run jsdoc In package.json
"scripts": {
"jsdoc": "jsdoc -c jsdoc.json"
} How to open API docs?
-> './API_document/index.html'
-> open this use web browser ## Available Scripts In the project directory, you can run: ### `npm run start` Runs the app in the development mode.
Open [http://localhost:3000](http://localhost:3000) to view it in the browser. The page will reload if you make edits.
You will also see any lint errors in the console. ### `npm run build` Builds the app for production to the `build` folder.
It correctly bundles React in production mode and optimizes the build for the best performance. The build is minified and the filenames include the hashes.
Your app is ready to be deployed! ### `yarn deploy` Deploy the project on your github page (Your Repository will be public) npm install gh-pages In package.json
"scripts": {
"build": "react-scripts build",
"deploy": "gh-pages -d build"
}
"devDependencies": {
"gh-pages": "^3.1.0"
}, "homepage": "https://choijinkyung.github.io/RT-VIEWER/" ### `npm run jsdoc` Each code can be annotated into jsdoc. Running this script updates. ## Modification Requirements 1. Modify Check Event
-> Draw / reset as soon as check 2. Dose Overlay
-> Find the contour point and trace it. 3. Modify the mouse button to activate the zoom event
-> mouseButton = 3 on the wheel 4. Modifying the import of Contour Data
-> import in class 5. Rotate 90 degrees, flip simultaneously and modify to make it possible 6. Import RT PLAN File 7. Separate each file using DB and import 8. Add Button for Reset x,y coords 9. DVH 10. TreeView ## Contribution Please read [CONTRIBUTING.md](https://gist.github.com/PurpleBooth/b24679402957c63ec426) for details on our code of conduct, and the process for submitting pull requests to us.
[CONTRIBUTING.md](https://gist.github.com/PurpleBooth/b24679402957c63ec426) 를 읽고 이에 맞추어 pull request 를 해주세요. ## Author * Name : [Choi Jin Kyung](https://github.com/choijinkyung) * E-mail : twin7014@naver.com * GitHub : [https://github.com/choijinkyung](https://github.com/choijinkyung) ## LICENSE This project is licensed under the MIT License - see the [LICENSE.md] ``` Copyright (c) 2020 j_iky Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ```