|
Forum Index : Microcontroller and PC projects : CMM2 Asteroid Blit test video
| Author | Message | ||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
Hey all here's a link to a youtube video I did of an asteroid blit test. Blit Test |
||||
| Atomizer_Zero Senior Member Joined: 04/07/2020 Location: United KingdomPosts: 134 |
It's incredibly fast. I had a similar experience the other day loading in streams of DATA and blitting the tiles to the screen. Again, had to slow it down, and slow down keyboard input too, to prevent reacting to the key press multiple times to scroll the data tiles.. I would be interested to see if you have any issues with transparency, as I notice you're drawing the asteroids onto a black background. I'm having issues with SPRITES erasing the page 0, despite being on page 1 ( in 12 bit mode)(probably something im doing wrong.. need to open a thread about it I think...) Looking forward to playing your game when its up and running |
||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
you can set the blit to not copy transparent pixels, but then when they are spinning in place they won't erase the previous copy. I tried it with overlapping oids and they were masked correctly. I wasn't sure how fast the blitting was until I tried it here. wow Now I'm certain I can blit with color 0 removed onto a fresh nebula on another page and blitted to page 0. I'm working on a test for that, but I ran into a snag with loading pictures I have bmp and gif files WITH THE PALETTE I'm using, but when they're loaded THE COLORS ARE BEING REMAPPED TO FIT THE DEFAULT PALETTE INSTEAD OF THE PALETTE I JUST SET, so all the colors are wonky. If I map reset, poof the gif or bmp I load looks right and all the other graphics on the screen have garbled colors. I would expect it should try and remap if it has to to the CURRENT PALETTE! Why can we set a palette if loaded art in the right format won't map to it? The picture are 8 bit specifically set to the palette I'm using. (I rechecked in photoshop and i'm changing the palette according to the photoshop palette file.) scratching my head on it. S0 I have to go back to the original software I used 20 years ago to process those pictures like I did the sprites. In the PC game I could just load the image and the palette and everything was fine. ![]() ![]() Edited 2020-08-09 20:18 by berighteous |
||||
| Atomizer_Zero Senior Member Joined: 04/07/2020 Location: United KingdomPosts: 134 |
I tried using MAP as well, when doing the PPU for my nes emulator. It was producing wonky colours for me too, so I wonder if this is actually a bug right now. Perhaps its reversing the colours. Try using B, G, R instead of R, G, B.. just out of curiosity. Edited 2020-08-09 20:31 by Atomizer_Zero |
||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
no, it's definitely remapping the picture to the default palette. When I map reset all the colors on the screen change and the image colors pop back to looking exactly like it does if I load it without changing the palette. |
||||
| matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 10580 |
The BMP and GIF decoders know nothing about any colour mapping. They just convert the incoming data to RGB888 and that then is loaded to the screen using the standard RGB888 to RGB332 mapping. To do anything else would be unrealistic: for each pixel search the map table and look for the nearest match? using what criteria? |
||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
What's the point of being able to change the palette to what you need if you can't load images USING the palette? That makes no sense at all. We can't make artwork for our games? We have only 256 colors to work with. We change the palette to give us more colors we need in certain areas and to do effects like color cycling. The ability to load in art and have the palettes respected the most important aspect of creating new games for the CMM2. Otherwise we're locked to balls and triangles and boxes. We have to have the ability to choose the colors we want to use and BE ABLE TO USE THEM. This is crazy important to actually using the modes you gave us. In my particular use case my bmps are 8 bit indexed color images with a common CLUT. shouldn't the pixels be already be indexed into the clut? How are 8 bit "indexed color" images stored? I am not talking about loading in generic 32bit color images. I'm using 8-bit indexed color images. Edited 2020-08-10 05:39 by berighteous |
||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
In the late 90's I wrote a bunch of arcade games in a neat fast interpreted language called Euphoria. (now it's Open Euphoria and probably dead for years) One of the neat things someone made it do was load BMPs and separate the data into an object with multiple, multi-dimensional arrays. One index was the bmp header info and stuff and the second index was just the pixel data in an array HxV. so when I loaded a bmp I could put just the pixel color indexes into a 2 dimensional array - a "sprite" The language didn't have sprites, I had to do masking pixel by pixel. I then saved that index data into the data files I'm using now. At the time (1996) I didn't convert the full sized images to that format because I could just load the bmp's in and change the clut on them on the fly because vga on the pc then just worked that way. So I have a workaround for CMM2 not loading my images "correctly." I searched the web and found the archives of the old euphoria language release I used to create the games originally. I have to run them in dosbox now. Then I can go back to the original euphoria programs that created my other data files, and I can make them load the 320x200 images into a euphoria object and then write out just the color index matrix to a data file, that I can read in my cmm2 program and have it look correct. The downside is each of the 3 files I need takes an extra 3 seconds to process this way. Maybe I can make them sprites and save them and they'll load faster that way? The old challenge of trying to make something you don't understand do what you want to do. It's like it's 1980 and I'm 14 again, lol. I really like the cmm2. Edited 2020-08-10 06:27 by berighteous |
||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
![]() ok I processed the bmp using ancient vga secrets and created a data file of just the pixel color indexes and can load it in. Tada! |
||||
| Atomizer_Zero Senior Member Joined: 04/07/2020 Location: United KingdomPosts: 134 |
Your last few posts have been somewhat of a roller coaster! lol It mimics how I feel with various aspects of the CMM2 too. It certainly does take some work arounds to get the results you want... but when you do work it out, it's the greatest feeling. "Euphoria", if you will One thing I will say is, the tool to convert the BMP files in Eurphoria could most likely easily be programmed for the Colour Maximite 2. Looking forward to trying out game when its all up and running! |
||||
| berighteous Senior Member Joined: 18/07/2020 Location: United StatesPosts: 110 |
lol. I'm a game programmer. if I have to break out Autodesk Animator and run it in dos box to make art to run on this thing I'll do it like we did in the 90's As for euphoria the language - I wrote a book on creating the original OidZone game from design specification, through language reference and line by line code exposition. I recreated OidZone for the Apple ][ in 6502 assembly language a couple years ago. I'm kinda taking a short break from my latest Apple ][ game to play with the colour maximite 2. Edited 2020-08-10 09:22 by berighteous |
||||
| The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |