home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 1: Amiga
/
FrozenFish-Apr94.iso
/
bbs
/
alib
/
d5xx
/
d590
/
mice.lha
/
MICE
/
Mice_Doc.Eng
< prev
next >
Wrap
Text File
|
1992-01-05
|
11KB
|
421 lines
****************************************
|| ||
|| MICE ||
|| by Pierre-Louis MANGEARD ||
|| © 1991, EquiLog S.P. ||
|| V1.2 ||
|| ||
****************************************
MICE means : My Image Code Editor. MICE generates source code from
standard IFF pictures, just as brushes from Deluxe Paint.
MICE works with the req.library so take care that it features in your libs:
directory.
Launch MICE from the CLI or from it's WorkBench icon.
MICE generates a structured source code for DEVPAC 2 in assembly and
LATTICE/SAS in C language. For others, make the modifications yourself.
INSTRUCTIONS FOR USE :
--------------------
To understand MICE functions well please follow the instructions step by
step.
Before all manipulations, you must run your favourite editor, but only if
it has a file requester.
To proceed with this tests, you will find with this doc a directory named
'Brushes' that contains three IFF brushes names 'Brol', 'Gazm', and
'Rototo'.
For each test, launch MICE from its icon or from shell and open the
'Brushes' directory in the file requester.
I.- Simple-selecting :
----------------
1 ->
Double-click on file 'Rototo'. The filerequester disappears. A window
opens : it contains a few boolean gadgets and a string gadget named
'SOURCE CODE FILENAME'.
- 4 gadgets are pre-selected ('ASSEMBLY', 'IMAGE STRUCT', 'IMAGE DATA' and
'COMMENTS')
- one gadget is ghosted ('MULTIFILES')
- the string gadget contains the mention 'RAM:Mice.Code'
2 ->
Now click on the 'DO & QUIT' gadget. The window closes.
3 ->
From your editor, load from RAM: the file that has been newly created,
named 'Mice.Code'.
This file contains the Image structure and the image datas of the brush
'Rototo', coded in assembly, with comments. This code is immediatly
available for GenIm2.
Note that the code retrieves the filename of the brush, and the labels
'ImageRototo' and 'ImageDataRototo' are generated.
So, for the maximum efficiency of MICE, you must follow some rules when you
name your brushes. Please see the chapter 'LABELS AND FILENAMES'.
II.- Option 'COMMENTS' :
-----------------
In the previous test, the 'COMMENTS' option was selected by default. Now
let's see what that means exactly.
1 ->
Double-click on file 'Rototo'.
2 ->
Click on the 'COMMENTS' gadget. It is now deselected.
3 ->
In the string gadget, rename the output file, for example 'RAM:Mice1.code'.
4 ->
Click on the 'DO & QUIT' gadget.
5 ->
Load this new file in a new window of your editor, so that you can compare
it with the previous code.
This file contains the Image structure and the image datas of the brush
'Rototo', coded in assembly, now WITHOUT comments.
III.- Option 'PALETTE' :
----------------
This option adds the code of the palette.
To see the result, repeat the same manipulations than I and II, with
'PALETTE' option.
IV.- Option 'C' :
----------
This option makes MICE generate C code instead of assembly code.
To see the result, repeat the same manipulations than I, II, and III, but
with the 'C' option.
V.- Multi-Selecting files without the 'MULTIFILES' option :
-----------------------------------------------------
V.1.- 'ASSEMBLY' option :
1 ->
Press the SHIFT key and click successively on the three files 'Brol',
'Gazm', and 'Rototo'.
2 ->
Click on the 'OK' gadget of the filerequester.
3 ->
Select the 'PALETTE' option.
4 ->
Click on the 'DO & QUIT' gadget.
5 ->
Load 'RAM:Mice.Code' in your editor.
The code you have obtained is made of three sections :
- SECTION Palette,DATA with the palette
- SECTION ImageStructure,DATA with all the Image structures
- SECTION ImageData,DATA_C with all the Image datas
This setting allows you to handle great blocks of datas with only one
cut-paste.
The palette features only once at the beginning of the file. That is the
palette of the first selected file, 'Brol'. If there was no palette in
'Brol', or if its palette was corrupted, there would be no palette section
in Mice.Code.
V.2.- 'C' option :
The C code is differently structured than assembly code.
Repeat the same manipulations than in part V.1., but with the 'C' option.
The palette features in first place, and the image datas are not separated
of the Image structures.
Since the LATTICE/SAS allows the use of the keyword 'chip', and that
guarantees that data within {} will be loaded into CHIP memory, then it is
not necessary to separate the different types of datas.
VI.- Multi-Selecting with the 'MULTIFILES' option and without 'PALETTE' :
------------------------------------------------------------------
1 ->
Press the SHIFT key and click successively on the three files 'Brol',
'Gazm', and 'Rototo'.
2 ->
Click on the 'OK' gadget of the filerequester.
3 ->
Select the 'MULTIFILES' option. Note that the 'SOURCE CODE FILENAME'
gadget now indicates 'RAM:' instead of 'RAM:Mice.Code'.
4 ->
Click on the 'DO & QUIT' gadget.
5 ->
On the filerequester of your editor, you can now discover three new files
in RAM:, named 'Brol.Code', 'Gazm.Code', and 'Rototo.Code'. Each of them
contains the image structure and the image data of its parent brush.
VI.- Multi-Selecting with the 'MULTIFILES' option and with 'PALETTE' :
---------------------------------------------------------------
1 ->
Press the SHIFT key and click successively on the three files 'Brol',
'Gazm', and 'Rototo'.
2 ->
Click on the 'OK' gadget of the filerequester.
3 ->
Select the 'PALETTE' option.
4 ->
Select the 'MULTIFILES' option.
5 ->
Click on the 'DO & QUIT' gadget.
6 ->
The window closes and a requester opens with the following message :
'Repeat palette in each file ?'. You may answer 'Yes' or 'No' :
VII.1. Answer 'Yes' to the requester :
Load successively the three files in RAM: 'Brol.Code', 'Gazm.Code', and
'Rototo.Code'. Each of them contains the palette, the image structure and
the image data of its parent brush. But this time, the palette of each
file is named respectively 'PaletteBrol', 'PaletteGazm' and
'PaletteRototo'.
VII.2. Answer 'No' to the requester :
On the filerequester of your editor, you discover a new file in RAM:, named
'Palette.Code', that contains the palette. However, the three others
files, 'PaletteBrol', 'PaletteGazm' and 'PaletteRototo', do not anymore
contain palette.
VIII.- Multi-Selecting files with only 'PALETTE' option :
------------------------------------------------
In most cases, when you want to code IFF brushes, they are parts of a same
screen, and have the same palette. That is why MICE generates only one
palette, except in the case described in VII.1.
But if you select ONLY the 'PALETTE' option, MICE will understand that you
need the palette of each selected brush.
So MICE will generate either a file with the three palettes 'PaletteBrol',
'PaletteGazm' and 'PaletteRototo', or, if you have chosen 'MULTIFILES'
option, three files 'Brol.Code', 'Gazm.Code', and 'Rototo.Code' that
contain respectively the palette of the parent brush.
IX.- 'SHOW IFF' :
----------
IX.1.- Simple-Selecting :
1 ->
Double-click on file 'Rototo'.
2 ->
Click on the gadget 'SHOW IFF'.
3 ->
A screen opens that shows you the brush 'Rototo'.
4 ->
Click on the left mousebutton. The screen closes and you are back to the
window.
IX.2.- Multi-Selecting :
1 ->
Press the SHIFT key and click successively on the three files 'Brol',
'Gazm', and 'Rototo'.
2 ->
Click on the 'OK' gadget of the filerequester.
3 ->
Click on the gadget 'SHOW IFF'.
4 ->
A screen opens that shows you the brush 'Brol'.
5 ->
Click on the left mousebutton. The screen closes and a new screen opens
with the brush 'Gazm'.
6 ->
Click on the left mousebutton. The screen closes and a new screen opens
with the brush 'Rototo'.
7 ->
Click on the left mousebutton. The screen closes and you are back to the
window.
X.- Options 'DO', 'DO & QUIT', 'CANCEL', 'QUIT' :
-------------------------------------------
The 'DO & QUIT' option allows you to code your image(s) and to quit MICE
immediatly.
The 'QUIT' option allows you to code your image(s) and to go back to the
filerequester for a new selection.
The 'CANCEL' option allows you to go back to the filerequester without any
effect.
The 'QUIT' option allows you to quit MICE without any effect.
LABELS AND FILENAMES :
--------------------
MICE retrieves the filename of your brush to generate its labels. It is
very handy because you can create your label at the very beginning of your
program, whilst you are drawing your bobs, images, gadgets, etc.
MICE converts the first letter of the filename in upper case if it is not
yet.
For example, from a brush named 'rototo', MICE will generate the labels
'ImageRototo', 'ImageDataRototo' and, eventually, 'PaletteRototo'.
Since the filename becomes label, it must follow some rules :
- filename must begin by ASCII a-z, A-Z, or _
- filename must not contain other character than a-z, A-Z, 0-9 or _
- then, filename must not contain either space or accentuated characters.
Examples of valid filenames :
Rototo
veRGlUtoMItrOPhLerCABle
Ramb0
R2D2
Louis_XIV
_fna
__vlu
Examples of non-valid filenames :
Starsky&Hutch
2001_A_Space_Odyssey
&%$?#(>*
_make room !
yékéké
etc...
- MICE refuses a file if the first letter of the name is not available.
- MICE accepts filenames that contains illegal characters : it keeps all
the available part and ignore all the following. Here are some examples of
what that means :
Starsky&Hutch gives the label ImageStarsky
brush.1 " " ImageBrush
brush.2 " " ImageBrush
brush(!&?<>) " " ImageBrush
_make room ! " " Image_make
etc... " " ImageEtc
So be sure that the first significant characters of your filenames are
different for each file.
In these examples, the two filenames 'brush.1' and 'brush.2' give the same
label. That would involve an error message at the assembly or compilation
time.
If you have chosen the 'MULTIFILES' option, only one file will appear,
named 'Brush.Code'. It contains the source code of the last file that has
been treated, because the two generated files had the same filename, and
the last saved has crashed the previous.
MICE is an EquiLog product.
Please write to :
EquiLog S.P.
c/o Pierre-Louis MANGEARD
15, rue des Cailles
Plateau Caillou
97460 SAINT PAUL
Ile de la Réunion