Atari 8-bit |
Viewers |
a8jdpeg 0.8
(14Sep02)
The original Atari 8-bit interface. |
|
JpegView 0.9 (17Oct03)
A friendlier menu oriented version of a8jdpeg |
|
JpegShow 0.1 (07Aug01)
A slideshow version |
|
Colour JPEG Viewer The colour version of the JPEG Viewer
|
|
|
The executables are in Atari DOS binary format (the .bin extension is to make sure the file gets downloaded as a binary), you should be able to save it on a disk and run it straight from your Atari 8-bit (or emulator).
NOTE: The display modes marked as 64K really really do need 64K! This includes using the RAM under the OS. Most versions of SpartaDOS also use this area and your machine WILL crash if you use a 64K display mode with one of these SpartaDOS versions. The 48K modes should work though. If you do want to use a 64K display mode with a SpartaDOS disk, then either give BEWEDOS a try, or take a look at PgmView.
a8jdpeg and JpegView can both convert JPEGs to the Atari 8-bit Micropainter and HIP formats. If these don't suit you, or if you want access to the uncompressed image data for whatever reason, then they can also convert to PGM (Portable Greymap) format. This format can easily be read on the Atari 8-bit (and many other machines) and converted to whatever format suits you. An example BASIC program for reading the PGMs produced by a8jdpeg is available.
Version 0.8 (14Sep02) replaces the release dated 07Aug01, and includes
the following changes:
Have you found a bug? Do you have an idea for further improvements?
If so, send
me an e-mail.
This version should work fine on most baseline JPEGs out there.
It will not work on progressive JPEGs. Progressive JPEGs are designed
for viewing over a slow connection. When viewing a progressive JPEG
over a slow connection, it starts out as a low quality fuzzy image which
becomes clearer as more data is downloaded. The way progressive JPEGs
are implemented makes then harder (although not impossible) to handle in
48/64K of RAM.
Progressive JPEGs can be converted to baseline JPEGs using the
jpegtran program provided by the IJG (The Independent JPEG Group):
Then try displaying the new image. This may also fix other problems
with images too. The jpegtran program is available for many systems,
although not (unfortunately) for the Atari 8-bit. If you do not
already have this program you can download it from ftp://ftp.uu.net/graphics/jpeg
Once loaded, JpegView will display all files with a .JPG extender on
drive 1. To load a file, press the letter displayed next to the file name.
To view the files on a different drive, or redisplay the files on the current
drive, press the appropriate drive number (1 for D1:, 2 for D2:, etc.).
Pressing the Tab key will allow you to change the files listed.
Change the mask to *.* to view all files and subdirectories on the current
drive.
JpegShow will start displaying all files with a .JPG extender on drive
1, pausing between each one. To change any of the parameters used press
the Esc key. To make these
options permanent use the save option, this will create a D:JPEGSHOW.CFG
file on the disk in drive 1.
a8jdpeg will first prompt you for a file name. The device or drive number displayed
can be changed by backspacing and replacing them with the new ones. Pressing
the Tab key will display the previous file name used. If no extension
is added to the file name ".JPG" will be added automatically. To stop this
from happening, add a dot at the end of the file name:
a8jdpeg Changes
JpegView Changes
Version 0.9 of JpegView replaces the release dated 07Aug01, this
includes all the improvements made in a8jdpeg 0.8 (as listed above) as
well as the following:
Bugs
jpegtran input.jpg > output.jpg
Screenshot Gallery
Want to see some screenshots? Take a look at the Gallery
Usage
First boot up into your favourite DOS, without BASIC (hold down the
OPTION
key when booting XL/XE models, remove all cartridges on 400/800 models)
then load a8jdpeg, JpegView or JpegShow (use the L option under DOS 2.0/2.5/MyDOS
or equivalent).
JpegView
JpegShow
a8jdpeg
D:ATARI.JPG | load a file called ATARI.JPG from D: |
D:ATARI | load a file called ATARI.JPG from D:, .JPG is added automatically |
D:ATARI. | load a file called ATARI from D:, .JPG is not added automatically |
Files can also be loaded from the directory list by pressing the corresponding letter on the keyboard after displaying the directory. To display a directory type in a directory mask using the '*' and '?' wildcards and place an extra ':' at the end. The above rules for file names also apply:
D:*.*: | display contents of D: |
D:*.JPG: | display all files with a .JPG extension on D: |
D2:*: | display all files with a .JPG extension on D2:, .JPG is added automatically |
D2:: | display all files with a .JPG extension on D2:, *.JPG is added automatically |
D2:PIC??: | display all files that start with "PIC" followed by 2 characters and have a .JPG extension on D2:, this will match PIC01.JPG, PICEL.JPG, PIC75.JPG, etc. |
D2:PICS:: | display all files with a .JPG extension in the PICS directory on D2:, this assumes your DOS supports subdirectories |
D8:PICS:PIC??: | display all files that start with "PIC" followed by 2 characters and have a .JPG extension in the PICS subdirectory on D8:, this will match PIC01.JPG, PICEL.JPG, PIC75.JPG, etc. This assumes your DOS supports subdirectories |
To return to DOS press the RETURN key, leaving the file name empty. The file name can be up to about 60 characters long (if your DOS supports this). An error here probably means you mistyped the file name. If successful the image size will be displayed and you will be asked for the row and column offsets, these default to'C' meaning centre the image, and you can just press RETURN. Since JPEG images can be (much) bigger than 320x200, you can specify here at what row and column you want a8jdpeg to start displaying the image. Each unit for the row and column values equates to 8 pixels, so giving values of 4 for the row and 6 for the column would display pixel 48(6*8), 32(4*8) at the top left hand corner of the screen. Then you will be asked for the graphics mode you want to view the image in, select one of the options from the menu. If this mode supports dithering you will also be asked if you want the image dithered or not. Dithering will provide better image quality but will slow things down a little.
The screen will then start to flash as the image is decoded and displayed.
While the image is being decoded you can press the S key to toggle
the screen, speeding up image decoding. Pressing the Esc key while
the screen is flashing will abort everything and take you back to the file
name prompt, pressing the C key will abort and allow you to change
the display parameters for the image. Once the image has been decoded the
screen will stop flashing, and you should be looking at your JPEG. Pressing
the X key will take you back to DOS, pressing the ESC
key will take you back to the a8jdpeg menu. Pressing the Space bar
will display the image information/help screen. The + and - keys
will allow you to cycle through different colour values. The S
key will save the displayed image in modes that support this (2, 3, D and
E).
64K and greater XL/XE machines have another 4 modes available:
All modes (except the GR.9 flicker and HIP modes in a8jdpeg) also support
dithering. Since JPEG images can contain up to 255 different levels
of grey, these will have to be reduced to the number of levels
supported by the mode selected. Without dithering this extra
information will be discarded. Dithering finds the closest available
grey to the one used in the image and displays that. The difference
between the requested grey and the one actually used is then
calculated, this "error" is then distributed over 4 surrounding
pixels, and modifies their values. This can provide better quality
images at the expense of speed.
JpegView and a8jdpeg can convert the images to Micropainter (62
sector), HIP and PGM formats. This is the same PGM (Portable Greymap) raw format
as found in the Unix world and beyond. This is the best format
to use if you want to extract the image information for your own use.
Take a look at the PGM page for more details,
a PGM viewer and sample code.
This version should work with any 48K or more 8-bit Atari computer.
To get the Graphics 9 and HIP modes you do need a GTIA chip though. Since it doesn't
use any memory below $2000 (except for pages 4 to 6 and the top half of
page 0) it should also work with most DOSes. The 64K modes also use the
RAM hidden under the OS, so will crash any DOSes that use that area (i.e.
most versions of SpartaDOS). If you do have any trouble with it on your
system, then let me know along
with details of your set up.
The source code is in ca65 format, part of
the cc65 cross compiler package. It
should be possible to modify this to work on native Atari assemblers too
(MAC/65, AMAC, etc.).
Any problems, suggestions, comments, bugs, feedback? Let
me know
Thanks to:
Enjoy!Technical details
On a 48K machine, there are 3 display modes available:
Plus 3 options in a8jdpeg for reducing the image horizontaly (JpegView will automatically reduce images).
Plus another 4 options in a8jdpeg for reducing the image horizontaly
(JpegView will automatically reduce images).
Source code
The source code comes in two parts, the decoder and the viewers. The decoder
is a port of Stephen L. Judd's jpy1223-8 file, and is greyscale only. The
viewers have been written from scratch for the Atari. New viewers
can be written by replacing the viewer code with you own. No modification
of the decoder is needed. Details of how to do this are in the decoder
and the viewers source code.
History
a8jdpeg
JpegView
JpegShow
In the pipeline
Here is the current development plan:
Stephen L. Judd - for writing the original C=64 version
and making the source available
Also thanks to:
René de Bie, Mathy van Nisselroy, TJ Edmister,
Marco Antonio Checa Funcke, James Bradford, Chris Martin, Andreas Magenheimer,
Piotr Fusik, Daniel Miller, Andrew Floyd - for comments, suggestions, ideas, feedback
and other help.
back to Atari page