Mercurial > hg > orthanc
comparison OrthancCppClient/SharedLibrary/AUTOGENERATED/OrthancCppClient.h @ 986:de18e90d5507
fix GetVoxelSizeZ
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 01 Jul 2014 16:51:18 +0200 |
parents | f2841a9e04cf |
children | 7cbcd580cd21 |
comparison
equal
deleted
inserted
replaced
981:ef02bd1c2f0e | 986:de18e90d5507 |
---|---|
201 **/ | 201 **/ |
202 class Library | 202 class Library |
203 { | 203 { |
204 private: | 204 private: |
205 LAAW_ORTHANC_CLIENT_HANDLE_TYPE handle_; | 205 LAAW_ORTHANC_CLIENT_HANDLE_TYPE handle_; |
206 LAAW_ORTHANC_CLIENT_FUNCTION_TYPE functionsIndex_[62 + 1]; | 206 LAAW_ORTHANC_CLIENT_FUNCTION_TYPE functionsIndex_[63 + 1]; |
207 | 207 |
208 | 208 |
209 | 209 |
210 void Load(const char* sharedLibraryPath) | 210 void Load(const char* sharedLibraryPath) |
211 { | 211 { |
237 inline void LoadFunctions(); | 237 inline void LoadFunctions(); |
238 | 238 |
239 void FreeString(char* str) | 239 void FreeString(char* str) |
240 { | 240 { |
241 typedef void (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (char*); | 241 typedef void (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (char*); |
242 Function function = (Function) GetFunction(62); | 242 Function function = (Function) GetFunction(63); |
243 function(str); | 243 function(str); |
244 } | 244 } |
245 | 245 |
246 Library() | 246 Library() |
247 { | 247 { |
389 if (strcmp(getVersion(), "0.7")) | 389 if (strcmp(getVersion(), "0.7")) |
390 { | 390 { |
391 throw ::OrthancClient::OrthancClientException("Mismatch between the C++ header and the library version"); | 391 throw ::OrthancClient::OrthancClientException("Mismatch between the C++ header and the library version"); |
392 } | 392 } |
393 | 393 |
394 functionsIndex_[62] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_FreeString", "4"); | 394 functionsIndex_[63] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_FreeString", "4"); |
395 functionsIndex_[3] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_557aee7b61817292a0f31269d3c35db7", "8"); | 395 functionsIndex_[3] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_557aee7b61817292a0f31269d3c35db7", "8"); |
396 functionsIndex_[4] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_0b8dff0ce67f10954a49b059e348837e", "8"); | 396 functionsIndex_[4] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_0b8dff0ce67f10954a49b059e348837e", "8"); |
397 functionsIndex_[5] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_e05097c153f676e5a5ee54dcfc78256f", "4"); | 397 functionsIndex_[5] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_e05097c153f676e5a5ee54dcfc78256f", "4"); |
398 functionsIndex_[6] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_e840242bf58d17d3c1d722da09ce88e0", "8"); | 398 functionsIndex_[6] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_e840242bf58d17d3c1d722da09ce88e0", "8"); |
399 functionsIndex_[7] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_c9af31433001b5dfc012a552dc6d0050", "8"); | 399 functionsIndex_[7] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_c9af31433001b5dfc012a552dc6d0050", "8"); |
421 functionsIndex_[28] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_eee03f337ec81d9f1783cd41e5238757", "8"); | 421 functionsIndex_[28] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_eee03f337ec81d9f1783cd41e5238757", "8"); |
422 functionsIndex_[29] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_006f08237bd7611636fc721baebfb4c5", "8"); | 422 functionsIndex_[29] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_006f08237bd7611636fc721baebfb4c5", "8"); |
423 functionsIndex_[30] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_b794f5cd3dad7d7b575dd1fd902afdd0", "8"); | 423 functionsIndex_[30] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_b794f5cd3dad7d7b575dd1fd902afdd0", "8"); |
424 functionsIndex_[31] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_8ee2e50dd9df8f66a3c1766090dd03ab", "8"); | 424 functionsIndex_[31] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_8ee2e50dd9df8f66a3c1766090dd03ab", "8"); |
425 functionsIndex_[32] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_046aed35bbe4751691f4c34cc249a61d", "8"); | 425 functionsIndex_[32] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_046aed35bbe4751691f4c34cc249a61d", "8"); |
426 functionsIndex_[33] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_4dcc7a0fd025efba251ac6e9b701c2c5", "28"); | 426 functionsIndex_[33] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_2be452e7af5bf7dfd8c5021842674497", "8"); |
427 functionsIndex_[34] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_b2601a161c24ad0a1d3586246f87452c", "32"); | 427 functionsIndex_[34] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_4dcc7a0fd025efba251ac6e9b701c2c5", "28"); |
428 functionsIndex_[35] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_b2601a161c24ad0a1d3586246f87452c", "32"); | |
428 functionsIndex_[19] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_193599b9e345384fcdfcd47c29c55342", "12"); | 429 functionsIndex_[19] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_193599b9e345384fcdfcd47c29c55342", "12"); |
429 functionsIndex_[20] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_7c97f17063a357d38c5fab1136ad12a0", "4"); | 430 functionsIndex_[20] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_7c97f17063a357d38c5fab1136ad12a0", "4"); |
430 functionsIndex_[37] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_e65b20b7e0170b67544cd6664a4639b7", "4"); | 431 functionsIndex_[38] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_e65b20b7e0170b67544cd6664a4639b7", "4"); |
431 functionsIndex_[38] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_470e981b0e41f17231ba0ae6f3033321", "8"); | 432 functionsIndex_[39] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_470e981b0e41f17231ba0ae6f3033321", "8"); |
432 functionsIndex_[39] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_04cefd138b6ea15ad909858f2a0a8f05", "12"); | 433 functionsIndex_[40] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_04cefd138b6ea15ad909858f2a0a8f05", "12"); |
433 functionsIndex_[40] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_aee5b1f6f0c082f2c3b0986f9f6a18c7", "8"); | 434 functionsIndex_[41] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_aee5b1f6f0c082f2c3b0986f9f6a18c7", "8"); |
434 functionsIndex_[41] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_93965682bace75491413e1f0b8d5a654", "16"); | 435 functionsIndex_[42] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_93965682bace75491413e1f0b8d5a654", "16"); |
435 functionsIndex_[35] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_b01c6003238eb46c8db5dc823d7ca678", "12"); | 436 functionsIndex_[36] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_b01c6003238eb46c8db5dc823d7ca678", "12"); |
436 functionsIndex_[36] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_0147007fb99bad8cd95a139ec8795376", "4"); | 437 functionsIndex_[37] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_0147007fb99bad8cd95a139ec8795376", "4"); |
437 functionsIndex_[44] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_236ee8b403bc99535a8a4695c0cd45cb", "8"); | 438 functionsIndex_[45] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_236ee8b403bc99535a8a4695c0cd45cb", "8"); |
438 functionsIndex_[45] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_2a437b7aba6bb01e81113835be8f0146", "8"); | 439 functionsIndex_[46] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_2a437b7aba6bb01e81113835be8f0146", "8"); |
439 functionsIndex_[46] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_2bcbcb850934ae0bb4c6f0cc940e6cda", "8"); | 440 functionsIndex_[47] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_2bcbcb850934ae0bb4c6f0cc940e6cda", "8"); |
440 functionsIndex_[47] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_8d415c3a78a48e7e61d9fd24e7c79484", "12"); | 441 functionsIndex_[48] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_8d415c3a78a48e7e61d9fd24e7c79484", "12"); |
441 functionsIndex_[48] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_70d2f8398bbc63b5f792b69b4ad5fecb", "12"); | 442 functionsIndex_[49] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_70d2f8398bbc63b5f792b69b4ad5fecb", "12"); |
442 functionsIndex_[49] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_1729a067d902771517388eedd7346b23", "12"); | 443 functionsIndex_[50] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_1729a067d902771517388eedd7346b23", "12"); |
443 functionsIndex_[50] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_72e2aeee66cd3abd8ab7e987321c3745", "8"); | 444 functionsIndex_[51] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_72e2aeee66cd3abd8ab7e987321c3745", "8"); |
444 functionsIndex_[51] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_1ea3df5a1ac1a1a687fe7325adddb6f0", "8"); | 445 functionsIndex_[52] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_1ea3df5a1ac1a1a687fe7325adddb6f0", "8"); |
445 functionsIndex_[52] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_99b4f370e4f532d8b763e2cb49db92f8", "8"); | 446 functionsIndex_[53] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_99b4f370e4f532d8b763e2cb49db92f8", "8"); |
446 functionsIndex_[53] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_c41c742b68617f1c0590577a0a5ebc0c", "8"); | 447 functionsIndex_[54] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_c41c742b68617f1c0590577a0a5ebc0c", "8"); |
447 functionsIndex_[54] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_142dd2feba0fc1d262bbd0baeb441a8b", "8"); | 448 functionsIndex_[55] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_142dd2feba0fc1d262bbd0baeb441a8b", "8"); |
448 functionsIndex_[55] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_5f5c9f81a4dff8daa6c359f1d0488fef", "12"); | 449 functionsIndex_[56] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_5f5c9f81a4dff8daa6c359f1d0488fef", "12"); |
449 functionsIndex_[56] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_9ca979fffd08fa256306d4e68d8b0e91", "8"); | 450 functionsIndex_[57] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_9ca979fffd08fa256306d4e68d8b0e91", "8"); |
450 functionsIndex_[57] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_6f2d77a26edc91c28d89408dbc3c271e", "8"); | 451 functionsIndex_[58] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_6f2d77a26edc91c28d89408dbc3c271e", "8"); |
451 functionsIndex_[58] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_c0f494b80d4ff8b232df7a75baa0700a", "4"); | 452 functionsIndex_[59] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_c0f494b80d4ff8b232df7a75baa0700a", "4"); |
452 functionsIndex_[59] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_d604f44bd5195e082e745e9cbc164f4c", "4"); | 453 functionsIndex_[60] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_d604f44bd5195e082e745e9cbc164f4c", "4"); |
453 functionsIndex_[60] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_1710299d1c5f3b1f2b7cf3962deebbfd", "8"); | 454 functionsIndex_[61] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_1710299d1c5f3b1f2b7cf3962deebbfd", "8"); |
454 functionsIndex_[61] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_bb55aaf772ddceaadee36f4e54136bcb", "8"); | 455 functionsIndex_[62] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_bb55aaf772ddceaadee36f4e54136bcb", "8"); |
455 functionsIndex_[42] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_6c5ad02f91b583e29cebd0bd319ce21d", "12"); | 456 functionsIndex_[43] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_6c5ad02f91b583e29cebd0bd319ce21d", "12"); |
456 functionsIndex_[43] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_4068241c44a9c1367fe0e57be523f207", "4"); | 457 functionsIndex_[44] = LAAW_ORTHANC_CLIENT_GET_FUNCTION(handle_, "LAAW_EXTERNC_4068241c44a9c1367fe0e57be523f207", "4"); |
457 | 458 |
458 /* Check whether the functions were properly loaded */ | 459 /* Check whether the functions were properly loaded */ |
459 for (unsigned int i = 0; i <= 62; i++) | 460 for (unsigned int i = 0; i <= 63; i++) |
460 { | 461 { |
461 if (functionsIndex_[i] == (LAAW_ORTHANC_CLIENT_FUNCTION_TYPE) NULL) | 462 if (functionsIndex_[i] == (LAAW_ORTHANC_CLIENT_FUNCTION_TYPE) NULL) |
462 { | 463 { |
463 throw ::OrthancClient::OrthancClientException("Unable to load the functions of the shared library"); | 464 throw ::OrthancClient::OrthancClientException("Unable to load the functions of the shared library"); |
464 } | 465 } |
702 inline LAAW_UINT32 GetWidth(); | 703 inline LAAW_UINT32 GetWidth(); |
703 inline LAAW_UINT32 GetHeight(); | 704 inline LAAW_UINT32 GetHeight(); |
704 inline float GetVoxelSizeX(); | 705 inline float GetVoxelSizeX(); |
705 inline float GetVoxelSizeY(); | 706 inline float GetVoxelSizeY(); |
706 inline float GetVoxelSizeZ(); | 707 inline float GetVoxelSizeZ(); |
708 inline float GetSliceThickness(); | |
707 inline void Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride); | 709 inline void Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride); |
708 inline void Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride, float progress[]); | 710 inline void Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride, float progress[]); |
709 }; | 711 }; |
710 } | 712 } |
711 | 713 |
1321 char* error = function(pimpl_, &result_); | 1323 char* error = function(pimpl_, &result_); |
1322 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1324 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1323 return result_; | 1325 return result_; |
1324 } | 1326 } |
1325 /** | 1327 /** |
1328 * @brief Get the slice thickness. | |
1329 * | |
1330 * Get the slice thickness. This call is only valid if this series corresponds to a 3D image. | |
1331 * | |
1332 * @return The slice thickness. | |
1333 **/ | |
1334 inline float Series::GetSliceThickness() | |
1335 { | |
1336 float result_; | |
1337 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, float*); | |
1338 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(33); | |
1339 char* error = function(pimpl_, &result_); | |
1340 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | |
1341 return result_; | |
1342 } | |
1343 /** | |
1326 * @brief Load the 3D image into a memory buffer. | 1344 * @brief Load the 3D image into a memory buffer. |
1327 * | 1345 * |
1328 * Load the 3D image into a memory buffer. This call is only valid if this series corresponds to a 3D image. The "target" buffer must be wide enough to store all the voxels of the image. | 1346 * Load the 3D image into a memory buffer. This call is only valid if this series corresponds to a 3D image. The "target" buffer must be wide enough to store all the voxels of the image. |
1329 * | 1347 * |
1330 * @param target The target memory buffer. | 1348 * @param target The target memory buffer. |
1333 * @param stackStride The number of bytes between two 2D slices in the target memory buffer. | 1351 * @param stackStride The number of bytes between two 2D slices in the target memory buffer. |
1334 **/ | 1352 **/ |
1335 inline void Series::Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride) | 1353 inline void Series::Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride) |
1336 { | 1354 { |
1337 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, void*, LAAW_INT32, LAAW_INT64, LAAW_INT64); | 1355 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, void*, LAAW_INT32, LAAW_INT64, LAAW_INT64); |
1338 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(33); | 1356 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(34); |
1339 char* error = function(pimpl_, target, format, lineStride, stackStride); | 1357 char* error = function(pimpl_, target, format, lineStride, stackStride); |
1340 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1358 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1341 } | 1359 } |
1342 /** | 1360 /** |
1343 * @brief Load the 3D image into a memory buffer. | 1361 * @brief Load the 3D image into a memory buffer. |
1351 * @param progress A pointer to a floating-point number that is continuously updated by the download threads to reflect the percentage of completion (between 0 and 1). This value can be read from a separate thread. | 1369 * @param progress A pointer to a floating-point number that is continuously updated by the download threads to reflect the percentage of completion (between 0 and 1). This value can be read from a separate thread. |
1352 **/ | 1370 **/ |
1353 inline void Series::Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride, float progress[]) | 1371 inline void Series::Load3DImage(void* target, ::Orthanc::PixelFormat format, LAAW_INT64 lineStride, LAAW_INT64 stackStride, float progress[]) |
1354 { | 1372 { |
1355 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, void*, LAAW_INT32, LAAW_INT64, LAAW_INT64, float*); | 1373 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, void*, LAAW_INT32, LAAW_INT64, LAAW_INT64, float*); |
1356 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(34); | 1374 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(35); |
1357 char* error = function(pimpl_, target, format, lineStride, stackStride, progress); | 1375 char* error = function(pimpl_, target, format, lineStride, stackStride, progress); |
1358 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1376 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1359 } | 1377 } |
1360 } | 1378 } |
1361 | 1379 |
1371 **/ | 1389 **/ |
1372 inline Study::Study(::OrthancClient::OrthancConnection& connection, const ::std::string& id) | 1390 inline Study::Study(::OrthancClient::OrthancConnection& connection, const ::std::string& id) |
1373 { | 1391 { |
1374 isReference_ = false; | 1392 isReference_ = false; |
1375 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void**, void*, const char*); | 1393 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void**, void*, const char*); |
1376 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(35); | 1394 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(36); |
1377 char* error = function(&pimpl_, connection.pimpl_, id.c_str()); | 1395 char* error = function(&pimpl_, connection.pimpl_, id.c_str()); |
1378 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1396 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1379 } | 1397 } |
1380 /** | 1398 /** |
1381 * @brief Destructs the object. | 1399 * @brief Destructs the object. |
1384 * | 1402 * |
1385 **/ | 1403 **/ |
1386 inline Study::~Study() | 1404 inline Study::~Study() |
1387 { | 1405 { |
1388 if (isReference_) return; | 1406 if (isReference_) return; |
1389 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | |
1390 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(36); | |
1391 char* error = function(pimpl_); | |
1392 error = error; // Remove warning about unused variable | |
1393 } | |
1394 /** | |
1395 * @brief Reload the series of this study. | |
1396 * | |
1397 * This method will reload the list of the series of this study. Pay attention to the fact that the series that have been previously returned by GetSeries() will be invalidated. | |
1398 * | |
1399 **/ | |
1400 inline void Study::Reload() | |
1401 { | |
1402 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | 1407 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); |
1403 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(37); | 1408 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(37); |
1404 char* error = function(pimpl_); | 1409 char* error = function(pimpl_); |
1410 error = error; // Remove warning about unused variable | |
1411 } | |
1412 /** | |
1413 * @brief Reload the series of this study. | |
1414 * | |
1415 * This method will reload the list of the series of this study. Pay attention to the fact that the series that have been previously returned by GetSeries() will be invalidated. | |
1416 * | |
1417 **/ | |
1418 inline void Study::Reload() | |
1419 { | |
1420 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | |
1421 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(38); | |
1422 char* error = function(pimpl_); | |
1405 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1423 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1406 } | 1424 } |
1407 /** | 1425 /** |
1408 * @brief Return the number of series for this study. | 1426 * @brief Return the number of series for this study. |
1409 * | 1427 * |
1413 **/ | 1431 **/ |
1414 inline LAAW_UINT32 Study::GetSeriesCount() | 1432 inline LAAW_UINT32 Study::GetSeriesCount() |
1415 { | 1433 { |
1416 LAAW_UINT32 result_; | 1434 LAAW_UINT32 result_; |
1417 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); | 1435 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); |
1418 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(38); | 1436 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(39); |
1419 char* error = function(pimpl_, &result_); | 1437 char* error = function(pimpl_, &result_); |
1420 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1438 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1421 return result_; | 1439 return result_; |
1422 } | 1440 } |
1423 /** | 1441 /** |
1430 **/ | 1448 **/ |
1431 inline ::OrthancClient::Series Study::GetSeries(LAAW_UINT32 index) | 1449 inline ::OrthancClient::Series Study::GetSeries(LAAW_UINT32 index) |
1432 { | 1450 { |
1433 void* result_; | 1451 void* result_; |
1434 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, void**, LAAW_UINT32); | 1452 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, void**, LAAW_UINT32); |
1435 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(39); | 1453 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(40); |
1436 char* error = function(pimpl_, &result_, index); | 1454 char* error = function(pimpl_, &result_, index); |
1437 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1455 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1438 return ::OrthancClient::Series(result_); | 1456 return ::OrthancClient::Series(result_); |
1439 } | 1457 } |
1440 /** | 1458 /** |
1446 **/ | 1464 **/ |
1447 inline ::std::string Study::GetId() const | 1465 inline ::std::string Study::GetId() const |
1448 { | 1466 { |
1449 const char* result_; | 1467 const char* result_; |
1450 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**); | 1468 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**); |
1451 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(40); | 1469 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(41); |
1452 char* error = function(pimpl_, &result_); | 1470 char* error = function(pimpl_, &result_); |
1453 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1471 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1454 return std::string(result_); | 1472 return std::string(result_); |
1455 } | 1473 } |
1456 /** | 1474 /** |
1464 **/ | 1482 **/ |
1465 inline ::std::string Study::GetMainDicomTag(const ::std::string& tag, const ::std::string& defaultValue) const | 1483 inline ::std::string Study::GetMainDicomTag(const ::std::string& tag, const ::std::string& defaultValue) const |
1466 { | 1484 { |
1467 const char* result_; | 1485 const char* result_; |
1468 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**, const char*, const char*); | 1486 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**, const char*, const char*); |
1469 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(41); | 1487 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(42); |
1470 char* error = function(pimpl_, &result_, tag.c_str(), defaultValue.c_str()); | 1488 char* error = function(pimpl_, &result_, tag.c_str(), defaultValue.c_str()); |
1471 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1489 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1472 return std::string(result_); | 1490 return std::string(result_); |
1473 } | 1491 } |
1474 } | 1492 } |
1485 **/ | 1503 **/ |
1486 inline Instance::Instance(::OrthancClient::OrthancConnection& connection, const ::std::string& id) | 1504 inline Instance::Instance(::OrthancClient::OrthancConnection& connection, const ::std::string& id) |
1487 { | 1505 { |
1488 isReference_ = false; | 1506 isReference_ = false; |
1489 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void**, void*, const char*); | 1507 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void**, void*, const char*); |
1490 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(42); | 1508 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(43); |
1491 char* error = function(&pimpl_, connection.pimpl_, id.c_str()); | 1509 char* error = function(&pimpl_, connection.pimpl_, id.c_str()); |
1492 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1510 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1493 } | 1511 } |
1494 /** | 1512 /** |
1495 * @brief Destructs the object. | 1513 * @brief Destructs the object. |
1499 **/ | 1517 **/ |
1500 inline Instance::~Instance() | 1518 inline Instance::~Instance() |
1501 { | 1519 { |
1502 if (isReference_) return; | 1520 if (isReference_) return; |
1503 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | 1521 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); |
1504 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(43); | 1522 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(44); |
1505 char* error = function(pimpl_); | 1523 char* error = function(pimpl_); |
1506 error = error; // Remove warning about unused variable | 1524 error = error; // Remove warning about unused variable |
1507 } | 1525 } |
1508 /** | 1526 /** |
1509 * @brief Get the %Orthanc identifier of this identifier. | 1527 * @brief Get the %Orthanc identifier of this identifier. |
1514 **/ | 1532 **/ |
1515 inline ::std::string Instance::GetId() const | 1533 inline ::std::string Instance::GetId() const |
1516 { | 1534 { |
1517 const char* result_; | 1535 const char* result_; |
1518 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**); | 1536 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**); |
1519 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(44); | 1537 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(45); |
1520 char* error = function(pimpl_, &result_); | 1538 char* error = function(pimpl_, &result_); |
1521 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1539 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1522 return std::string(result_); | 1540 return std::string(result_); |
1523 } | 1541 } |
1524 /** | 1542 /** |
1529 * @param mode The extraction mode. | 1547 * @param mode The extraction mode. |
1530 **/ | 1548 **/ |
1531 inline void Instance::SetImageExtractionMode(::Orthanc::ImageExtractionMode mode) | 1549 inline void Instance::SetImageExtractionMode(::Orthanc::ImageExtractionMode mode) |
1532 { | 1550 { |
1533 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_INT32); | 1551 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_INT32); |
1534 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(45); | 1552 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(46); |
1535 char* error = function(pimpl_, mode); | 1553 char* error = function(pimpl_, mode); |
1536 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1554 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1537 } | 1555 } |
1538 /** | 1556 /** |
1539 * @brief Get the extraction mode for the 2D image corresponding to this instance. | 1557 * @brief Get the extraction mode for the 2D image corresponding to this instance. |
1544 **/ | 1562 **/ |
1545 inline ::Orthanc::ImageExtractionMode Instance::GetImageExtractionMode() const | 1563 inline ::Orthanc::ImageExtractionMode Instance::GetImageExtractionMode() const |
1546 { | 1564 { |
1547 LAAW_INT32 result_; | 1565 LAAW_INT32 result_; |
1548 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, LAAW_INT32*); | 1566 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, LAAW_INT32*); |
1549 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(46); | 1567 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(47); |
1550 char* error = function(pimpl_, &result_); | 1568 char* error = function(pimpl_, &result_); |
1551 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1569 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1552 return static_cast< ::Orthanc::ImageExtractionMode >(result_); | 1570 return static_cast< ::Orthanc::ImageExtractionMode >(result_); |
1553 } | 1571 } |
1554 /** | 1572 /** |
1561 **/ | 1579 **/ |
1562 inline ::std::string Instance::GetTagAsString(const ::std::string& tag) const | 1580 inline ::std::string Instance::GetTagAsString(const ::std::string& tag) const |
1563 { | 1581 { |
1564 const char* result_; | 1582 const char* result_; |
1565 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**, const char*); | 1583 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**, const char*); |
1566 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(47); | 1584 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(48); |
1567 char* error = function(pimpl_, &result_, tag.c_str()); | 1585 char* error = function(pimpl_, &result_, tag.c_str()); |
1568 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1586 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1569 return std::string(result_); | 1587 return std::string(result_); |
1570 } | 1588 } |
1571 /** | 1589 /** |
1578 **/ | 1596 **/ |
1579 inline float Instance::GetTagAsFloat(const ::std::string& tag) const | 1597 inline float Instance::GetTagAsFloat(const ::std::string& tag) const |
1580 { | 1598 { |
1581 float result_; | 1599 float result_; |
1582 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, float*, const char*); | 1600 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, float*, const char*); |
1583 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(48); | 1601 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(49); |
1584 char* error = function(pimpl_, &result_, tag.c_str()); | 1602 char* error = function(pimpl_, &result_, tag.c_str()); |
1585 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1603 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1586 return result_; | 1604 return result_; |
1587 } | 1605 } |
1588 /** | 1606 /** |
1595 **/ | 1613 **/ |
1596 inline LAAW_INT32 Instance::GetTagAsInt(const ::std::string& tag) const | 1614 inline LAAW_INT32 Instance::GetTagAsInt(const ::std::string& tag) const |
1597 { | 1615 { |
1598 LAAW_INT32 result_; | 1616 LAAW_INT32 result_; |
1599 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, LAAW_INT32*, const char*); | 1617 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, LAAW_INT32*, const char*); |
1600 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(49); | 1618 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(50); |
1601 char* error = function(pimpl_, &result_, tag.c_str()); | 1619 char* error = function(pimpl_, &result_, tag.c_str()); |
1602 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1620 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1603 return result_; | 1621 return result_; |
1604 } | 1622 } |
1605 /** | 1623 /** |
1608 * Get the width of the 2D image that is encoded by this DICOM instance. | 1626 * Get the width of the 2D image that is encoded by this DICOM instance. |
1609 * | 1627 * |
1610 * @return The width. | 1628 * @return The width. |
1611 **/ | 1629 **/ |
1612 inline LAAW_UINT32 Instance::GetWidth() | 1630 inline LAAW_UINT32 Instance::GetWidth() |
1613 { | |
1614 LAAW_UINT32 result_; | |
1615 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); | |
1616 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(50); | |
1617 char* error = function(pimpl_, &result_); | |
1618 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | |
1619 return result_; | |
1620 } | |
1621 /** | |
1622 * @brief Get the height of the 2D image. | |
1623 * | |
1624 * Get the height of the 2D image that is encoded by this DICOM instance. | |
1625 * | |
1626 * @return The height. | |
1627 **/ | |
1628 inline LAAW_UINT32 Instance::GetHeight() | |
1629 { | 1631 { |
1630 LAAW_UINT32 result_; | 1632 LAAW_UINT32 result_; |
1631 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); | 1633 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); |
1632 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(51); | 1634 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(51); |
1633 char* error = function(pimpl_, &result_); | 1635 char* error = function(pimpl_, &result_); |
1634 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1636 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1635 return result_; | 1637 return result_; |
1636 } | 1638 } |
1637 /** | 1639 /** |
1638 * @brief Get the number of bytes between two lines of the image (pitch). | 1640 * @brief Get the height of the 2D image. |
1639 * | 1641 * |
1640 * Get the number of bytes between two lines of the image in the memory buffer returned by GetBuffer(). This value depends on the extraction mode for the image. | 1642 * Get the height of the 2D image that is encoded by this DICOM instance. |
1641 * | 1643 * |
1642 * @return The pitch. | 1644 * @return The height. |
1643 **/ | 1645 **/ |
1644 inline LAAW_UINT32 Instance::GetPitch() | 1646 inline LAAW_UINT32 Instance::GetHeight() |
1645 { | 1647 { |
1646 LAAW_UINT32 result_; | 1648 LAAW_UINT32 result_; |
1647 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); | 1649 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); |
1648 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(52); | 1650 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(52); |
1649 char* error = function(pimpl_, &result_); | 1651 char* error = function(pimpl_, &result_); |
1650 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1652 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1651 return result_; | 1653 return result_; |
1652 } | 1654 } |
1653 /** | 1655 /** |
1656 * @brief Get the number of bytes between two lines of the image (pitch). | |
1657 * | |
1658 * Get the number of bytes between two lines of the image in the memory buffer returned by GetBuffer(). This value depends on the extraction mode for the image. | |
1659 * | |
1660 * @return The pitch. | |
1661 **/ | |
1662 inline LAAW_UINT32 Instance::GetPitch() | |
1663 { | |
1664 LAAW_UINT32 result_; | |
1665 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT32*); | |
1666 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(53); | |
1667 char* error = function(pimpl_, &result_); | |
1668 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | |
1669 return result_; | |
1670 } | |
1671 /** | |
1654 * @brief Get the format of the pixels of the 2D image. | 1672 * @brief Get the format of the pixels of the 2D image. |
1655 * | 1673 * |
1656 * Return the memory layout that is used for the 2D image that is encoded by this DICOM instance. This value depends on the extraction mode for the image. | 1674 * Return the memory layout that is used for the 2D image that is encoded by this DICOM instance. This value depends on the extraction mode for the image. |
1657 * | 1675 * |
1658 * @return The pixel format. | 1676 * @return The pixel format. |
1659 **/ | 1677 **/ |
1660 inline ::Orthanc::PixelFormat Instance::GetPixelFormat() | 1678 inline ::Orthanc::PixelFormat Instance::GetPixelFormat() |
1661 { | 1679 { |
1662 LAAW_INT32 result_; | 1680 LAAW_INT32 result_; |
1663 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_INT32*); | 1681 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_INT32*); |
1664 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(53); | 1682 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(54); |
1665 char* error = function(pimpl_, &result_); | 1683 char* error = function(pimpl_, &result_); |
1666 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1684 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1667 return static_cast< ::Orthanc::PixelFormat >(result_); | 1685 return static_cast< ::Orthanc::PixelFormat >(result_); |
1668 } | 1686 } |
1669 /** | 1687 /** |
1675 **/ | 1693 **/ |
1676 inline const void* Instance::GetBuffer() | 1694 inline const void* Instance::GetBuffer() |
1677 { | 1695 { |
1678 const void* result_; | 1696 const void* result_; |
1679 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const void**); | 1697 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const void**); |
1680 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(54); | 1698 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(55); |
1681 char* error = function(pimpl_, &result_); | 1699 char* error = function(pimpl_, &result_); |
1682 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1700 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1683 return reinterpret_cast< const void* >(result_); | 1701 return reinterpret_cast< const void* >(result_); |
1684 } | 1702 } |
1685 /** | 1703 /** |
1692 **/ | 1710 **/ |
1693 inline const void* Instance::GetBuffer(LAAW_UINT32 y) | 1711 inline const void* Instance::GetBuffer(LAAW_UINT32 y) |
1694 { | 1712 { |
1695 const void* result_; | 1713 const void* result_; |
1696 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const void**, LAAW_UINT32); | 1714 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const void**, LAAW_UINT32); |
1697 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(55); | 1715 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(56); |
1698 char* error = function(pimpl_, &result_, y); | 1716 char* error = function(pimpl_, &result_, y); |
1699 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1717 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1700 return reinterpret_cast< const void* >(result_); | 1718 return reinterpret_cast< const void* >(result_); |
1701 } | 1719 } |
1702 /** | 1720 /** |
1708 **/ | 1726 **/ |
1709 inline LAAW_UINT64 Instance::GetDicomSize() | 1727 inline LAAW_UINT64 Instance::GetDicomSize() |
1710 { | 1728 { |
1711 LAAW_UINT64 result_; | 1729 LAAW_UINT64 result_; |
1712 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT64*); | 1730 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, LAAW_UINT64*); |
1713 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(56); | 1731 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(57); |
1714 char* error = function(pimpl_, &result_); | 1732 char* error = function(pimpl_, &result_); |
1715 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1733 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1716 return result_; | 1734 return result_; |
1717 } | 1735 } |
1718 /** | 1736 /** |
1724 **/ | 1742 **/ |
1725 inline const void* Instance::GetDicom() | 1743 inline const void* Instance::GetDicom() |
1726 { | 1744 { |
1727 const void* result_; | 1745 const void* result_; |
1728 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const void**); | 1746 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const void**); |
1729 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(57); | 1747 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(58); |
1730 char* error = function(pimpl_, &result_); | 1748 char* error = function(pimpl_, &result_); |
1731 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1749 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1732 return reinterpret_cast< const void* >(result_); | 1750 return reinterpret_cast< const void* >(result_); |
1733 } | 1751 } |
1734 /** | 1752 /** |
1736 * | 1754 * |
1737 * Discard the downloaded 2D image, so as to make room in memory. | 1755 * Discard the downloaded 2D image, so as to make room in memory. |
1738 * | 1756 * |
1739 **/ | 1757 **/ |
1740 inline void Instance::DiscardImage() | 1758 inline void Instance::DiscardImage() |
1741 { | |
1742 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | |
1743 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(58); | |
1744 char* error = function(pimpl_); | |
1745 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | |
1746 } | |
1747 /** | |
1748 * @brief Discard the downloaded DICOM file, so as to make room in memory. | |
1749 * | |
1750 * Discard the downloaded DICOM file, so as to make room in memory. | |
1751 * | |
1752 **/ | |
1753 inline void Instance::DiscardDicom() | |
1754 { | 1759 { |
1755 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | 1760 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); |
1756 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(59); | 1761 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(59); |
1757 char* error = function(pimpl_); | 1762 char* error = function(pimpl_); |
1758 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1763 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1759 } | 1764 } |
1760 /** | 1765 /** |
1766 * @brief Discard the downloaded DICOM file, so as to make room in memory. | |
1767 * | |
1768 * Discard the downloaded DICOM file, so as to make room in memory. | |
1769 * | |
1770 **/ | |
1771 inline void Instance::DiscardDicom() | |
1772 { | |
1773 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*); | |
1774 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(60); | |
1775 char* error = function(pimpl_); | |
1776 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | |
1777 } | |
1778 /** | |
1761 * @brief Load a raw tag from the DICOM file. | 1779 * @brief Load a raw tag from the DICOM file. |
1762 * | 1780 * |
1763 * Load a raw tag from the DICOM file. | 1781 * Load a raw tag from the DICOM file. |
1764 * | 1782 * |
1765 * @param path The path to the tag of interest (e.g. "0020-000d"). | 1783 * @param path The path to the tag of interest (e.g. "0020-000d"). |
1766 **/ | 1784 **/ |
1767 inline void Instance::LoadTagContent(const ::std::string& path) | 1785 inline void Instance::LoadTagContent(const ::std::string& path) |
1768 { | 1786 { |
1769 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const char*); | 1787 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (void*, const char*); |
1770 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(60); | 1788 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(61); |
1771 char* error = function(pimpl_, path.c_str()); | 1789 char* error = function(pimpl_, path.c_str()); |
1772 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1790 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1773 } | 1791 } |
1774 /** | 1792 /** |
1775 * @brief Return the value of the raw tag that was loaded by LoadContent. | 1793 * @brief Return the value of the raw tag that was loaded by LoadContent. |
1780 **/ | 1798 **/ |
1781 inline ::std::string Instance::GetLoadedTagContent() const | 1799 inline ::std::string Instance::GetLoadedTagContent() const |
1782 { | 1800 { |
1783 const char* result_; | 1801 const char* result_; |
1784 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**); | 1802 typedef char* (LAAW_ORTHANC_CLIENT_CALL_CONV* Function) (const void*, const char**); |
1785 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(61); | 1803 Function function = (Function) ::OrthancClient::Internals::Library::GetInstance().GetFunction(62); |
1786 char* error = function(pimpl_, &result_); | 1804 char* error = function(pimpl_, &result_); |
1787 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); | 1805 ::OrthancClient::Internals::Library::GetInstance().ThrowExceptionIfNeeded(error); |
1788 return std::string(result_); | 1806 return std::string(result_); |
1789 } | 1807 } |
1790 } | 1808 } |