English Amiga Board


Go Back   English Amiga Board > Support > support.Other

 
 
Thread Tools
Old 03 February 2020, 18:08   #1
Retro1234
Phone Homer
 
Retro1234's Avatar
 
Join Date: Jun 2006
Location: 5150
Posts: 5,773
Two Identical 16 colour Images?

I don't have access to a decent computer or I would test myself

We have a 16 colour IFF we save it in HAM format but it is only 16 colours what Image/File will have the larger size? Or will they be the same file size?

Why I ask, HAM is Supposed to have some lossy compression.
Retro1234 is offline  
Old 03 February 2020, 19:33   #2
DanScott
Lemon. / Core Design
 
DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,212
A 16 colour image is 4 bitplanes... a HAM image would use 6 bitplanes... so the HAM image would be bigger.

There is no compression with HAM, other than the way it uses the bitplane data to either read a colour from the palette, or to modify one of the previous pixels R,G or B values
DanScott is offline  
Old 03 February 2020, 19:49   #3
Retro1234
Phone Homer
 
Retro1234's Avatar
 
Join Date: Jun 2006
Location: 5150
Posts: 5,773
Thank you for your reply sir
Retro1234 is offline  
Old 03 February 2020, 23:57   #4
DamienD
Banned
 
DamienD's Avatar
 
Join Date: Aug 2005
Location: London / Sydney
Age: 47
Posts: 20,420
What exactly does this thread have to do with Creation > Graphics > Graphics. Work In Progress?

...moved accordingly.
DamienD is offline  
Old 12 February 2020, 00:19   #5
Retro1234
Phone Homer
 
Retro1234's Avatar
 
Join Date: Jun 2006
Location: 5150
Posts: 5,773
What compression type does IFF use for instance we have Two images 320*256 one is a very detailed image the other is just A box, both images are the same size and amount of pixels but the one of the box has a much smaller file size.
Retro1234 is offline  
Old 12 February 2020, 07:51   #6
Solo Kazuki
Registered User
 
Solo Kazuki's Avatar
 
Join Date: Sep 2004
Location: Poland
Posts: 1,301
IFF-ILBM could be optionally compressed (which is probably in Your case) with RLE compression.
Solo Kazuki is offline  
Old 12 February 2020, 09:09   #7
fxgogo
Also known as GarethQ
 
fxgogo's Avatar
 
Join Date: May 2019
Location: Twickenham / U.K.
Posts: 715
Just to add to Solo Kazuki, RLE compression is lossless.

Normally uncompressed images save pixel info as: pixel # is value #, next pixel # is value #, etc. For NLE compression, If pixels of common colour are next to each other the info is saved as follows: pixel # to pixel # is colour value.

So images with lots of fine detail won’t see a huge saving, but images with lots of solid areas of colour will.
fxgogo is offline  
Old 12 February 2020, 12:56   #8
Retro1234
Phone Homer
 
Retro1234's Avatar
 
Join Date: Jun 2006
Location: 5150
Posts: 5,773
What I'm think is if we can have a transparent colour in CDXL

Like MPEG we can Compare each frame by frame and only update the parts needed
[ Show youtube player ]
On stuff not moving much we save alot and could get a lot more smaller file size.
Retro1234 is offline  
Old 17 March 2020, 15:46   #9
Cobe
Registered User
 
Join Date: Jan 2014
Location: Belgrade / Serbia
Age: 41
Posts: 999
I think you're thinking about delta compression that yafa already uses.
Cobe is offline  
Old 17 March 2020, 16:06   #10
Retro1234
Phone Homer
 
Retro1234's Avatar
 
Join Date: Jun 2006
Location: 5150
Posts: 5,773
I think it's called I frame or something but simpler I don't know much it would save a test could be done with ImageMagic.
Retro1234 is offline  
Old 17 March 2020, 22:14   #11
AmigaHope
Registered User
 
Join Date: Sep 2006
Location: New Sandusky
Posts: 942
Quote:
Originally Posted by DanScott View Post
A 16 colour image is 4 bitplanes... a HAM image would use 6 bitplanes... so the HAM image would be bigger.

There is no compression with HAM, other than the way it uses the bitplane data to either read a colour from the palette, or to modify one of the previous pixels R,G or B values
This is effectively (mathematically) a lossy compression format, in that it compresses a 12-bit image down to 6 bits by throwing away 2 of the 3 RGB channels for a given pixel. It's crude and simple but it's definitely compression (akin to the subsampling compression used in MPEG where they throw away 3 out of every 4 chroma samples -- in fact this is more like how HAM was originally supposed to work back when it was intended to operate on a YUV space).
AmigaHope is offline  
Old 23 March 2020, 23:37   #12
Retro1234
Phone Homer
 
Retro1234's Avatar
 
Join Date: Jun 2006
Location: 5150
Posts: 5,773
Does yafa compare images like static backgrounds?

presumably applying compression like xpk to them wont increase FPS etc because the player doesn't know the overall file is smaller

it would require a new player so instead of just streaming frame by frame it could look at the file size and decide ok instead of just streaming 1 frame it can stream such amount and such amount of data like 1 and half frames with my limit of 300kb transfer.

I still think comparing frames could work especially if you remove noise and make an allowance for say a 10% difference of each 16*and 16 square of the image - wouldnt require any extra CPU to decompress, it would already be decompressed etc.
Retro1234 is offline  
Old 24 March 2020, 12:09   #13
Cobe
Registered User
 
Join Date: Jan 2014
Location: Belgrade / Serbia
Age: 41
Posts: 999
Now you got me thinking. I thought that yafa compares frames but it probably compares just certain selected consecutive run of bits byte, word or long.
Maybe xpk cant help on 020 but on 030 I'm pretty sure it could.
Cobe is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
32 colour games? donnie Amiga scene 6 29 June 2017 01:13
Colour issue AtlasRapture support.WinUAE 7 17 July 2010 11:39
Colour space absence support.Hardware 5 04 June 2009 14:57
A520 - No Colour? EreWeGo support.Hardware 8 04 October 2008 23:47
Using 2 identical joysticks w/ WinUAE Ellokin support.WinUAE 1 11 October 2007 15:35

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 18:31.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.10053 seconds with 13 queries