[med-svn] [Git][med-team/orthanc-dicomweb][upstream] New upstream version 1.16+dfsg
Sebastien Jodogne (@jodogne-guest)
gitlab at salsa.debian.org
Fri Jan 5 12:08:29 GMT 2024
Sebastien Jodogne pushed to branch upstream at Debian Med / orthanc-dicomweb
Commits:
ccc6bc4e by jodogne-guest at 2024-01-05T12:41:58+01:00
New upstream version 1.16+dfsg
- - - - -
23 changed files:
- .hg_archival.txt
- CMakeLists.txt
- NEWS
- Plugin/DicomWebClient.cpp
- Plugin/OrthancExplorer.js
- Plugin/Plugin.cpp
- Plugin/StowRs.cpp
- Plugin/WadoRs.h
- Plugin/WadoRsRetrieveFrames.cpp
- README
- Resources/CMake/JavaScriptLibraries.cmake
- Resources/Orthanc/CMake/Compiler.cmake
- Resources/Orthanc/CMake/DownloadOrthancFramework.cmake
- Resources/Orthanc/CMake/GoogleTestConfiguration.cmake
- Resources/Orthanc/Plugins/OrthancPluginCppWrapper.cpp
- Resources/Orthanc/Plugins/OrthancPluginCppWrapper.h
- − Resources/Orthanc/Toolchains/LinuxStandardBaseToolchain.cmake
- − Resources/Orthanc/Toolchains/MinGW-W64-Toolchain32.cmake
- − Resources/Orthanc/Toolchains/MinGW-W64-Toolchain64.cmake
- − Resources/Orthanc/Toolchains/MinGWToolchain.cmake
- Resources/SyncOrthancFolder.py
- TODO
- WebApplication/index.html
Changes:
=====================================
.hg_archival.txt
=====================================
@@ -1,6 +1,6 @@
repo: d5f45924411123cfd02d035fd50b8e37536eadef
-node: 8ccaf9f005a783c7ccd0a98aa438c58bd07a922a
-branch: OrthancDicomWeb-1.15
+node: 7f3f3dd90701572bc90a18148d02e9428c86be24
+branch: OrthancDicomWeb-1.16
latesttag: null
-latesttagdistance: 549
-changessincelatesttag: 581
+latesttagdistance: 567
+changessincelatesttag: 609
=====================================
CMakeLists.txt
=====================================
@@ -22,13 +22,13 @@ cmake_minimum_required(VERSION 2.8)
project(OrthancDicomWeb)
-set(ORTHANC_DICOM_WEB_VERSION "1.15")
+set(ORTHANC_DICOM_WEB_VERSION "1.16")
if (ORTHANC_DICOM_WEB_VERSION STREQUAL "mainline")
set(ORTHANC_FRAMEWORK_DEFAULT_VERSION "mainline")
set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "hg")
else()
- set(ORTHANC_FRAMEWORK_DEFAULT_VERSION "daf4807631c5") # TODO: upgrade to 1.12.2 when available
+ set(ORTHANC_FRAMEWORK_DEFAULT_VERSION "1.12.2")
set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "web")
endif()
@@ -235,3 +235,5 @@ add_dependencies(UnitTests AutogeneratedTarget)
target_link_libraries(UnitTests
${GOOGLE_TEST_LIBRARIES}
)
+
+DefineSourceBasenameForTarget(UnitTests)
\ No newline at end of file
=====================================
NEWS
=====================================
@@ -1,3 +1,11 @@
+Version 1.16 (2023-12-19)
+=========================
+
+* Removed misleading log messages about transcoding.
+ https://discourse.orthanc-server.org/t/dicomweb-plugin-1-13-possible-unnecessary-transcoding/3979
+* Fix parsing of Accept header "multipart/related; type=application/octet-stream; transfer-syntax=*" that is used by OHIF.
+* When retrieving frames, WADO-RS may now retrieve transcoded instances from Orthanc StorageCache (for Orthanc >= 1.12.2)
+
Version 1.15 (2023-08-24)
=========================
=====================================
Plugin/DicomWebClient.cpp
=====================================
@@ -776,7 +776,7 @@ private:
* chunked transfers, or a version of Orthanc <= 1.7.2 that
* supports chunk transfers, but cannot receive multipart
* messages larger than 2GB. The latter problem is fixed by:
- * https://hg.orthanc-server.com/orthanc/rev/36257d6f348f
+ * https://orthanc.uclouvain.be/hg/orthanc/rev/36257d6f348f
**/
if (client->IsChunkedTransfersAllowed())
{
=====================================
Plugin/OrthancExplorer.js
=====================================
@@ -126,7 +126,6 @@ $('#lookup').live('pagebeforeshow', function() {
.append($('<div>')
.addClass('ui-block-b')
.append($('<a>')
- .attr('id', 'coucou')
.attr('data-role', 'button')
.attr('href', '#')
.attr('data-icon', 'forward')
=====================================
Plugin/Plugin.cpp
=====================================
@@ -536,6 +536,8 @@ extern "C"
return -1;
}
+ SetPluginCanDownloadTranscodedFile(OrthancPlugins::CheckMinimalOrthancVersion(1, 12, 2));
+
#if HAS_ORTHANC_PLUGIN_CHUNKED_HTTP_CLIENT == 0
LOG(WARNING) << "Performance warning in DICOMweb: The plugin was compiled against "
<< "Orthanc SDK <= 1.5.6. STOW and WADO chunked transfers will be entirely stored in RAM.";
=====================================
Plugin/StowRs.cpp
=====================================
@@ -64,7 +64,7 @@ namespace OrthancPlugins
}
// Hotfix for bug #190, until the Orthanc Framework is fixed
- // https://bugs.orthanc-server.com/show_bug.cgi?id=190
+ // https://orthanc.uclouvain.be/bugs/show_bug.cgi?id=190
if (!boundary.empty() &&
boundary.size() >= 2 &&
boundary[0] == '"' &&
=====================================
Plugin/WadoRs.h
=====================================
@@ -100,3 +100,5 @@ void RetrieveSeriesRendered(OrthancPluginRestOutput* output,
void RetrieveStudyRendered(OrthancPluginRestOutput* output,
const char* url,
const OrthancPluginHttpRequest* request);
+
+void SetPluginCanDownloadTranscodedFile(bool enable);
\ No newline at end of file
=====================================
Plugin/WadoRsRetrieveFrames.cpp
=====================================
@@ -31,6 +31,8 @@
#include <boost/algorithm/string/replace.hpp>
#include <boost/lexical_cast.hpp>
+static bool pluginCanDownloadTranscodedFile = false;
+
static void TokenizeAndNormalize(std::vector<std::string>& tokens,
const std::string& source,
@@ -111,33 +113,24 @@ static bool ParseTransferSyntax(Orthanc::DicomTransferSyntax& syntax,
if (type == "application/octet-stream")
{
- if (transferSyntax.empty() ||
- transferSyntax == "1.2.840.10008.1.2.1")
+ if (transferSyntax.empty())
{
syntax = Orthanc::DicomTransferSyntax_LittleEndianExplicit;
return true;
}
- else if (transferSyntax == "1.2.840.10008.1.2")
- {
- syntax = Orthanc::DicomTransferSyntax_LittleEndianImplicit;
- return true;
- }
- else if (transferSyntax == "1.2.840.10008.1.2.2") // New in 1.3
- {
- syntax = Orthanc::DicomTransferSyntax_BigEndianExplicit;
- return false;
- }
else if (transferSyntax == "*")
{
- // New in DICOMweb plugin 1.1
- return false;
+ // don't change transferSyntax, it must have been set to the 'current' value before calling this method
+ return true;
}
else
{
- throw Orthanc::OrthancException(
- Orthanc::ErrorCode_BadRequest,
- "DICOMweb RetrieveFrames: Cannot specify a transfer syntax (" +
- transferSyntax + ") for default Little Endian uncompressed pixel data");
+ if (!Orthanc::LookupTransferSyntax(syntax, transferSyntax))
+ {
+ throw Orthanc::OrthancException(Orthanc::ErrorCode_NotImplemented,
+ "Unknown transfer syntax in 'Accept' header: " + transferSyntax);
+ }
+ return true;
}
}
else
@@ -287,7 +280,7 @@ static bool ParseTransferSyntax(Orthanc::DicomTransferSyntax& syntax,
}
}
- // By default, DICOMweb expectes Little Endian uncompressed pixel data
+ // By default, DICOMweb expects Little Endian uncompressed pixel data
syntax = Orthanc::DicomTransferSyntax_LittleEndianExplicit;
return true;
}
@@ -435,44 +428,73 @@ static void RetrieveFrames(OrthancPluginRestOutput* output,
std::list<unsigned int>& frames)
{
std::string orthancId, studyInstanceUid, seriesInstanceUid, sopInstanceUid;
- OrthancPlugins::MemoryBuffer content;
- if (LocateInstance(output, orthancId, studyInstanceUid, seriesInstanceUid, sopInstanceUid, request) &&
- content.RestApiGet("/instances/" + orthancId + "/file", false))
+ if (LocateInstance(output, orthancId, studyInstanceUid, seriesInstanceUid, sopInstanceUid, request))
{
- if (allFrames)
- {
- OrthancPlugins::LogInfo("DICOMweb RetrieveFrames on " + orthancId + ", all frames");
- }
- else
- {
- std::string s = "DICOMweb RetrieveFrames on " + orthancId + ", frames: ";
- for (std::list<unsigned int>::const_iterator
- frame = frames.begin(); frame != frames.end(); ++frame)
+ OrthancPlugins::MemoryBuffer content;
+ Orthanc::DicomTransferSyntax currentSyntax;
+ std::unique_ptr<OrthancPlugins::DicomInstance> instance;
+
+ { // logging only
+ if (allFrames)
{
- s += boost::lexical_cast<std::string>(*frame + 1) + " ";
+ OrthancPlugins::LogInfo("DICOMweb RetrieveFrames on " + orthancId + ", all frames");
}
+ else
+ {
+ std::string s = "DICOMweb RetrieveFrames on " + orthancId + ", frames: ";
+ for (std::list<unsigned int>::const_iterator
+ frame = frames.begin(); frame != frames.end(); ++frame)
+ {
+ s += boost::lexical_cast<std::string>(*frame + 1) + " ";
+ }
- OrthancPlugins::LogInfo(s);
+ OrthancPlugins::LogInfo(s);
+ }
}
- Orthanc::DicomTransferSyntax targetSyntax;
+ std::string currentSyntaxString;
+ if (!OrthancPlugins::RestApiGetString(currentSyntaxString, "/instances/" + orthancId + "/metadata/TransferSyntax", false))
+ {
+ throw Orthanc::OrthancException(Orthanc::ErrorCode_InternalError, "DICOMWeb: Unable to get TransferSyntax for instance " + orthancId);
+ }
- std::unique_ptr<OrthancPlugins::DicomInstance> instance;
+ if (!Orthanc::LookupTransferSyntax(currentSyntax, currentSyntaxString))
+ {
+ throw Orthanc::OrthancException(Orthanc::ErrorCode_NotImplemented, "Unknown transfer syntax: " + currentSyntaxString);
+ }
+
+ Orthanc::DicomTransferSyntax targetSyntax = currentSyntax;
+ bool transcodeThisInstance = false;
+
if (ParseTransferSyntax(targetSyntax, request))
{
- OrthancPlugins::LogInfo("DICOMweb RetrieveFrames: Transcoding instance " + orthancId +
- " to transfer syntax " + Orthanc::GetTransferSyntaxUid(targetSyntax));
+ transcodeThisInstance = targetSyntax != currentSyntax;
+ }
- instance.reset(OrthancPlugins::DicomInstance::Transcode(
- content.GetData(), content.GetSize(), GetTransferSyntaxUid(targetSyntax)));
+ // maximize the use the Orthanc storage cache. Since 1.12.2, transcoded file may be stored in the storage cache
+ if (pluginCanDownloadTranscodedFile && transcodeThisInstance)
+ {
+ if (!content.RestApiGet("/instances/" + orthancId + "/file?transcode=" + Orthanc::GetTransferSyntaxUid(targetSyntax), false))
+ {
+ throw Orthanc::OrthancException(Orthanc::ErrorCode_InternalError, "DICOMWeb: Unable to get transcoded file for for instance " + orthancId);
+ }
+ instance.reset(new OrthancPlugins::DicomInstance(content.GetData(), content.GetSize()));
}
- else
+ else // pre 1.12.2 code (or no transcoding needed)
{
+ if (!content.RestApiGet("/instances/" + orthancId + "/file", false))
+ {
+ throw Orthanc::OrthancException(Orthanc::ErrorCode_InternalError, "DICOMWeb: Unable to get file for for instance " + orthancId);
+ }
instance.reset(new OrthancPlugins::DicomInstance(content.GetData(), content.GetSize()));
- if (!Orthanc::LookupTransferSyntax(targetSyntax, instance->GetTransferSyntaxUid()))
+
+ if (transcodeThisInstance)
{
- throw Orthanc::OrthancException(Orthanc::ErrorCode_NotImplemented,
- "Unknown transfer syntax: " + std::string(GetTransferSyntaxUid(targetSyntax)));
+ OrthancPlugins::LogInfo("DICOMweb RetrieveFrames: Transcoding instance " + orthancId +
+ " to transfer syntax " + Orthanc::GetTransferSyntaxUid(targetSyntax));
+
+ instance.reset(OrthancPlugins::DicomInstance::Transcode(
+ content.GetData(), content.GetSize(), GetTransferSyntaxUid(targetSyntax)));
}
}
@@ -513,3 +535,8 @@ void RetrieveSelectedFrames(OrthancPluginRestOutput* output,
ParseFrameList(frames, request);
RetrieveFrames(output, request, false, frames);
}
+
+void SetPluginCanDownloadTranscodedFile(bool enable)
+{
+ pluginCanDownloadTranscodedFile = enable;
+}
\ No newline at end of file
=====================================
README
=====================================
@@ -36,7 +36,7 @@ Installation and usage
----------------------
Build and usage instructions are available in the Orthanc Book:
-http://book.orthanc-server.com/plugins/dicomweb.html
+https://orthanc.uclouvain.be/book/plugins/dicomweb.html
Contributing
@@ -44,7 +44,7 @@ Contributing
Instructions for contributing to the Orthanc project are included in
the Orthanc Book:
-https://book.orthanc-server.com/developers/repositories.html
+https://orthanc.uclouvain.be/book/developers/repositories.html
Licensing: AGPL
=====================================
Resources/CMake/JavaScriptLibraries.cmake
=====================================
@@ -18,7 +18,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-set(BASE_URL "http://orthanc.osimis.io/ThirdPartyDownloads/dicom-web")
+set(BASE_URL "https://orthanc.uclouvain.be/downloads/third-party-downloads/dicom-web")
DownloadPackage(
"da0189f7c33bf9f652ea65401e0a3dc9"
=====================================
Resources/Orthanc/CMake/Compiler.cmake
=====================================
@@ -263,3 +263,24 @@ if (CMAKE_COMPILER_IS_GNUCXX)
# preceding batches. https://cmake.org/Bug/view.php?id=14874
set(CMAKE_CXX_ARCHIVE_APPEND "<CMAKE_AR> <LINK_FLAGS> q <TARGET> <OBJECTS>")
endif()
+
+
+# This function defines macro "__ORTHANC_FILE__" as a replacement to
+# macro "__FILE__", as the latter leaks the full path of the source
+# files in the binaries
+# https://stackoverflow.com/questions/8487986/file-macro-shows-full-path
+# https://twitter.com/wget42/status/1676877802375634944?s=20
+function(DefineSourceBasenameForTarget targetname)
+ # Microsoft Visual Studio is extremely slow if using
+ # "set_property()", we only enable this feature for gcc and clang
+ if (CMAKE_COMPILER_IS_GNUCXX OR
+ CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
+ get_target_property(source_files "${targetname}" SOURCES)
+ foreach(sourcefile ${source_files})
+ get_filename_component(basename "${sourcefile}" NAME)
+ set_property(
+ SOURCE "${sourcefile}" APPEND
+ PROPERTY COMPILE_DEFINITIONS "__ORTHANC_FILE__=\"${basename}\"")
+ endforeach()
+ endif()
+endfunction()
=====================================
Resources/Orthanc/CMake/DownloadOrthancFramework.cmake
=====================================
@@ -153,9 +153,13 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "hg" OR
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "1.11.2")
set(ORTHANC_FRAMEWORK_MD5 "ede3de356493a8868545f8cb4b8bc8b5")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "1.11.3")
- set(ORTHANC_FRAMEWORK_MD5 "5c1b11009d782f248739919db6bf7f7a")
+ set(ORTHANC_FRAMEWORK_MD5 "f941c0f5771db7616e7b7961026a60e2")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "1.12.0")
set(ORTHANC_FRAMEWORK_MD5 "d32a0cde03b6eb603d8dd2b33d38bf1b")
+ elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "1.12.1")
+ set(ORTHANC_FRAMEWORK_MD5 "8a435140efc8ff4a01d8242f092f21de")
+ elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "1.12.2")
+ set(ORTHANC_FRAMEWORK_MD5 "d2476b9e796e339ac320b5333489bdb3")
# Below this point are development snapshots that were used to
# release some plugin, before an official release of the Orthanc
@@ -166,21 +170,27 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "hg" OR
#
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "ae0e3fd609df")
# DICOMweb 1.1 (framework pre-1.6.0)
+ set(ORTHANC_FRAMEWORK_PRE_RELEASE ON)
set(ORTHANC_FRAMEWORK_MD5 "7e09e9b530a2f527854f0b782d7e0645")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "82652c5fc04f")
# Stone Web viewer 1.0 (framework pre-1.8.1)
+ set(ORTHANC_FRAMEWORK_PRE_RELEASE ON)
set(ORTHANC_FRAMEWORK_MD5 "d77331d68917e66a3f4f9b807bbdab7f")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "4a3ba4bf4ba7")
# PostgreSQL 3.3 (framework pre-1.8.2)
+ set(ORTHANC_FRAMEWORK_PRE_RELEASE ON)
set(ORTHANC_FRAMEWORK_MD5 "2d82bddf06f9cfe82095495cb3b8abde")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "23ad1b9c7800")
# For "Toolbox::ReadJson()" and "Toolbox::Write{...}Json()" (pre-1.9.0)
+ set(ORTHANC_FRAMEWORK_PRE_RELEASE ON)
set(ORTHANC_FRAMEWORK_MD5 "9af92080e57c60dd288eba46ce606c00")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "b2e08d83e21d")
# WSI 1.1 (framework pre-1.10.0), to remove "-std=c++11"
+ set(ORTHANC_FRAMEWORK_PRE_RELEASE ON)
set(ORTHANC_FRAMEWORK_MD5 "2eaa073cbb4b44ffba199ad93393b2b1")
elseif (ORTHANC_FRAMEWORK_VERSION STREQUAL "daf4807631c5")
# DICOMweb 1.15 (framework pre-1.12.2)
+ set(ORTHANC_FRAMEWORK_PRE_RELEASE ON)
set(ORTHANC_FRAMEWORK_MD5 "c644aff2817306b3207c98c92e43f35f")
endif()
endif()
@@ -269,7 +279,7 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "hg")
else()
message("Forking the Orthanc source repository using Mercurial")
execute_process(
- COMMAND ${ORTHANC_FRAMEWORK_HG} clone "https://hg.orthanc-server.com/orthanc/"
+ COMMAND ${ORTHANC_FRAMEWORK_HG} clone "https://orthanc.uclouvain.be/hg/orthanc/"
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
RESULT_VARIABLE Failure
)
@@ -318,7 +328,11 @@ if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "web")
else()
# Default case: Download from the official Web site
set(ORTHANC_FRAMEMORK_FILENAME Orthanc-${ORTHANC_FRAMEWORK_VERSION}.tar.gz)
- set(ORTHANC_FRAMEWORK_URL "https://orthanc.uclouvain.be/third-party-downloads/orthanc-framework/${ORTHANC_FRAMEMORK_FILENAME}")
+ if (ORTHANC_FRAMEWORK_PRE_RELEASE)
+ set(ORTHANC_FRAMEWORK_URL "https://orthanc.uclouvain.be/downloads/third-party-downloads/orthanc-framework/${ORTHANC_FRAMEMORK_FILENAME}")
+ else()
+ set(ORTHANC_FRAMEWORK_URL "https://orthanc.uclouvain.be/downloads/sources/orthanc/${ORTHANC_FRAMEMORK_FILENAME}")
+ endif()
endif()
set(ORTHANC_FRAMEWORK_ARCHIVE "${CMAKE_SOURCE_DIR}/ThirdPartyDownloads/${ORTHANC_FRAMEMORK_FILENAME}")
=====================================
Resources/Orthanc/CMake/GoogleTestConfiguration.cmake
=====================================
@@ -50,7 +50,7 @@ if (USE_GOOGLE_TEST_DEBIAN_PACKAGE)
elseif (STATIC_BUILD OR NOT USE_SYSTEM_GOOGLE_TEST)
set(GOOGLE_TEST_SOURCES_DIR ${CMAKE_BINARY_DIR}/googletest-release-1.8.1)
- set(GOOGLE_TEST_URL "https://orthanc.uclouvain.be/third-party-downloads/gtest-1.8.1.tar.gz")
+ set(GOOGLE_TEST_URL "https://orthanc.uclouvain.be/downloads/third-party-downloads/gtest-1.8.1.tar.gz")
set(GOOGLE_TEST_MD5 "2e6fbeb6a91310a16efe181886c59596")
DownloadPackage(${GOOGLE_TEST_MD5} ${GOOGLE_TEST_URL} "${GOOGLE_TEST_SOURCES_DIR}")
=====================================
Resources/Orthanc/Plugins/OrthancPluginCppWrapper.cpp
=====================================
@@ -79,6 +79,10 @@ namespace OrthancPlugins
}
}
+ void ResetGlobalContext()
+ {
+ globalContext_ = NULL;
+ }
bool HasGlobalContext()
{
@@ -1670,15 +1674,16 @@ namespace OrthancPlugins
return true;
}
- // Parse the version
- int aa, bb, cc;
- if (
#ifdef _MSC_VER
- sscanf_s
+#define ORTHANC_SCANF sscanf_s
#else
- sscanf
+#define ORTHANC_SCANF sscanf
#endif
- (version, "%4d.%4d.%4d", &aa, &bb, &cc) != 3 ||
+
+ // Parse the version
+ int aa, bb, cc = 0;
+ if ((ORTHANC_SCANF(version, "%4d.%4d.%4d", &aa, &bb, &cc) != 3 &&
+ ORTHANC_SCANF(version, "%4d.%4d", &aa, &bb) != 2) ||
aa < 0 ||
bb < 0 ||
cc < 0)
@@ -2602,7 +2607,7 @@ namespace OrthancPlugins
if (body.isMember(KEY_PRIORITY))
{
- if (body[KEY_PRIORITY].type() != Json::booleanValue)
+ if (body[KEY_PRIORITY].type() != Json::intValue)
{
#if HAS_ORTHANC_EXCEPTION == 1
throw Orthanc::OrthancException(Orthanc::ErrorCode_BadFileFormat,
=====================================
Resources/Orthanc/Plugins/OrthancPluginCppWrapper.h
=====================================
@@ -137,6 +137,8 @@ namespace OrthancPlugins
void SetGlobalContext(OrthancPluginContext* context);
+ void ResetGlobalContext();
+
bool HasGlobalContext();
OrthancPluginContext* GetGlobalContext();
=====================================
Resources/Orthanc/Toolchains/LinuxStandardBaseToolchain.cmake deleted
=====================================
@@ -1,100 +0,0 @@
-# Orthanc - A Lightweight, RESTful DICOM Store
-# Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
-# Department, University Hospital of Liege, Belgium
-# Copyright (C) 2017-2023 Osimis S.A., Belgium
-# Copyright (C) 2021-2023 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
-#
-# This program is free software: you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public License
-# as published by the Free Software Foundation, either version 3 of
-# the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this program. If not, see
-# <http://www.gnu.org/licenses/>.
-
-
-#
-# Full build, as used on the BuildBot CIS:
-#
-# $ LSB_CC=gcc-4.8 LSB_CXX=g++-4.8 cmake ../OrthancServer/ -DCMAKE_BUILD_TYPE=Debug -DCMAKE_TOOLCHAIN_FILE=../OrthancFramework/Resources/Toolchains/LinuxStandardBaseToolchain.cmake -DUSE_LEGACY_JSONCPP=ON -DUSE_LEGACY_LIBICU=ON -DUSE_LEGACY_BOOST=ON -DBOOST_LOCALE_BACKEND=icu -DENABLE_PKCS11=ON -G Ninja
-#
-# Or, more lightweight version (without libp11 and ICU):
-#
-# $ LSB_CC=gcc-4.8 LSB_CXX=g++-4.8 cmake ../OrthancServer/ -DCMAKE_BUILD_TYPE=Debug -DCMAKE_TOOLCHAIN_FILE=../OrthancFramework/Resources/Toolchains/LinuxStandardBaseToolchain.cmake -DUSE_LEGACY_JSONCPP=ON -DUSE_LEGACY_BOOST=ON -G Ninja
-#
-
-INCLUDE(CMakeForceCompiler)
-
-SET(LSB_PATH $ENV{LSB_PATH} CACHE STRING "")
-SET(LSB_CC $ENV{LSB_CC} CACHE STRING "")
-SET(LSB_CXX $ENV{LSB_CXX} CACHE STRING "")
-SET(LSB_TARGET_VERSION "4.0" CACHE STRING "")
-
-IF ("${LSB_PATH}" STREQUAL "")
- SET(LSB_PATH "/opt/lsb")
-ENDIF()
-
-IF (EXISTS ${LSB_PATH}/lib64)
- SET(LSB_TARGET_PROCESSOR "x86_64")
- SET(LSB_LIBPATH ${LSB_PATH}/lib64-${LSB_TARGET_VERSION})
-ELSEIF (EXISTS ${LSB_PATH}/lib)
- SET(LSB_TARGET_PROCESSOR "x86")
- SET(LSB_LIBPATH ${LSB_PATH}/lib-${LSB_TARGET_VERSION})
-ELSE()
- MESSAGE(FATAL_ERROR "Unable to detect the target processor architecture. Check the LSB_PATH environment variable.")
-ENDIF()
-
-SET(LSB_CPPPATH ${LSB_PATH}/include)
-SET(PKG_CONFIG_PATH ${LSB_LIBPATH}/pkgconfig/)
-
-# the name of the target operating system
-SET(CMAKE_SYSTEM_NAME Linux)
-SET(CMAKE_SYSTEM_VERSION LinuxStandardBase)
-SET(CMAKE_SYSTEM_PROCESSOR ${LSB_TARGET_PROCESSOR})
-
-# which compilers to use for C and C++
-SET(CMAKE_C_COMPILER ${LSB_PATH}/bin/lsbcc)
-
-if (${CMAKE_VERSION} VERSION_LESS "3.6.0")
- CMAKE_FORCE_CXX_COMPILER(${LSB_PATH}/bin/lsbc++ GNU)
-else()
- SET(CMAKE_CXX_COMPILER ${LSB_PATH}/bin/lsbc++)
-endif()
-
-# here is the target environment located
-SET(CMAKE_FIND_ROOT_PATH ${LSB_PATH})
-
-# adjust the default behaviour of the FIND_XXX() commands:
-# search headers and libraries in the target environment, search
-# programs in the host environment
-SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
-SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY NEVER)
-SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE NEVER)
-
-SET(CMAKE_CROSSCOMPILING OFF)
-
-
-SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --lsb-target-version=${LSB_TARGET_VERSION} -I${LSB_PATH}/include" CACHE INTERNAL "" FORCE)
-SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --lsb-target-version=${LSB_TARGET_VERSION} -nostdinc++ -I${LSB_PATH}/include -I${LSB_PATH}/include/c++ -I${LSB_PATH}/include/c++/backward" CACHE INTERNAL "" FORCE)
-SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} --lsb-target-version=${LSB_TARGET_VERSION} -L${LSB_LIBPATH} --lsb-besteffort" CACHE INTERNAL "" FORCE)
-SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} --lsb-target-version=${LSB_TARGET_VERSION} -L${LSB_LIBPATH} --lsb-besteffort" CACHE INTERNAL "" FORCE)
-
-if (NOT "${LSB_CXX}" STREQUAL "")
- SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --lsb-cxx=${LSB_CXX}")
- SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} --lsb-cxx=${LSB_CXX}")
- SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} --lsb-cxx=${LSB_CXX}")
-endif()
-
-if (NOT "${LSB_CC}" STREQUAL "")
- SET(CMAKE_C_FLAGS "${CMAKE_CC_FLAGS} --lsb-cc=${LSB_CC}")
- SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --lsb-cc=${LSB_CC}")
- SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} --lsb-cc=${LSB_CC}")
- SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} --lsb-cc=${LSB_CC}")
-endif()
-
=====================================
Resources/Orthanc/Toolchains/MinGW-W64-Toolchain32.cmake deleted
=====================================
@@ -1,38 +0,0 @@
-# Orthanc - A Lightweight, RESTful DICOM Store
-# Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
-# Department, University Hospital of Liege, Belgium
-# Copyright (C) 2017-2023 Osimis S.A., Belgium
-# Copyright (C) 2021-2023 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
-#
-# This program is free software: you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public License
-# as published by the Free Software Foundation, either version 3 of
-# the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this program. If not, see
-# <http://www.gnu.org/licenses/>.
-
-
-# the name of the target operating system
-set(CMAKE_SYSTEM_NAME Windows)
-
-# which compilers to use for C and C++
-set(CMAKE_C_COMPILER i686-w64-mingw32-gcc)
-set(CMAKE_CXX_COMPILER i686-w64-mingw32-g++)
-set(CMAKE_RC_COMPILER i686-w64-mingw32-windres)
-
-# here is the target environment located
-set(CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32)
-
-# adjust the default behaviour of the FIND_XXX() commands:
-# search headers and libraries in the target environment, search
-# programs in the host environment
-set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
-set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
-set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
=====================================
Resources/Orthanc/Toolchains/MinGW-W64-Toolchain64.cmake deleted
=====================================
@@ -1,38 +0,0 @@
-# Orthanc - A Lightweight, RESTful DICOM Store
-# Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
-# Department, University Hospital of Liege, Belgium
-# Copyright (C) 2017-2023 Osimis S.A., Belgium
-# Copyright (C) 2021-2023 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
-#
-# This program is free software: you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public License
-# as published by the Free Software Foundation, either version 3 of
-# the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this program. If not, see
-# <http://www.gnu.org/licenses/>.
-
-
-# the name of the target operating system
-set(CMAKE_SYSTEM_NAME Windows)
-
-# which compilers to use for C and C++
-set(CMAKE_C_COMPILER x86_64-w64-mingw32-gcc)
-set(CMAKE_CXX_COMPILER x86_64-w64-mingw32-g++)
-set(CMAKE_RC_COMPILER x86_64-w64-mingw32-windres)
-
-# here is the target environment located
-set(CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32)
-
-# adjust the default behaviour of the FIND_XXX() commands:
-# search headers and libraries in the target environment, search
-# programs in the host environment
-set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
-set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
-set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
=====================================
Resources/Orthanc/Toolchains/MinGWToolchain.cmake deleted
=====================================
@@ -1,41 +0,0 @@
-# Orthanc - A Lightweight, RESTful DICOM Store
-# Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
-# Department, University Hospital of Liege, Belgium
-# Copyright (C) 2017-2023 Osimis S.A., Belgium
-# Copyright (C) 2021-2023 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
-#
-# This program is free software: you can redistribute it and/or
-# modify it under the terms of the GNU Lesser General Public License
-# as published by the Free Software Foundation, either version 3 of
-# the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this program. If not, see
-# <http://www.gnu.org/licenses/>.
-
-
-# the name of the target operating system
-set(CMAKE_SYSTEM_NAME Windows)
-
-# which compilers to use for C and C++
-set(CMAKE_C_COMPILER i586-mingw32msvc-gcc)
-set(CMAKE_CXX_COMPILER i586-mingw32msvc-g++)
-set(CMAKE_RC_COMPILER i586-mingw32msvc-windres)
-
-# here is the target environment located
-set(CMAKE_FIND_ROOT_PATH /usr/i586-mingw32msvc)
-
-# adjust the default behaviour of the FIND_XXX() commands:
-# search headers and libraries in the target environment, search
-# programs in the host environment
-set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
-set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
-set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
-
-set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DSTACK_SIZE_PARAM_IS_A_RESERVATION=0x10000" CACHE INTERNAL "" FORCE)
-set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DSTACK_SIZE_PARAM_IS_A_RESERVATION=0x10000" CACHE INTERNAL "" FORCE)
=====================================
Resources/SyncOrthancFolder.py
=====================================
@@ -12,7 +12,7 @@ import urllib.request
TARGET = os.path.join(os.path.dirname(__file__), 'Orthanc')
PLUGIN_SDK_VERSION = '1.12.1'
-REPOSITORY = 'https://hg.orthanc-server.com/orthanc/raw-file'
+REPOSITORY = 'https://orthanc.uclouvain.be/hg/orthanc/raw-file'
FILES = [
('OrthancFramework/Resources/CMake/AutoGeneratedCode.cmake', 'CMake'),
=====================================
TODO
=====================================
@@ -1,3 +1,17 @@
+* when retrieving frames from Multi-frame instances, we should not transcode the whole instance for each frame !!!
+ For a 90MB instance with 88 frames, OHIF is unusable because of this !
+ Sample request:
+ curl -H "Accept: multipart/related; type=application/octet-stream" http://localhost:8043/dicom-web/studies/1.2.156.112536.1.2143.25015081191207.14610300430.5/series/1.2.156.112536.1.2143.25015081191207.14610300430.6/instances/1.2.156.112536.1.2143.25015081191207.14610309990.44/frames/3 --output /tmp/out.bin
+ check for these logs: DICOMweb RetrieveFrames: Transcoding instance a7aec17a-e296e51f-2abe8ad8-bc95d57b-4de269d0 to transfer syntax 1.2.840.10008.1.2.1
+
+ We should very likely implement a cache in the DicomWEB plugin and make sure that, if 3 clients are requesting the same instance at the same time, we only
+ request one transcoding.
+
+ No such issue in StoneViewer since Stone downloads the whole file. However, Stone uses 2-3 workers at the same time and the file is read 2-3 times at the same time
+ before it ends up in Orthanc cache -> we should introduce a state "is_being_loaded" in caches and have other consumers wait for it to be available.
+ https://discourse.orthanc-server.org/t/possible-memory-leak-with-multiframe-dicom-orthanc-ohif/3988/12
+
+
* Implement capabilities: https://www.dicomstandard.org/using/dicomweb/capabilities/
from https://groups.google.com/d/msgid/orthanc-users/c60227f2-c6da-4fd9-9b03-3ce9bf7d1af5n%40googlegroups.com?utm_medium=email&utm_source=footer
@@ -8,6 +22,10 @@
* Add support for application/zip in /dicom-web/studies/ (aka sup 211: https://www.dicomstandard.org/docs/librariesprovider2/dicomdocuments/news/ftsup/docs/sups/sup211.pdf?sfvrsn=9fe9edae_2)
+* Support private tags in search fields:
+ https://discourse.orthanc-server.org/t/dicomweb-plugin-exception-of-unknown-dicom-tag-for-private-data-element-tags-while-using-query-parameters/3998
+
+
* Based on this discussion: https://discourse.orthanc-server.org/t/series-metadata-retrieval-is-very-long-even-with-configuration-optimization/3389
optimize studies/.../series/.../metadata route when "SeriesMetadata" is set
to "MainDicomTags" and "ExtraMainDicomTags" are configured according to recommandation
=====================================
WebApplication/index.html
=====================================
@@ -44,7 +44,7 @@
</p>
<p>
<a class="btn btn-primary btn-lg"
- href="https://book.orthanc-server.com/plugins/dicomweb.html"
+ href="https://orthanc.uclouvain.be/book/plugins/dicomweb.html"
target="_blank" role="button">Open documentation</a>
<a class="btn btn-primary btn-lg"
:href="orthancApiRoot"
View it on GitLab: https://salsa.debian.org/med-team/orthanc-dicomweb/-/commit/ccc6bc4e9a13ec90f0fdc7c1324f8a7ad33b631f
--
View it on GitLab: https://salsa.debian.org/med-team/orthanc-dicomweb/-/commit/ccc6bc4e9a13ec90f0fdc7c1324f8a7ad33b631f
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20240105/bc441989/attachment-0001.htm>
More information about the debian-med-commit
mailing list