Images of asteroids and comets are interesting but are even more so when you can see the object moving against the background stars. In this tutorial, you’ll learn:

  • How to create an animated GIF using AstroImageJ
  • How to crop your animated GIF
  • How to add the Slooh.com logo to your animated GIF

You’ll need both AstroImageJ and GIMP installed on your system to follow these steps.

Result

This is an animation of asteroid 6478 Gault taken January 30, 2019:

The tail on this asteroid is being formed because the asteroid is breaking apart. Astronomers think it is rotating at a speed high enough to cause it to break up and the tail you see is the broken-up material. Just before this asteroid disappeared from our view, it developed a second tail and the Hubble Space telescope caught an image of that.

I created this animation using AstroImageJ and GIMP and followed the steps in this tutorial.

Creating an animated GIF using AstroImageJ

Start with FITS files of your object and ensure you have them all in one folder to make them easier to import using AstroImageJ.

1. Start AstroImageJ

2. Select File – Import – Image Sequence

3. Browse to the folder containing your FITS files

4. Select one of the files in the sequence

5. Verify that the number of files is correct in the Sequence Options dialog box and click Ok

6. AstroImageJ imports your sequence of images in chronological order and opens the stack

7. Drag the scroll bar at the bottom of the image to check the alignment of the images (your images should ideally not shift as you drag the scroll bar; I explain how to align your images in the next series of steps)

8. Align your images as follows:

a. Click the 13th icon from the left (the tooltip says ‘align stack using apertures’)

b. Uncheck all options except ‘Align only to whole pixels’ and ‘Show help panel during aperture selection

c. Select three stars that are visible on all of the images and are relatively clear of your moving object and are mostly alone (not surrounded by other nearby stars)

d. Press Enter on your keyboard once you have selected at least three stars

e. AstroImageJ will align your images using the three stars as reference stars

f. Drag the slider located at the bottom of your images to verify that your images are aligned

9. Use your mouse wheel to zoom in and use your mouse to position the image such that your moving object is centered in the image and it is visible

10. If you need to adjust the Scale (brightness) of your image, select Scale – fixed brightness and contrast, and use the scale controls at the bottom to adjust your image

11. Crop your image to the region of interest as follows:

a. From the AstroImageJ window (the smaller one) select the Rectangle at the left side of the toolbar

b. Draw a rectangle around the areas you want to keep

c. Move and adjust the rectangle as required

d. From the AstroImageJ window (the smaller one) select Image – Crop

12. Save your animated GIF by selecting from the AstroImageJ window (the smaller one) select File – Save As – Animated GIF

You now have your animated GIF and can now add a logo using GIMP.

Adding A Logo Using GIMP

The process of adding a logo to the animated GIF using GIMP needs a number of steps because you have to duplicate and place the logo on each frame of your animation. When you import the animated GIF into GIMP, it gets imported such that each frame of the animation is a layer of your image in GIMP. The directions here have you place the logo over each layer and then merge it with each layer of your image.

I assume you have the Slooh logos downloaded and available to you on your system. If you don’t already have the logos, sign in to Slooh and download the logos from here:

https://polaris.slooh.com/files/Discussion_Board_Content/Slooh_Space_for_Everyone_Logos.zip

1. Start GIMP

2. Open your animated GIF that you created in the preceding section

3. Open one of the logo images

4. Paste the logo so that it appears before the first frame of your animated GIF as follows:

a. From the menu, select Select – All

b. From the menu, select Edit – Copy

c. Switch back to the animated GIF image

d. Select Edit – Paste as – New Layer

5. Move the logo to where you want it to appear on your image (activate the Move tool to move it)

6. Copy and paste this layer to each frame of the animation. Your layers panel should look like this when you are finished (detailed steps follow):

a. Ensure the layer having the Slooh logo is the active one

b. From the menu, select Select – All

c. From the menu select Edit – Copy

d. Select the next layer in your image

e. From the menu select Edit – Paste As – New Layer

f. Repeat from step D for each layer in your image – your layers panel should look something like the preceding screenshot.

7. Save your work so far using File – Save

8. Merge each of the pasted layers as follows:

a. Select one of the layers having the Slooh logo on it

b. From the menu, select Layer – Merge Down

c. Verify that the layer was merged properly (you should see the logo on your image in the small preview window. If it doesn’t work, close GIMP, restart it, re-open the image you saved in step 10 and try again. I noticed that this helped when I was testing this.). This is how your layers panel should look:

d. Repeat from step A until you merge all of the layers.

9. Export the final GIF by selecting File – Export As

10. Enter a file name ending in .GIF

11. A new window pops-up, select ‘As Animation’ and ‘Loop Forever’, and click Export

If you like, you can resize your final GIF – select Image – Scale Image, and enter the final size you wish to use.

Conclusion

In this tutorial, you learned how to create an aligned, animated GIF using AstroImageJ and you learned how to add a logo to your animation using GIMP.