Short: Convert any picture to HAM6/HAM8. Author: thellier@free.fr (Alain Thellier) Uploader: thellier free fr (Alain Thellier) Type: gfx/conv Version: 2 Replaces: util/conv/DatatypeToHam.lha Requires: OS3.0 or higher,picture datatypes Architecture: m68k-amigaos DESCRIPTION FRANCAIS DatatypeToHam : Alain THELLIER - Paris - FRANCE DatatypeToHam est une commande pour convertir des images en HAM6 ou HAM8 Avec les datatypes lit tout les formats images version v2: n'a plus besoin de la SimpleDT.library et cybergraphics est faculative (selon UseWindow flag) Une version 68000 et une version 68020/68040 fournies -------------------------------------------------------------------------------------------------- Si vous aimez ce prog envoyez moi une carte postale: Thellier. 43 Rue Ordener. 75018 PARIS. FRANCE -------------------------------------------------------------------------------------------------- LICENSE GNU General Public License (GNU GPL) USAGE 1)Simple DatatypeToHam Ouvre juste un selecteur de fichier pour choisir une image Mais aura par défaut flags=UseFloydSteinberg+UseHam8+UseScreen+UseSave; HamLarge=320; HamHaut =480; 2) Expert Vous pouvez donner les flags et la taille DatatypeToHam Flags NomFichier HamLarge HamHaut HamLarge HamHaut est la taille voulue en pixels FileName est l'image à lire flags est l'addition de ces valeurs UseFloydSteinberg =8 ; /* utilise le tramage Floyd-Steinberg sur l'image puis la convertit en ham */ UseError =1 ; /* utilise aussi une propagation d'erreur simple en convertissant chaque ligne en HAM (erreur dans les pixels droits) */ UseShortError =2 ; /* Si UseError+UseShortError sont mis alors cette propagation d'erreur ne dépasse pas trois pixels */ UseGreyTolerance =4 ; /* Préfére les gris de la palette aux couleurs ham */ UseHam8 =16 ; /* utilise le HAM8 sinon HAM6 */ UseScreen =32 ; /* ouvre un écran HAM et y affiche l'image */ UseWindow =64 ; /* ouvre une fenetre RGB sur l'écran Workbench et y affiches les images original&HAM (y faut une carte RTG) */ UseSave =128; /* sauve l'image HAM avec le nom NomFichier-flags.iff */ UseQuiet =256; /* n'affiche aucune infos texte */ Donc si voulez sauver/afficher une image Ham8 alors il faut flags=16+32+128=176 Exemple : DatatypeToHam 176 image.png 320 480 DatatypeToHam 184 autreimage.jpg DatatypeToHam 168 Les flags ples plus utiles sont 184 pour HAM8 or 168 pour HAM6 SAVOUREZ Alain Thellier ---------------------------------------------------------------------------------------------------- DESCRIPTION ENGLISH DatatypeToHam : Alain THELLIER - Paris - FRANCE DatatypeToHam is a simple tool for converting pictures to HAM6 or HAM8 With the datatypes it can read any picture formats version v2: no more need SimpleDT.library and cybergraphics is optionnal (UseWindow flag) Include a 68000 binary and a 68020-68040 binary --------------------------------------------------------------------------------------------- If you enjoyed this prog send me a postcard at: Thellier. 43 Rue Ordener. 75018 PARIS. FRANCE --------------------------------------------------------------------------------------------- LICENSE GNU General Public License (GNU GPL) USAGE 1)Simple DatatypeToHam will open a requester for selecting the picture But will have those default flags=UseFloydSteinberg+UseHam8+UseScreen+UseSave; HamLarge=320; HamHigh =480; 2) Expert You can specify the flags and size with this syntax DatatypeToHam Flags FileName HamLarge HamHigh HamLarge HamHigh is the wanted size in pixels FileName is the input picture flags is the addition of those flags UseFloydSteinberg =8 ; /* use Floyd-Steinberg on picture then convert to ham */ UseError =1 ; /* also use simple error propagation when converting a line to HAM (error to right pixels) */ UseShortError =2 ; /* If UseError+UseShortError then limit this error propagation to three right pixels */ UseGreyTolerance =4 ; /* Give a preference to the greys from palette against HAM colors */ UseHam8 =16 ; /* use HAM8 else use HAM6 */ UseScreen =32 ; /* open an HAM screen and display the picture */ UseWindow =64 ; /* open a RGB window on the Workbench screen and display the original&HAM pictures (need an RTG card) */ UseSave =128; /* save the HAM picture as filename-flags.iff */ UseQuiet =256; /* no text ouput */ So if you want to only save/display an Ham8 picture then you need flags=16+32+128=176 Exemple : DatatypeToHam 176 picture.png 320 480 DatatypeToHam 184 otherpicture.jpg DatatypeToHam 168 Typical flags values are 184 for HAM8 or 168 for HAM6 ENJOY Alain Thellier