Jump to content

Jaguar Image Converter


SebRmv

Recommended Posts

Just tried Zeros convertors and they work great :) THANKS!
You're welcome ;)

 

SebRmv : to view CRY pictures on a PC, there's JagView, but it displays the colors slightly wrongly (so it's not a good tool for debugging). If I can find some time, I'll make a PC viewer for CRY files.

 

Link to comment
Share on other sites

Subsidiary question: how to view CRY15/RGB15 picture on a Jag?

I naively thought it was just needed to add VARMOD when setting VMODE, but it does not seem to work as I expect...

 

Link to comment
Share on other sites

Are these four images correct?

(these are ASM files, to include in a source file)

 

space.zip

Link to comment
Share on other sites

I tried all 4 in my app and they all looked like random data...

 

however your header in the .s says 320x200

 

the image i uploaded was 340x255.... so that might explain that

 

yes, these are 320x200 images (this should correspond to the bmp you posted above)

Link to comment
Share on other sites

I converted the files to binary (using a program written in 5 minutes ^^), and all of them display fine using the tool I posted yesterday. CRY15 and RGB15 files also work when using mixed-mode. So maybe there's something wrong with your display code, or your assembler is somehow generating junk...

 

Here are the files in binary form if it's useful : space.zip

Link to comment
Share on other sites

Would love to learn the final word of the story. Cyrano, could you please post the piece of code you are using? I can post mine if you wish (but it uses my library).

 

Anyway, I fixed a bug in my converter. The 15 bits mode were flawed, thanks for having spotted that (even if it seems it might be by accident :P)

The bad news is that I have to recompile a Windows compatible version if I want to make a binary distrib...

Link to comment
Share on other sites

Here is the code I used to test the four images... Just change the way VMODE is initialised depending on the image format.

 

#include <jagdefs.h>
#include <jagtypes.h>
#include <stdlib.h>

#include <interrupt.h>
#include <display.h>
#include <sprite.h>

#include <sound.h>

#include <joypad.h>

#include <console.h>

extern phrase image;

int main(int argc, char *argv[]) {
  SET_SHORT_INT(CRY16|CSYNC|BGEN|PWIDTH4|VIDEN,VMODE);     // for CRY16
//  SET_SHORT_INT(RGB16|CSYNC|BGEN|PWIDTH4|VIDEN,VMODE);     // for RGB16
//  SET_SHORT_INT(CSYNC|BGEN|PWIDTH4|VIDEN|VARMOD,VMODE);     // for CRY15/RGB15
  init_interrupts();
  init_display_driver();

  display *d = new_display(0);
  d->x = 16;
  d->y = 8;

  show_display(d);

  sprite *s = new_sprite(320,240,0,0,DEPTH16,&image);
  attach_sprite_to_display_at_layer(s,d,1);

  while(1) {
    vsync();
  }

  return 0;
}

Link to comment
Share on other sites

Here are the converted image (in ASM format)

 

NEBULA.zip

Link to comment
Share on other sites

Ok, so I'll have a look at the Windows port (if I am courageous enough)

 

Link to comment
Share on other sites

  • 2 years later...
Sorry to bring this up from the dead but I can't find a copy of this anywhere. The Removers' website is down and searching google for "converter-0.1.8.tar.gz" brings up nothing.

 

Hello,

 

The Removers website run nicely, i have done a download on it and it run :

 

http://removers.free.fr/softs/download.php

 

 

GT :poulpe:

Link to comment
Share on other sites

  • 1 year later...

I nice addition to this converter would be the "--header" option of the original tga2cry

I need to convert a lots of pictures with different size, so storing the width/height inside the final picture binary would be nice :)

you could store it using long, so width.l height.l makes 8bytes, the data are still phrase aligned :)

tga2cry have this option but it don't have the "auto pad width to phrase boundary", which is required for all the pictures I have

 

Link to comment
Share on other sites

Thanks for the suggestion. I will add the option very soon (hopefully tomorrow).

What is the exact behaviour of tga2cry when the --header option is enabled?

 

Once added, I plan to make a source release. Will you be able to build yourself the binary? I have not the compilation chain setup for windows...

 

Link to comment
Share on other sites

Just added the --header option. The source is available on my website.

It emits two words and a long corresponding to the height of the picture, the width of the picture, and the flags for the blitter (PITCH, DEPTH, WIDTH): this is to mimick tga2cry behaviour.

 

Link to comment
Share on other sites

Thanks for the quick release, but, I tried to install ocaml on windows, it works but I can't compile camlimages :/

 

Zerosquare > thanks but I use rgb output, not cry :)

 

Do you use a cygwin environment?

You need to take an old version of camlimages.

On archlinux, I packaged this version: https://aur.archlinux.org/packages/camlimages3/

I guess it should compile/work the same on windows/cygwin.

I hope you manage to compile it, because I am a bit lazy to install cygwin myself.

Please let me know. If you can't do it, I'll give it a try next tuesday at my office during the lunch break.

 

Link to comment
Share on other sites

I tried all I can using cygwin but I'm still stuck when compiling camlimage, seems like a problem with autoconf

anyway, I finally made a little tool to adjust the width of the output from tga2cry, it was easier and faster to do..

hopefully someone can make a windows binary release of your tool one day :D

 

Link to comment
Share on other sites

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...