Short: How to Use V39/V40 graphics.library Author: jschober@campusart.com (Jürgen Schober) Uploader: jschober campusart com (Jürgen Schober) Type: dev/src Version: Rel5 Architecture: m68k-amigaos Date: 96/12/04 Replace: How2UseGfxV39.lha How2UseGfxV39.readme How2UseGfx-P2.lha How2UseGfxV39-P2.readme Now part 2 of the demo is also included into this archive and it is ~800KB in size :) This archive includes some code that shows how you can use systemfriendly BitBlits. It shows how palette sharing is handled and how friendbitmaps can be used. The main goal is to show that it is possible to support both native ECS/AGA and gfxboards with image blitting stuff and how you can check out what is the best way to blit images. The demo opens a window on the public screen (Workbench) allocates pens for a red, a green and a blue shaded ball. Also a background pen is allocated and the color is cycled throu a color table. The balls are moved around the window. It runs on any displaymode, independend if gfx board or not or what color depth you use (though I haven't tried 24 bit modes yet). Within a talk to another programmer I found that there is some need on information on this topic. So I thought I should release such an archive. Feel free to do what ever you want with this archive (except selling it and making money:) As this example could also to be used to write board friendly games, it is dedicated to these people out there who are still thinking palette sharing etc. is useless...why can't I have white backgrounds on some text manipulation programs ? New: Chunky Friend Allocation has been fixed (BMF_MINPLANES) 30.11.96 Minor changes to the code (inner sizes are calculated right) Please, also see the ReadMe included in this archive. ----------------------------------------------------------------------------- Part 2 Readme: I have now included the part 2 into this archive, also the Image is available in source code. I also fixed the rastport bug I had in part 2 before , and also I forgot to free the background in the last release... (what a shame, I know =:~/ ) This archive contains some example material how scrolling bitmaps could be handled. It is just an example how things could be done, because I am bretty sure, none of you will use ScollLayers() in a SuperBitmap window for a real application. But with a fast board (e.g. a PiccoloSD64) and a good driver (e.g. EGSPlus :) it shows what could be done if the Amiga would have the right chips. This demo opens a 320x256 window on any screen (currently a WB clone or the WB itself) with a 640x512 custom superbitmap attached to it. The backdrop is a 256 color image (640x512) which is scrolled thru the window. On top of it a green ball is jumping around. Both images where created in 24 bit and color reduced to 256 colors. The real colors are calculated on startup using a shared palette. It looks best when run on a 256 color screen (but will reduce the colors if less). It should run on any board (ECS/AGA too) but isn't really useable on native amiga chips... I haven't tried CyberGraphics yet (but I should) but I think it would run more smoothly on EGS systems (with EGSPlus) since the SuperBitMap is held in boardmemory in this case which makes the scrolling much better :) It does no buffer blitting yet (e.g. double buffer, refresh buffer or such). And it does not use an custom scrolling code, which would sure help for slow boards...(e.g. a delta frame scrolling would be a lot faster). But maybe you find some things what would be intuitiv for your ideas. So check it out ... and if you have a fast EGS board enjoy :) PS.: I haven't either included the Backdground image nor the Image source since this have about 1.2 MB...the object code should be ok if you want to recompile it. The colortableformat is a modified Amiga Colortable format and looks like this: struct Colors { ULONG red,green,blue; // left justified 32 bits } colors[256]; all other things should be clear from the source code. You should be able to hook another image in ... --- Jürgen Schober Graz · Austria e-mail: point@sbox.tu-graz.ac.at (private) jschober@campusart.com (business) WWW: http://www.sbox.tu-graz.ac.at/home/point/Welcome.html http://www.pointdesign.campusart.com/