1

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?

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.

Thanks in advance.

4

1 に答える 1

3

わかりました、この質問に答えます。まず、GitHub にアクセスして、ソースをダウンロードしてコンパイルし、バイナリを生成する必要があります。他の唯一の選択肢は、2.0 SP1 用の古いものを使用することです。Clear Canvas 自体がダウンロード用のバイナリを提供していたことを覚えているのはこれが最後です。彼らはもはやそうではなく、あなたはそれを見つけるために検索する必要があります.

バイナリを入手したら、Windows フォーム アプリケーションを作成できます。ビルド後、バイナリを debug フォルダーに配置します。次に、DLL を参照して参照を追加します。

これらは私がいつも使用するものです:

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

次に、コードをフォーム クラスに追加します。

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

これが整ったら、次のようなコードを記述できるはずです。

>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 ファイルをロードし、1 つのタグの値を変更して、ファイルを新しい名前で保存するだけです。

Clear Canvas で DICOM を送信する方法の質問に対する私が書いた回答を参照してください。

Visual Studio 2010 で c# を使用してリモート AE に dicom ファイルを送信する

そのコードは、私が必要としていたすべてのもので機能します。

于 2015-08-13T02:34:34.673 に答える