Mercurial > hg > orthanc
comparison UnitTestsSources/Png.cpp @ 711:8f62e8d5a384
test main dicom tags
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 13 Feb 2014 15:51:10 +0100 |
parents | c87a1d529e13 |
children | 37adac56017a |
comparison
equal
deleted
inserted
replaced
710:c87a1d529e13 | 711:8f62e8d5a384 |
---|---|
118 | 118 |
119 v = 0; | 119 v = 0; |
120 for (int y = 0; y < height; y++) | 120 for (int y = 0; y < height; y++) |
121 { | 121 { |
122 uint16_t *p = reinterpret_cast<uint16_t*>((uint8_t*) r.GetBuffer() + y * r.GetPitch()); | 122 uint16_t *p = reinterpret_cast<uint16_t*>((uint8_t*) r.GetBuffer() + y * r.GetPitch()); |
123 ASSERT_EQ(p, r.GetBuffer(y)); | |
123 for (int x = 0; x < width; x++, p++, v++) | 124 for (int x = 0; x < width; x++, p++, v++) |
124 { | 125 { |
125 ASSERT_EQ(*p, v); | 126 ASSERT_EQ(*p, v); |
126 } | 127 } |
127 } | 128 } |
140 | 141 |
141 v = 0; | 142 v = 0; |
142 for (int y = 0; y < height; y++) | 143 for (int y = 0; y < height; y++) |
143 { | 144 { |
144 uint16_t *p = reinterpret_cast<uint16_t*>((uint8_t*) r2.GetBuffer() + y * r2.GetPitch()); | 145 uint16_t *p = reinterpret_cast<uint16_t*>((uint8_t*) r2.GetBuffer() + y * r2.GetPitch()); |
146 ASSERT_EQ(p, r2.GetBuffer(y)); | |
145 for (int x = 0; x < width; x++, p++, v++) | 147 for (int x = 0; x < width; x++, p++, v++) |
146 { | 148 { |
147 ASSERT_EQ(*p, v); | 149 ASSERT_EQ(*p, v); |
148 } | 150 } |
149 } | 151 } |