Save As Animated Gif for Hyperstacks?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Save As Animated Gif for Hyperstacks?

Andy Puckett
I'm using ImageJ to analyze a time-series of astronomical images (FITS
files).  I'm using Hyperstacks, because I need to be able to adjust the
Brightness & Contrast settings of each slice separately.  This has worked
fine so far, but now I'd like to be able to Save As Animated Gif.  The
problem is that it seems to be applying the same B&C settings to all images,
so it seems to be treating my Hyperstack as if it were a Stack.

Does SAAG only work correctly on Stacks?  Could it be made to work on
Hyperstacks in a future update?  (Please?)

Thanks,
Andy Puckett

-------------------------------------------------------------
Dr. Andy Puckett [hidden email]
Postdoctoral Fellow 907-786-1838
University of Alaska Anchorage   SCI 221
-------------------------------------------------------------
Reply | Threaded
Open this post in threaded view
|

Re: Save As Animated Gif for Hyperstacks?

Bill Mohler
My impression has always been that the slice-by-slice adjustment of
contrast in non-grayscale hyperstacks is an unintended feature and
not one implemented by design. But you might be able to apply the B|C
settings you want to a duplicate copy of each image from your
hyperstack, on the way to building a new stack with "hard-copied"
adjustments, then save your animated GIF.


At 5:28 AM -0900 3/2/09, Andy Puckett wrote:

>I'm using ImageJ to analyze a time-series of astronomical images (FITS
>files).  I'm using Hyperstacks, because I need to be able to adjust the
>Brightness & Contrast settings of each slice separately.  This has worked
>fine so far, but now I'd like to be able to Save As Animated Gif.  The
>problem is that it seems to be applying the same B&C settings to all images,
>so it seems to be treating my Hyperstack as if it were a Stack.
>
>Does SAAG only work correctly on Stacks?  Could it be made to work on
>Hyperstacks in a future update?  (Please?)
>
>Thanks,
>Andy Puckett
>
>-------------------------------------------------------------
>Dr. Andy Puckett [hidden email]
>Postdoctoral Fellow 907-786-1838
>University of Alaska Anchorage   SCI 221
>-------------------------------------------------------------
Reply | Threaded
Open this post in threaded view
|

Re: Save As Animated Gif for Hyperstacks?

Wayne Rasband
In reply to this post by Andy Puckett
On Mar 2, 2009, at 9:28 AM, Andy Puckett wrote:

> I'm using ImageJ to analyze a time-series of astronomical images (FITS
> files).  I'm using Hyperstacks, because I need to be able to adjust the
> Brightness & Contrast settings of each slice separately.  This has
> worked
> fine so far, but now I'd like to be able to Save As Animated Gif.  The
> problem is that it seems to be applying the same B&C settings to all
> images,
> so it seems to be treating my Hyperstack as if it were a Stack.
>
> Does SAAG only work correctly on Stacks?  Could it be made to work on
> Hyperstacks in a future update?  (Please?)

You can save a multichannel stack as an animated gif in the 1.42k daily
build using this method:

   1. Switch to "Color" or "Grayscale" mode using the Channels tool
   2. Convert to RGB using Image>Type>RGB Color
   3. Convert to 8-bit using Image>Type>8-bit Color or Image>Type>8-bit
   4. Set the frame rate using Image>Stacks>Animation Options
   5. Save as an animated gif using File>Save As>Gif

This also works for saving in AVI and QuickTime formats, where step (3)
can be omitted because it is not necessary to convert to 8-bits.

The number of channels must be equal to the number of images in the
stack, as it is in the 5 channel "Neuron" sample image. You can update
to the daily build using the Help>Update ImageJ command and selecting
"daily build" in the drop down menu.

-wayne
Reply | Threaded
Open this post in threaded view
|

Re: Save As Animated Gif for Hyperstacks?

Andy Puckett
In reply to this post by Andy Puckett
Hi Wayne,

For my 16-bit grayscale images, it seems that EITHER Step 2 OR Step 3  
is necessary to get an Animated Gif with nice contrast.  I doesn't  
look like I have to do both.

Thanks,
Andy

-------------------------------------------------------------
Dr. Andy Puckett [hidden email]
Postdoctoral Fellow 907-786-1838
University of Alaska Anchorage   SCI 221
-------------------------------------------------------------


On Mar 2, 2009, at 8:00 PM, IMAGEJ automatic digest system wrote:

> Date:    Mon, 2 Mar 2009 15:33:38 -0500
> From:    Wayne Rasband <[hidden email]>
> Subject: Re: Save As Animated Gif for Hyperstacks?
>
> On Mar 2, 2009, at 9:28 AM, Andy Puckett wrote:
>
>> I'm using ImageJ to analyze a time-series of astronomical images  
>> (FITS
>> files).  I'm using Hyperstacks, because I need to be able to adjust  
>> the
>> Brightness & Contrast settings of each slice separately.  This has
>> worked
>> fine so far, but now I'd like to be able to Save As Animated Gif.  
>> The
>> problem is that it seems to be applying the same B&C settings to all
>> images,
>> so it seems to be treating my Hyperstack as if it were a Stack.
>>
>> Does SAAG only work correctly on Stacks?  Could it be made to work on
>> Hyperstacks in a future update?  (Please?)
>
> You can save a multichannel stack as an animated gif in the 1.42k  
> daily
> build using this method:
>
>   1. Switch to "Color" or "Grayscale" mode using the Channels tool
>   2. Convert to RGB using Image>Type>RGB Color
>   3. Convert to 8-bit using Image>Type>8-bit Color or Image>Type>8-bit
>   4. Set the frame rate using Image>Stacks>Animation Options
>   5. Save as an animated gif using File>Save As>Gif
>
> This also works for saving in AVI and QuickTime formats, where step  
> (3)
> can be omitted because it is not necessary to convert to 8-bits.
>
> The number of channels must be equal to the number of images in the
> stack, as it is in the 5 channel "Neuron" sample image. You can update
> to the daily build using the Help>Update ImageJ command and selecting
> "daily build" in the drop down menu.
>
> -wayne