Weasis viewer and Conquest web - working, 3.0 option in 1.4.19c1

  • Has anyone been able to get the Weasis viewer to work successfully with the Conquest web?


    I'm running Conquest 1.4.17alpha web and it works fine. We're trying to enable a java viewer as opposed to running the viewer=serversideviewer in the dicom.ini. I've tried the configuration below but can't get the .jnlp to launch successfully.


    [webdefaults]


    viewer = weasis


    [imagejaviewer]


    source =substance.jnlp


    Any suggestions?


    Thanks,


    Robby

  • Hi,


    this is not the way to do it. Weasis uses WADO and several people have tried it, so search the forum. I have not though.


    These entries affect the conquest generated webpages only (starting from dgate.exe?mode=top) and mean:


    [webdefaults]
    viewer = viewername <----------- look for [viewername]
    [viwewername]
    source =filename.lua <----------- must be lua or cq code that generates web page to view a series


    Samples are imagejaviewer.cq and flexviewer.lua.


    Marcel
    Marcel

  • Hi Robby,


    Looking at the samples on the weasis page it should not be too hard to wip up a lua viewer file that should do the job.


    [webdefaults]
    viewer = weasis
    [weasis]
    source =weasis.lua


    Take a sample jnlp file and put it in weasis.lua:

    Code
    -- create table list here
    print [[
    INSERT CONTENTS OF SAMPLE jnlp FILE HERE
    ]]


    Where in the sample file


    <argument>$dicom:get -r http://www.dcm4che.org/conflue…chments/16121882/RENALAN2
    </argument>


    is filled with all conquest wado URLS using a bit of code like this:


    <argument>$dicom:get -r ]] .. table.concat(list, ' ') .. [[


    Before the print you then have to fill the list:


    list={}
    -- do a dicom query based on the CGI parameters similar as in wadoviewer.lua
    for k,v in ipairs(queryresult)
    table.insert(list,
    script_name .. "?requestType=WADO&contentType=application/dicom&studyUID="..v.StudyInstanceUID..
    "&seriesUID="..v.SeriesInstanceUID.."&objectUID=" .. v.SOPInstanceUID)
    end


    I will try it out later and post the code.


    Marcel

  • Hi,


    This helps:


    [weasisviewer]
    source = viewers\launchWeasis.cq
    header = Content-Type: application/x-java-jnlp-file\


    It will at least open the viewer. If I manually substitute this in the file:


    <argument>$dicom:get -r http://cf-j10/cgi-bin/dgate.ex…0.425&dsize=0&compress=un
    </argument>


    It will show one slice of my data. Tomorrow more..., probably need a lua script to generate an XML file with dicom imag e references


    Marcel

  • Great info Marcel!


    Thanks for the assistance. I'm not a developer so I'm not sure what needs to go in a .lua or .cq file.


    If I can get the weasis viewer to work with Conquest web this would solve all my problems and I would reward you handsomely :)


    Many thanks,


    Robby

  • Hi,


    I got basic weasis connectivity going, with these limits: you replace seriesviewer by a weasisviewer script, which starts up weasis for an individual series. Since starting weases takes quite a long time (10 s or more), it may be better to start it at study level. To do this I can:


    1) start it at study level when you ask to view a series
    or 2) create a new studyviewer option (requires a dgate.exe update)
    or 3) create a specific weasis starter page where you query for the patient/study, e.g., dgate.exe?mode=weasisstarter


    Which is preferable depends on the intended application. How do you see this? If you want to mix conquest web functions with weasis then 1 or 2 may be preferable. 3) Is good for a standalone application.


    Another limitation is that weasis cannot pass bridge or address information into dgate.exe (it generates the '?' that starts the variable part of the URL itself). So weasis will only allow viewing of data for one server per conquest web system.


    Marcel

  • All that we are looking for is for some type of series viewer (definately something more that viewer=serversideviewer) to launch when the results are returned from querying PatientID or PatientName from the Conquest web.


    I can get the viewer to launch if I pass all the info manually thru the URL, even from over the internet. But, obviously, the doctors will not be able to do this. They just need a viewer to be used over the internet.


    If I could edit the dicom.ini to lauch the weasis viewer that would be ideal. But I have no knowledge of what goes into creating a weasis.cq file or weais.jnlp file.


    Many continued thanks!


    Robby

  • With the 1.4.17beta update weasis viewer works (rudimentary).


    Put this dicom.ini in cgi-bin:


    viewer = weasisviewer
    [weasisviewer]
    source = viewers\launchWeasis.cq
    header = Content-Type: application/x-java-jnlp-file\
    [weasisseriesxml]
    source = viewers\weasisseriesxml.lua


    Put this file in cgi-bin\viewers\launchWeasis.cq (almost identical copy from: http://www.dcm4che.org/conflue…sis+from+any+environments)

    XML
    <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE jnlp PUBLIC "-//Sun Microsystems, Inc//DTD JNLP Descriptor 6.0//EN" "http://java.sun.com/dtd/JNLP-6.0.dtd"> <jnlp spec="1.6+" version="1.1.3" codebase="http://dicom.vital-it.ch:8089/weasis" href=""> <information> <title>Weasis</title> <vendor>Hôpitaux Universitaires de Genève (HUG)</vendor> <homepage href="docs/help.html"/> <description>DICOM images viewer</description> <description kind="short">An application to visualize and analyze DICOM images.</description> <description kind="one-line">DICOM images viewer</description> <description kind="tooltip">Weasis</description> <icon href="images/logo-button.png" kind="default" /> <icon href="images/about.png" kind="splash" /> </information> <security> <all-permissions/> </security> <resources> <!-- Requires Java SE 6 update 10 release for jnlp extension without codebase (substance.jnlp) --> <j2se version="1.6.0_10+" href="http://java.sun.com/products/autodl/j2se" initial-heap-size="128m" max-heap-size="512m" /> <j2se version="1.6.0_10+" initial-heap-size="128m" max-heap-size="512m" /> <!-- Weasis launcher --> <jar href="weasis-launcher.jar" main="true" /> <!-- OSGI Felix framework --> <jar href="felix.jar" /> <!-- Optional library (Substance Look and feel, only since version 1.0.8). Requires the new Java Plug-in introduced in the Java SE 6 update 10 release.For previous JRE 6, substance.jnlp needs a static codebase URL --> <extension href="substance.jnlp"/> <!-- Allows to get files in pack200 compression, only available from Weasis 1.1.2 --> <property name="jnlp.packEnabled" value="true" /> <!-- Required parameter. Define the location of config.properties (the OSGI configuration and the list of plug-ins to install/start) --> <property name="felix.config.properties" value="http://dicom.vital-it.ch:8089/weasis/conf/config.properties" /> <!-- Required parameter. Define the code base of Weasis for the JNLP --> <property name="weasis.codebase.url" value="http://dicom.vital-it.ch:8089/weasis" /> <!-- Required parameter. Start OSGI console on the port 17179 --> <property name="gosh.args" value="-sc telnetd -p 17179 start" /> <!-- Optional parameter. Allows to have the Weasis menu bar in the top bar on Mac OS X (works only with the native Aqua look and feel) --> <property name="apple.laf.useScreenMenuBar" value="true" /> <!-- Optional parameter. Allows to get plug-ins translations --> <property name="weasis.i18n" value="http://dicom.vital-it.ch:8089/weasis-i18n" /> <!-- Optional Weasis Documentation, appears in the menu Help > User Manual --> <!-- <property name="weasis.help.url" value="http://dicom.vital-it.ch:8089/weasis-doc" /> --> </resources> <!-- Main class --> <application-desc main-class="org.weasis.launcher.WebstartLauncher"> <!-- Example for opening dicom files from URLs --> <argument>$dicom:get -w %webscriptadress%?%extra%&mode=weasisseriesxml&series=%series2%&dum=.xml </argument> </application-desc> </jnlp>


    Put this code in cgi-bin\viewers\weasisseriesxml.lua


    And go. Note that the first file downloads weasis from the internet - better make that local. Also note that at least the dgate.exe in cgi-bin needs to be updated to 1.4.17beta.


    Edit 1): put in that it asks for its own AE title from the server. Assumptions:
    1) webscriptaddress is set correctly in cgi-bin/dicom.ini
    2) The server's own AE title is in acrnema.map and has the correct IP and PORT.
    3) dicom.ini in cgi-bin refers to a recent dgate.dic and acrnema.map


    Edit 2): put in a Weasis bug workaround that fixes wado over the internet (overrideDicomTagsList="0x00000000") and removed additionalParameters which lead to a warning message.


    Marcel

  • Awesome Marcel!


    It does in fact launch internally! I think there is a firewall issue getting it to work over the intenet...since it's gettin getting the substance.jnlp from some place else.


    You did state rudimentary so I'm assuming the next step is to get the images to appear....amost there!


    Appreciate ya Marcel!


    Robby

  • Hi,


    weasis makes a WADO HTTP connection to conquest, (using webscriptadress in the lua script), that looks like http://127.0.0.1/cgi-bin/dgate.exe. If you have a HTTP connection that works externally to get to conquest, you can just substitute that in cgi-bin/dicom.ini; it must end with dgate.exe (or dgate for linux) though.


    Marcel

  • I see that now. The studies are still not coming up even on an internal request. I have updated webscriptaddress with the DNS name to test anyway.
    Here is my generated URL:


    http://mywebsite.sytes.net/cgi…3194661192814320&size=560


    I also tried changing the internal IP address above to the DNS name and still same result.


    Do any of these settings need to be changed in dicom.ini?


    [webdefaults]
    size = 560
    dsize = 0
    compress = n1
    iconsize = 48
    graphic = gif


    For what it's worth, the thumbnails are coming up on the Conquest web page.

  • It is the xml file which may not contain the port and address bits. You need to try this from a web browser:


    dgate.exe?mode=weasisseriesxml&series=003499:1.2.840.113564.10.1.11874645685364616760173193194661192814320


    Then you can check the quality of the generated xml file going into weasis


    Marcel



  • I did what you asked and got the following:


    ==========================================================
    This page contains the following errors:


    error on line 1 at column 1: Document is empty
    Below is a rendering of the page up to the first error.
    ==========================================================


    Here is the page source:


    *** lua run error viewers\weasisseriesxml.lua:5: attempt to index global 'DicomObject' (a nil value) in 'dofile('viewers\\weasisseriesxml.lua')'



    I was looking thu the .lua script and I did find what I thought was a typo?


    Quote

    additionnalParameters=""


    I fixed the spelling...keeping my fingers crossed...but still no images ......grrrrr


    Thanks,


    Robby

  • http://127.0.0.1/cgi-bin/dgate…eries=patientid:seriesuid


    Gives an XML document in my browser. This will be the input to weasis and it must be correct for weasis to load anything. Mine works:

    Code
    <wado_query wadoURL="http://cf-j10/cgi-bin/dgate.exe" requireOnlySOPInstanceUID="false" additionnalParameters="" overrideDicomTagsList=""><Patient PatientID="20403128" PatientName="xxxx PatientBirthDate=""><Study StudyInstanceUID="1.2.840.113619.2.22.287.42009.8532.20050104.260435" StudyDescription="" StudyDate="20050104" StudyTime="160435"><Series SeriesInstanceUID="1.2.840.113619.2.22.287.42009.8532.2.20050104.260538" SeriesDescription="" SeriesNumber="2" Modality="CT"><Instance SOPInstanceUID="1.2.840.113619.2.22.287.42009.8532.2.1.20050104.260558" InstanceNumber="0"/><Instance SOPInstanceUID="1.2.840.113619.2.22.287.42009.8532.2.2.20050104.260600" InstanceNumber="1"/><Instance SOPInstanceUID="1.2.840.113619.2.22.287.42009.8532.2.3.20050104.260602" InstanceNumber="2"/>


    etc etc


    The line wadoURL="http://cf-j10/cgi-bin/dgate.exe" has to point to conquest without any '?'


    Marcel


    Marcel

  • Hi,


    after adding correct references to dgate.dic and acrnema.map in cgi-bin/dicom.ini, things start to work for robby. Now we see the thumnails in weasis appear and then dissappear. Trying to solve that now. A similar behavior has been reported with older 1.4.16's but it should have been fixed. Does anybody have a clue?


    Marcel

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!