Mercurial > hg > orthanc
comparison UnitTestsSources/ImageProcessingTests.cpp @ 1364:111e23bb4904 query-retrieve
integration mainline->query-retrieve
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 21 May 2015 16:58:30 +0200 |
parents | 6e7e5ed91c2d |
children | 96582230ddcb |
comparison
equal
deleted
inserted
replaced
953:f894be6e7cc1 | 1364:111e23bb4904 |
---|---|
1 /** | 1 /** |
2 * Orthanc - A Lightweight, RESTful DICOM Store | 2 * Orthanc - A Lightweight, RESTful DICOM Store |
3 * Copyright (C) 2012-2014 Medical Physics Department, CHU of Liege, | 3 * Copyright (C) 2012-2015 Sebastien Jodogne, Medical Physics |
4 * Belgium | 4 * Department, University Hospital of Liege, Belgium |
5 * | 5 * |
6 * This program is free software: you can redistribute it and/or | 6 * This program is free software: you can redistribute it and/or |
7 * modify it under the terms of the GNU General Public License as | 7 * modify it under the terms of the GNU General Public License as |
8 * published by the Free Software Foundation, either version 3 of the | 8 * published by the Free Software Foundation, either version 3 of the |
9 * License, or (at your option) any later version. | 9 * License, or (at your option) any later version. |
49 m.SetValue(DICOM_TAG_BITS_ALLOCATED, "16"); | 49 m.SetValue(DICOM_TAG_BITS_ALLOCATED, "16"); |
50 m.SetValue(DICOM_TAG_SAMPLES_PER_PIXEL, "1"); | 50 m.SetValue(DICOM_TAG_SAMPLES_PER_PIXEL, "1"); |
51 m.SetValue(DICOM_TAG_BITS_STORED, "12"); | 51 m.SetValue(DICOM_TAG_BITS_STORED, "12"); |
52 m.SetValue(DICOM_TAG_HIGH_BIT, "11"); | 52 m.SetValue(DICOM_TAG_HIGH_BIT, "11"); |
53 m.SetValue(DICOM_TAG_PIXEL_REPRESENTATION, "0"); | 53 m.SetValue(DICOM_TAG_PIXEL_REPRESENTATION, "0"); |
54 m.SetValue(DICOM_TAG_PHOTOMETRIC_INTERPRETATION, "MONOCHROME2"); | |
54 | 55 |
55 DicomImageInformation info(m); | 56 DicomImageInformation info(m); |
56 PixelFormat format; | 57 PixelFormat format; |
57 ASSERT_TRUE(info.ExtractPixelFormat(format)); | 58 ASSERT_TRUE(info.ExtractPixelFormat(format)); |
58 ASSERT_EQ(PixelFormat_Grayscale16, format); | 59 ASSERT_EQ(PixelFormat_Grayscale16, format); |
68 m.SetValue(DICOM_TAG_BITS_ALLOCATED, "16"); | 69 m.SetValue(DICOM_TAG_BITS_ALLOCATED, "16"); |
69 m.SetValue(DICOM_TAG_SAMPLES_PER_PIXEL, "1"); | 70 m.SetValue(DICOM_TAG_SAMPLES_PER_PIXEL, "1"); |
70 m.SetValue(DICOM_TAG_BITS_STORED, "16"); | 71 m.SetValue(DICOM_TAG_BITS_STORED, "16"); |
71 m.SetValue(DICOM_TAG_HIGH_BIT, "15"); | 72 m.SetValue(DICOM_TAG_HIGH_BIT, "15"); |
72 m.SetValue(DICOM_TAG_PIXEL_REPRESENTATION, "1"); | 73 m.SetValue(DICOM_TAG_PIXEL_REPRESENTATION, "1"); |
74 m.SetValue(DICOM_TAG_PHOTOMETRIC_INTERPRETATION, "MONOCHROME2"); | |
73 | 75 |
74 DicomImageInformation info(m); | 76 DicomImageInformation info(m); |
75 PixelFormat format; | 77 PixelFormat format; |
76 ASSERT_TRUE(info.ExtractPixelFormat(format)); | 78 ASSERT_TRUE(info.ExtractPixelFormat(format)); |
77 ASSERT_EQ(PixelFormat_SignedGrayscale16, format); | 79 ASSERT_EQ(PixelFormat_SignedGrayscale16, format); |