<div dir="auto"><div>Leonard,<br><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
Date: Mon, 1 Jan 2018 17:30:56 -0800<br>
From: Leonard Daly <<a href="mailto:Leonard.Daly@realism.com">Leonard.Daly@realism.com</a>><br>
To: <a href="mailto:x3d-public@web3d.org">x3d-public@web3d.org</a><br>
Subject: Re: [x3d-public] ImageTexture3D support in x3dom<br>
Message-ID: <<a href="mailto:a526830c-7de2-361f-680c-9fa52678553e@realism.com">a526830c-7de2-361f-680c-<wbr>9fa52678553e@realism.com</a>><br>
Content-Type: text/plain; charset="utf-8"; Format="flowed"<br>
<br>
Andreas,<br>
<br>
This touches on an active research area. I found two papers directly<br>
related to the question:<br>
<a href="https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3043920/" rel="noreferrer" target="_blank">https://www.ncbi.nlm.nih.gov/<wbr>pmc/articles/PMC3043920/</a><br>
<a href="https://www.ncbi.nlm.nih.gov/pubmed/1449870" rel="noreferrer" target="_blank">https://www.ncbi.nlm.nih.gov/<wbr>pubmed/1449870</a> (abstract only)<br>
<br>
Both are 10+ years old, so there may be more recent work someplace else.<br></blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">I got the 800 shades of grey from the first link originally. Medical display manufacturer s have more recent white papers but they focus on color which seems essentially an unsolved standardization challenge for the rigorous medical field.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
This biggest constraint will be the display end of the system. Most<br>
graphics cards are strictly 8bpp for b/w. Most monitors are not<br>
calibrated or stable enough to do higher level resolution than that. It<br>
is possible to get higher (and better, more expensive) equipment, but<br>
that is only done in specialized environments (like medical imaging).<br></blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">After looking I found to my surprise that this changed recently (2017) as hdr displays with 10bit per channel color are now consumer products and 10bit output is generated by professional gpus (and perhaps high end gaming cards).</div><div dir="auto">OpenGL supports 10bit channels and webGL2 now as well.</div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Requiring standard X3D browsers to handle high-level images would cause<br>
an production and/or adoption problem. Allowing them to handle the<br>
higher end images would be reasonable.<br></blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">This touches on HDR as well as medical imaging.</div><div dir="auto"><br></div><div dir="auto">x3dom is webgl1 . The 1992 abstract claims that compression to 8bit did not lead gaps in diagnoses, so that would be the easy path for now to deal with higher fidelity input.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
Leonard Daly<br>
<br>
<br>
<br>
> Hi Don,<br>
><br>
> thanks for checking in on the supported nodes list. X3dom recognized<br>
> ImageTexture3D but it was just a stub without functionality.<br>
><br>
> For the rendering all props and recognition need to go to Vicomtech, I<br>
> only added loading of nrrd files.<br>
><br>
> I noticed that medical image data often have more than 256 levels of<br>
> intensity, usually 4096. The human eye apparently can distinguish<br>
> around 800 levels.<br>
><br>
> Since most display systems can only show 256 levels of grey,<br>
> interactive windowing of the data range seems be common concept for<br>
> exploration.<br>
><br>
> As a graphics standard, should X3D be concerned with how to visualize<br>
> 12bit grey images/textures ?<br>
><br>
> For nrrd I currently support 8bit grey and (soon) 24bit rgb 3d images.<br>
> The practical question is what to do if there is 16bit grey data, a<br>
> common situation.<br>
><br>
> One could automatically rescale to 8bit, assuming 12bit range, with a<br>
> warning.<br>
><br>
> One could treat as grey plus alpha but this is generally not what is<br>
> expected.<br>
><br>
> One could treat as u v and expect a 2d transfer map. A default<br>
> transfer function could accomplish grey rescaling but custom maps<br>
> could use color to represent the full dynamic range. But 2d transfer<br>
> maps may currently not be supported in x3dom.<br>
><br>
> Hm, so another option would to treat as uint16 and expect 1d transfer<br>
> function. A 256 pixel long grey ramp would rescale to 8bit but it<br>
> would be possible to use 4096 colors, cool to hot for example.<br>
><br>
> It may be time to check what other x3d browsers do.<br>
><br>
> Happy holidays, Andreas<br>
><br>
><br>
><br>
><br>
><br>
><br>
><br>
> On Dec 23, 2017 3:49 PM, "Don Brutzman" <<a href="mailto:brutzman@nps.edu">brutzman@nps.edu</a><br>
> <mailto:<a href="mailto:brutzman@nps.edu">brutzman@nps.edu</a>>> wrote:<br>
><br>
>     Looks like we already had this node included for X3DOM in the<br>
>     inventory spreadsheet.? Further improvements welcome.? Just<br>
>     updated (clearing an Xj3D bug) and online at<br>
><br>
>     <a href="http://www.web3d.org/specifications/X3dNodeInventoryComparison.pdf" rel="noreferrer" target="_blank">http://www.web3d.org/<wbr>specifications/<wbr>X3dNodeInventoryComparison.pdf</a><br>
>     <<a href="http://www.web3d.org/specifications/X3dNodeInventoryComparison.pdf" rel="noreferrer" target="_blank">http://www.web3d.org/<wbr>specifications/<wbr>X3dNodeInventoryComparison.pdf</a><wbr>><br>
>     <a href="http://www.web3d.org/specifications/X3dNodeInventoryComparison.xlsx" rel="noreferrer" target="_blank">http://www.web3d.org/<wbr>specifications/<wbr>X3dNodeInventoryComparison.<wbr>xlsx</a><br>
>     <<a href="http://www.web3d.org/specifications/X3dNodeInventoryComparison.xlsx" rel="noreferrer" target="_blank">http://www.web3d.org/<wbr>specifications/<wbr>X3dNodeInventoryComparison.<wbr>xlsx</a>><br>
><br>
>     The example looks tremendous and certainly conveys why we should<br>
>     keep pressing ahead to make X3D sufficiently capable for archiving<br>
>     diagnostic visualizations in medical records.<br>
><br>
>     Snapshot attached.? Intentionally large in order to show<br>
>     tremendous detail that is possible.? Curiously the skull<br>
>     information is so rich when examining that it was difficult to<br>
>     find a single view that conveyed as much information.<br>
><br>
>     Thanks for the great work!<br>
><br>
><br>
>     On 12/19/2017 3:26 AM, Andreas Plesch wrote:<br>
><br>
>         One of the many excellent features of x3dom is its extensive<br>
>         volume rendering support, provided by vicomtech. For loading<br>
>         efficiency it uses a special volume texture format, a 2d<br>
>         texture atlas of slices in regular image formats.<br>
><br>
>         Using tools like image magick it is not too hard to convert an<br>
>         actual raw data volume to such a texture atlas image but I<br>
>         always thought it would be neat to avoid having to do that. I<br>
>         saw now a way to use existing pieces to start implement the<br>
>         standard ImageTexture3D node which can load nrrd, dicom and<br>
>         other (?) formats.<br>
><br>
>         Focusing on nrrd, here is a first implementation of the<br>
>         ImageTexture3D node:<br>
><br>
>         <a href="https://x3dom-nrrd.glitch.me/index.xhtml" rel="noreferrer" target="_blank">https://x3dom-nrrd.glitch.me/<wbr>index.xhtml</a><br>
>         <<a href="https://x3dom-nrrd.glitch.me/index.xhtml" rel="noreferrer" target="_blank">https://x3dom-nrrd.glitch.me/<wbr>index.xhtml</a>> (for Halloween next<br>
>         year ...)<br>
><br>
>         I tested with a few nrrd examples and overall it seems to work<br>
>         although I am sure there a few problems left. But the support<br>
>         is good enough that the node may be listed in a table of<br>
>         supported nodes for x3dom, I suspect.<br>
><br>
>         a peaceful holiday season, Andreas<br>
><br>
>         --<br>
>         Andreas Plesch<br>
>         Waltham, MA 02453<br>
><br>
><br>
>     all the best, Don<br>
>     --<br>
>     Don Brutzman? Naval Postgraduate School, Code USW/Br<br>
>     <a href="mailto:brutzman@nps.edu">brutzman@nps.edu</a> <mailto:<a href="mailto:brutzman@nps.edu">brutzman@nps.edu</a>><br>
>     Watkins 270,? MOVES Institute, Monterey CA 93943-5000 USA<br>
>     <a href="tel:%2B1.831.656.2149" value="+18316562149">+1.831.656.2149</a> <tel:%2B1.831.656.2149><br>
>     X3D graphics, virtual worlds, navy robotics<br>
>     <a href="http://faculty.nps.edu/brutzman" rel="noreferrer" target="_blank">http://faculty.nps.edu/<wbr>brutzman</a> <<a href="http://faculty.nps.edu/brutzman" rel="noreferrer" target="_blank">http://faculty.nps.edu/<wbr>brutzman</a>><br>
><br>
><br>
><br>
> ______________________________<wbr>_________________<br>
> x3d-public mailing list<br>
> <a href="mailto:x3d-public@web3d.org">x3d-public@web3d.org</a><br>
> <a href="http://web3d.org/mailman/listinfo/x3d-public_web3d.org" rel="noreferrer" target="_blank">http://web3d.org/mailman/<wbr>listinfo/x3d-public_web3d.org</a><br>
<br>
<br>
--<br>
*Leonard Daly*<br>
3D Systems & Cloud Consultant<br>
LA ACM SIGGRAPH Past Chair<br>
President, Daly Realism - /Creating the Future/<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <<a href="http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20180101/06c50ec3/attachment-0001.html" rel="noreferrer" target="_blank">http://web3d.org/pipermail/<wbr>x3d-public_web3d.org/<wbr>attachments/20180101/06c50ec3/<wbr>attachment-0001.html</a>><br>
<br>
------------------------------<br>
<br>
Message: 3<br>
Date: Mon, 1 Jan 2018 20:32:41 -0500<br>
From: Andreas Plesch <<a href="mailto:andreasplesch@gmail.com">andreasplesch@gmail.com</a>><br>
To: X3D Graphics public mailing list <<a href="mailto:x3d-public@web3d.org">x3d-public@web3d.org</a>><br>
Subject: Re: [x3d-public] problem in nrrd example file header<br>
Message-ID:<br>
        <<a href="mailto:CAKdk67vw1KaaE0WeivUwQ8RCO-nhDAz-V_WqaxJLtHndwMz-gA@mail.gmail.com">CAKdk67vw1KaaE0WeivUwQ8RCO-<wbr>nhDAz-V_WqaxJLtHndwMz-gA@mail.<wbr>gmail.com</a>><br>
Content-Type: text/plain; charset="UTF-8"<br>
<br>
It turns out that<br>
<br>
<a href="http://savage.nps.edu/Savage/VolumeRendering/datasets/nrrd/mri_ventricles_segment.nrrd" rel="noreferrer" target="_blank">http://savage.nps.edu/Savage/<wbr>VolumeRendering/datasets/nrrd/<wbr>mri_ventricles_segment.nrrd</a><br>
<br>
has the same problem of a malformed header line, eg. an excess space<br>
character in the spacings line.<br>
<br>
Here is a corrected nrrd file:<br>
<br>
<a href="https://cdn.glitch.com/405924cd-3c0d-476e-9b88-520a5610604c%2Fmri_ventricles_segment_fixed.nrrd?1514854259949" rel="noreferrer" target="_blank">https://cdn.glitch.com/<wbr>405924cd-3c0d-476e-9b88-<wbr>520a5610604c%2Fmri_ventricles_<wbr>segment_fixed.nrrd?<wbr>1514854259949</a><br>
<br>
-Andreas<br>
<br>
On Mon, Dec 18, 2017 at 4:18 PM, Andreas Plesch <<a href="mailto:andreasplesch@gmail.com">andreasplesch@gmail.com</a>> wrote:<br>
> I am working on ImageTexture3D support for x3dom using the existing<br>
> ImageTextureAtlas node and <a href="https://github.com/scijs/nrrd-js" rel="noreferrer" target="_blank">https://github.com/scijs/nrrd-<wbr>js</a> as a<br>
> parser.<br>
><br>
> It turns out the the parser is very strict, and so discovered a<br>
> malformed header line in<br>
> <a href="https://savage.nps.edu/Savage/VolumeRendering/datasets/nrrd/mri_ventricles.nrrd" rel="noreferrer" target="_blank">https://savage.nps.edu/Savage/<wbr>VolumeRendering/datasets/nrrd/<wbr>mri_ventricles.nrrd</a><br>
> used in <a href="http://www.web3d.org/x3d/content/examples/Basic/VolumeRendering/BasicVentriclesIndex.html" rel="noreferrer" target="_blank">http://www.web3d.org/x3d/<wbr>content/examples/Basic/<wbr>VolumeRendering/<wbr>BasicVentriclesIndex.html</a><br>
><br>
> Specifically, the header line<br>
> 'spacings:  NaN 0.009 0.009 0.009'<br>
><br>
> has _two_ space character after the colon delimiter. Exactly _one_<br>
> space is allowed, however, as described here:<br>
><br>
> <a href="http://teem.sourceforge.net/nrrd/format.html#general.2" rel="noreferrer" target="_blank">http://teem.sourceforge.net/<wbr>nrrd/format.html#general.2</a><br>
> second paragraph:<br>
> ... a string "<field>" identifying the field (called the field<br>
> identifier), then a colon followed by a single space ": ", and then<br>
> the information describing the field "<desc>" (called the field<br>
> descriptor) ...<br>
><br>
> The second space then acts as a separator making the first value in<br>
> the array an empty string which causes throwing when attempting to<br>
> parse as a float.<br>
><br>
> I made an attempt at fixing the header by removing one space and made<br>
> the file available here:<br>
><br>
> <a href="https://cdn.glitch.com/af228b45-6772-432d-a549-74f9f447b2c3%2Fmri_ventricles2.nrrd?1513631507711" rel="noreferrer" target="_blank">https://cdn.glitch.com/<wbr>af228b45-6772-432d-a549-<wbr>74f9f447b2c3%2Fmri_<wbr>ventricles2.nrrd?1513631507711</a><br>
><br>
> -Andreas<br>
><br>
> --<br>
> Andreas Plesch<br>
> Waltham, MA 02453<br>
<br>
<br>
<br>
--<br>
Andreas Plesch<br>
Waltham, MA 02453<br>
<br>
<br>
<br>
------------------------------<br>
<br>
Subject: Digest Footer<br>
<br>
______________________________<wbr>_________________<br>
x3d-public mailing list<br>
<a href="mailto:x3d-public@web3d.org">x3d-public@web3d.org</a><br>
<a href="http://web3d.org/mailman/listinfo/x3d-public_web3d.org" rel="noreferrer" target="_blank">http://web3d.org/mailman/<wbr>listinfo/x3d-public_web3d.org</a><br>
<br>
<br>
------------------------------<br>
<br>
End of x3d-public Digest, Vol 106, Issue 1<br>
******************************<wbr>************<br>
</blockquote></div><br></div></div></div>