ClearCanvas SDK [英] ClearCanvas SDK

查看:226
本文介绍了ClearCanvas SDK的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在另一个项目中试用ClearCanvas SDK.我不希望对代码进行任何更改.那么,如何获取此代码并将其包含在另一个项目中?我是否需要按照Github的说明进行构建,还是可以下载zip文件,在VS中打开并参考CC解决方案?

I would like to experiment with the ClearCanvas SDK inside of another project. I am not looking to make any changes to the code whatsoever. So how do I get this code and include it in another project? Do I need to Build it via the Github instructions or can I just download the zip, open in VS and reference the CC solution?

以下是我想做的一些细节.我正在寻找使用CC来读取dicom标签并从这些标签中收集数据的方法.最初,这就是我要使用CC进行的所有操作.

Here’s a little detail to what I would like to do. I am looking to use CC to read dicom tags and collect the dat from those tags. Initially, that is all I’d like to do with CC.

谢谢.

推荐答案

好的,我将回答这个问题.首先,您需要转到GitHub并下载并编译源代码以生成二进制文件.唯一的其他选择是将旧版本用于2.0 SP1.那是我记得Clear Canvas自己提供的二进制文件供下载的最后一个.他们不再这样做了,您必须进行搜索才能找到它.

Ok I will answer this question. First you need to go to GitHub and download and compile the source to produce the binaries. The only other choice is to use the old ones for 2.0 SP1. That is the last I remember Clear Canvas themselves providing the binaries for download. They no longer do and you would have to search to find it.

一旦有了二进制文件,便可以创建Windows窗体应用程序.构建完成后,将二进制文件放入debug文件夹中.然后通过浏览DLL添加引用.

Once you have the binaries you can create a windows form application. Put the binaries in the debug folder after building. Add then a reference by browsing to the DLL.

这些是我经常使用的:

ClearCanvas.Common.dll
ClearCanvas.Desktop.dll
ClearCanvas.Dicom.dll
log4net.dll

然后将代码添加到表单类:

Then add the code to the form class:

using ClearCanvas.Dicom;
using ClearCanvas.Dicom.Network;
using ClearCanvas.Common;

一旦设置好,您就应该可以编写如下代码:

Once This is in place you should be able to write code like:

>DicomFile f = new DicomFile(@"C:\33d70014.dcm");
>f.Load();
>f.DataSet[DicomTags.NameOfPhysiciansReadingStudy].SetString(0,"MedicalIDD^LastNameD^FirstNameD^MiddleNameD");
>f.Save(@"C:\33d70014_1.dcm");

此代码仅加载现有的DICOM文件,更改一个标签的值,然后将文件保存为新名称.

This code simply loads an existing DICOM file, changes the value of one tag, and saves the file under a new name.

请参阅我写的关于如何使用Clear Canvas发送DICOM的答案:

Please see the answer I wrote to the question of how to send DICOM with Clear Canvas:

该代码可以满足我所需的一切.

That code works for everything I needed it to.

这篇关于ClearCanvas SDK的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆