norman
 Senior Member Posts:813
 |
| 2008-05-27 10:12 PM |
|
Hi Deepak, Sorry for the significant delay, but we finally got around to adding the new codecs on the viewer. Just get the latest version from SVN. Let me know if you have any problems with it. N. |
|
|
|
|
dblanchard
 Senior Member Posts:185
 |
| 2008-09-30 10:01 PM |
|
Hi Steve, you said:
> We've also added an extension point for codecs, and a DicomCodecHelper class in the
> ClearCanvas.DicomServices assembly to help loading the extensions.
I didn't see this class anywhere, does it exist or is it not needed anymore?
Thanks
|
|
|
|
|
steve
 Senior Member Posts:1932
 |
| 2008-09-30 11:59 PM |
|
Dan, When the ClearCanvas.DicomServices assembly was merged into the ClearCanvas.Dicom assembly, the DicomCodecHelper class was merged into the DicomCodecRegistry class. The registry now loads the codecs via extension points... Steve |
|
| Real-time support available to Clinical Edition and Team Edition customers |
|
|
dblanchard
 Senior Member Posts:185
 |
| 2009-06-01 06:25 AM |
|
Hello, I am trying to use the Codecs, I download latest and opened the ClearCanvas.Dicom.sln solution. I rebuilt all, and 6 projects are built, and 6 are skipped. is this correct? I looked for all compiled DLLs in that folder hierarchy and the only one I found was ClearCanvas.Dicom.Codec.Rle.dll.
What do I have to do to use the codecs - assuming I find the compiled DLLs, do they just have to be put in the same folder as the ClearCanvas.Dicom.dll ? And then, I have to call some method on DicomCodecRegistry() so it scans for extensions... ?
The one I am mostly after is JpegLosslessNonHierarchicalFirstOrderPredictionProcess14SelectionValue1Uid "1.2.840.10008.1.2.4.70". It appears this is part of the ClearCanvas.Dicom.Codec.Jpeg project, right?
Thanks,
dan |
|
|
|
|
steve
 Senior Member Posts:1932
 |
| 2009-06-01 10:39 AM |
|
Dan, First, about the output directory for the Jpeg codecs, the project is a Managed C++ project, and we customized a bit where the output files were placed. The Jpeg output files are in Trunk\Dicom\Codec\Jpeg\debug and Trunk\Dicom\Codec\Jpeg\release. Yes, you do have the correct assembly for that Jpeg codec. As for finding the codecs, since they're now plugins, they should be loaded for you automatically, you don't have to register them with the registry. That static constructor to DicomCodecRegistry automatically loads the codecs for you. As for directories where a plugin can be loaded, since they're loaded dynamically as part of the framework's plugin mechanism, they can be one of two places: The root application directory, or a "plugins" directory off of the root directory. Note that when you use a plugins directory, you have to configure the directory as a probing path in the app.config file. You can see the workstation's app.config for an example, if you have that installed... Steve |
|
| Real-time support available to Clinical Edition and Team Edition customers |
|
|
dblanchard
 Senior Member Posts:185
 |
| 2009-06-05 01:09 PM |
|
thanks steve, I must be missing something, because I do not see the compiled versions in subversion, and when I build the solution the managed C++ projects are skipped... ? Any ideas? I'm using vs2008 pro... thanks dan |
|
|
|
|
steve
 Senior Member Posts:1932
 |
| 2009-06-05 02:26 PM |
|
Dan, The actual compiled versions of the codecs are here: ReferencedAssemblies\Codecs As for building the codecs, you have to explicitly set the build configuration to "x86" to build the 32-bit version of the codecs. The build configurations on the solution are not the cleanest, I'd suspect this is why the codecs are not building for you. Steve |
|
| Real-time support available to Clinical Edition and Team Edition customers |
|
|
dblanchard
 Senior Member Posts:185
 |
| 2009-08-27 01:18 AM |
|
Hi Steve, I'm still having problems with the compression. I can't get the project to compile - I pretty much only need ClearCanvas.Dicom.Codec.Jpeg.dll to compile. My issue is that this requires a reference to CC Common 1.0 w/ no public key, but I recompiled w/ a public key and with a different version number... so, I really need to be able to compile this DLL to use it. When I try to compile with Debug|x86 I get about 100 errors like this, any ideas? Thanks a lot. Error 1299 error LNK2028: unresolved token (0A00008D) "extern "C" unsigned int __cdecl jpeg12_read_scanlines(struct ClearCanvas::Dicom::Codec::Jpeg::jpeg_decompress_struct *,short * *,unsigned int)" (?jpeg12_read_scanlines@@$$J0YAIPAUjpeg_decompress_struct@Jpeg@Codec@Dicom@ClearCanvas@@PAPAFI@Z) referenced in function "public: virtual void __clrcall ClearCanvas::Dicom::Codec::Jpeg::Jpeg12Codec::Decode(class ClearCanvas::Dicom::DicomCompressedPixelData ^,class ClearCanvas::Dicom::DicomUncompressedPixelData ^,class ClearCanvas::Dicom::Codec::Jpeg::DicomJpegParameters ^,int)" (?Decode@Jpeg12Codec@Jpeg@Codec@Dicom@ClearCanvas@@$$FU$AAMXP$AAVDicomCompressedPixelData@45@P$AAVDicomUncompressedPixelData@45@P$AAVDicomJpegParameters@2345@H@Z) Jpeg12Codec.obj ClearCanvas.Dicom.Codec.Jpeg
|
|
|
|
|
steve
 Senior Member Posts:1932
 |
| 2009-08-27 01:53 AM |
|
Dan, It seems perhaps that the actual C static library that contains the codec code itself didn't compile properly. With the Codec assemblies, the actual "Platform" for the project is a bit unconventional. Ie, there's an x86 and x64 platform that the ClearCanvas.Dicom solution requires to be set in order for the compilation to work. Do you have this "Platform" set in your solution when compiling? I suspect that the libijg8/libijg12/libijg16 libraries are not building properly for you when you're compiling, perhaps because of the Platform setting not being set right. Steve |
|
| Real-time support available to Clinical Edition and Team Edition customers |
|
|
nibuen
 Veteran Member Posts:61
 |
| 2011-02-10 05:23 PM |
|
Hi Steve, I have tried setting the "Platform" to x86 and when I check the configuration manager OpenJPEG, libjig8, etc. all show "Win32" for platform. Yet I get the same errors that Dan has posted above. Thanks, Leif |
|
|
|
|
steve
 Senior Member Posts:1932
 |
| 2011-03-09 06:01 PM |
|
Lief, When we build the codecs, we do it from msbuild. Have you tried building it like this: msbuild /p:Configuration=Release /p:Platform=x86 ClearCanvas.Dicom.sln That might solve the problem by forcing the platform to be x86. The Trunk builds fine for me like this from a Visual Studio 2008 Command Prompt. Steve |
|
| Real-time support available to Clinical Edition and Team Edition customers |
|
|
nibuen
 Veteran Member Posts:61
 |
| 2011-03-12 11:36 PM |
|
Thanks Steve! That worked great. |
|
|
|
|
nibuen
 Veteran Member Posts:61
 |
| 2011-03-14 07:26 PM |
|
Hey Steve,
While I could get this working great for x86, when I try to do x64 it tells me there is no such solution? Here is output:
"c:\app\RisViewer2.0\Dicom\ClearCanvas.Dicom.sln" (default target) (1) ->
(libijg16 target) ->
vcbuild.exe : error VCBLD0004: Project 'c:\app\RisViewer2.0\Dicom\Codec\Jpeg\
libijg16\libijg16.vcproj' does not contain a configuration called 'Release|x64'.
Leif
|
|
|
|
|
steve
 Senior Member Posts:1932
 |
| 2011-03-19 11:13 PM |
|
Leif, Are you building with the Win64 cross compiler? Ie, you have to use the Win64 command prompt when building for 64-bit. Steve |
|
| Real-time support available to Clinical Edition and Team Edition customers |
|
|
nibuen
 Veteran Member Posts:61
 |
| 2011-03-20 05:21 PM |
|
Nope! Thanks alot! |
|
|
|
|