Hi all,
I am pretty much new to the mailing list but I have been using ImageJ in my application for about an year. Recently we are required to offer a new feature for our Medical Images - Window & Leveling concept. After going through couple of articles I managed to understand clearly what it means. But I also knew that, ImageJ does have W&L added in the Menu Bar and I did play around with that for a while. But our requirements are like this. We have specific users who wants to have these Window&Level values preset for them. For example: Lungs = value1 Brain = value2 Bones = value3 etc., So i was thinking to have a drop-down list and have lungs, brain, bones etc., listed in them. So when the user chooses one of them, it will change the intensity of the Image to their needs. So, can anybody help me find what API function should I exaclty use for setting the values. I could not find any such function in the documentation. But I am pretty much convinced that there is one, because W&L of the ImageJ has an "Apply" button in it, which exactly does what I need. Any ideas ? Thanks Prasad |
Hi,
Is this a windoze bug? I'm running XP pro and have a pile of tif's to convert to a multiframe tif stack. If I File/Open a group of sequence-named files all together (using shift and control keys to select them) and then do either Image/Stacks/ConvertImagesToStack OR Plugins/Stacks/StacksBuilding/StackBuilder (this is WCIF package) the resulting stack is perfect. However, if I drag the files to ImageJ from a WindozeExplorer screen, a bunch of slices that belong in the beginning of the stack are tacked onto the end. While we're on the subject, is there a plugin to directly read in sequence-names files as a stack? Thanks everyone - Ted Ballou |
In reply to this post by Prasad Rajagopal
Use the setMinAndMax(min, max) function to set the display window and
level, where min and max are calculated from the window width and level using min = level - width/2; max = level + width/2; Use a macro set such as the one at http://rsb.info.nih.gov/ij/macros/WindowAndLevel.txt to create menu commands for setting preset values for lungs, bones, etc. This macro set creates keyboard shortcuts that allow you to switch to the lung preset values by pressing 1 and to the bone values by pressing 2. It also includes macros for changing the preset values using a dialog box and to change them to values defined interactively using the W&L or B&C tools. Add the macros in this set to StartupMacros.txt to have them installed automatically when ImageJ starts up. Information about the ImageJ macro language can be found at http://rsb.info.nih.gov/ij/developer/macro/macros.html -wayne On Jun 13, 2006, at 2:40 PM, Prasad Rajagopal wrote: > Hi all, > > I am pretty much new to the mailing list but I have been using > ImageJ in my application for about an year. Recently we are required to > offer a new feature for our Medical Images - Window & Leveling concept. > > After going through couple of articles I managed to understand > clearly what it means. But I also knew that, ImageJ does have W&L > added in > the Menu Bar and I did play around with that for a while. > > But our requirements are like this. We have specific users who > wants to have these Window&Level values preset for them. > > For example: > > Lungs = value1 > Brain = value2 > Bones = value3 > etc., > > So i was thinking to have a drop-down list and have lungs, > brain, bones etc., listed in them. So when the user chooses one > of them, it will change the intensity of the Image to their needs. > > So, can anybody help me find what API function should I > exaclty use for setting the values. I could not find any such function > in the documentation. > > But I am pretty much convinced that there is one, because > W&L of > the ImageJ has an "Apply" button in it, which exactly does what I need. > > Any ideas ? > > Thanks > Prasad > |
In reply to this post by Ted Ballou
I use a macro, convert_tiffs_to_stack. If you place all your tiffs
in a folder, this macro will read them sequentially and create/save the resulting stack in the directory of your choice. On Jun 14, 2006, at 2:29 PM, Ted Ballou wrote: > Hi, > > Is this a windoze bug? I'm running XP pro and have a pile of tif's > to convert to a multiframe tif stack. If I File/Open a group of > sequence-named files all together (using shift and control keys to > select them) and then do either Image/Stacks/ConvertImagesToStack > OR Plugins/Stacks/StacksBuilding/StackBuilder (this is WCIF > package) the resulting stack is perfect. However, if I drag the > files to ImageJ from a WindozeExplorer screen, a bunch of slices > that belong in the beginning of the stack are tacked onto the end. > > While we're on the subject, is there a plugin to directly read in > sequence-names files as a stack? > > Thanks everyone - > > Ted Ballou |
In reply to this post by Prasad Rajagopal
Hi,
Thanks for the reply. It was very helpful. It worked. But there is a slight problem. I wrote a macro named it as StartupMacros.txt and put that file in the "macros" directory. And when I restarted ImageJ it automatically installed. But since I am using ImageJ as an applet, when i embed the "ij.jar" for the ImageJ it does not inlcude the StartupMacros.txt functionalities. When I load webpage, ImageJ starts and opens the Image. But when I pressed "1", "2", etc., nothing happened because the Macro was not there. Do you know how to make it work when calling ImageJ as Applet ? Thanks Prasad |
> Thanks for the reply. It was very helpful. It worked.
> But there is a slight problem. I wrote a macro named it > as StartupMacros.txt and put that file in the "macros" > directory. And when I restarted ImageJ it automatically > installed. > > But since I am using ImageJ as an applet, when i embed > the "ij.jar" for the ImageJ it does not inlcude the > StartupMacros.txt functionalities. When I load webpage, > ImageJ starts and opens the Image. But when I pressed > "1", "2", etc., nothing happened because the Macro was > not there. > > Do you know how to make it work when calling ImageJ as > Applet ? ImageJ 1.37i installs the macros in StartupMacros.txt when it is running as an applet. The applet at <http://rsb.info.nih.gov/ij/applet/>, for example, installs the macros at <http://rsb.info.nih.gov/ij/applet/StartupMacros.txt>. -wayne |
Free forum by Nabble | Edit this page |