Extra Colors and Transparencies for OSD Elements? - page 2 - Feature Requests - CHDK Forum
supplierdeeply

Poll

Select up to 3 comments that reflect your opinions on this. (DEV for developers.)

Not needed.
4 (18.2%)
Might be nice.
5 (22.7%)
Yes, I'd like this very much!
8 (36.4%)
DEV: Impossible to implement.
0 (0%)
DEV: Possible, but I doubt it.
0 (0%)
DEV: It would take some time.
5 (22.7%)
DEV: Easy! How fast do you want it? :)
0 (0%)

Total Members Voted: 17

Extra Colors and Transparencies for OSD Elements?

  • 11 Replies
  • 6820 Views
Re: Extra Colors and Transparencies for OSD Elements?
« Reply #10 on: 17 / February / 2013, 20:11:10 »
Advertisements
My camera is a SX260 HS.

I'm fairly familiar with the palette mess (see also recent wiki edits).  There's actually quite a few in the autobuild that implement the overrides - although I wouldn't be able to say how effective they are and whether there's any negative fallout from doing so.

I'm a bit confused by you saying that the grids use indexes into the camera palette, unless you mean 'the camera palette post-chdk overrides', as a test grid using one of the overridden colors certainly uses that :)

That said, it's entirely possible that even though the colors could be overridden, for this model (and others) the 2bit alpha LUT probably means that there's little chance of any other alpha levels. I forgot about that aspect :)

*

Offline philmoz

  • *****
  • 3450
    • Photos
Re: Extra Colors and Transparencies for OSD Elements?
« Reply #11 on: 17 / February / 2013, 20:25:52 »
I'm a bit confused by you saying that the grids use indexes into the camera palette, unless you mean 'the camera palette post-chdk overrides', as a test grid using one of the overridden colors certainly uses that :)

Yes, the colors in the grid file are just values from 0 - 255 and get dumped into the bitmap without any translation. So grids will look very different on different camera models. Even with cameras that store custom colors in the palette they will come out differently since the colors are stored in different places.

By way of contrast the Lua drawing functions use a translation table to convert universal 'script' colors to whatever is closest for the camera (using the CHDK color values in gui_draw.h).

I experimented with changing the 'color' definition in CHDK to a 16 bit value and treating values > 255 as 'CHDK' colors, then using a lookup table to convert them to actual palette values. It got very complicated with the palette changing in different modes so I shelved it until I can come up with a better solution.

Phil.
« Last Edit: 17 / February / 2013, 20:29:05 by philmoz »
CHDK ports:
  sx30is (1.00c, 1.00h, 1.00l, 1.00n & 1.00p)
  g12 (1.00c, 1.00e, 1.00f & 1.00g)
  sx130is (1.01d & 1.01f)
  ixus310hs (1.00a & 1.01a)
  sx40hs (1.00d, 1.00g & 1.00i)
  g1x (1.00e, 1.00f & 1.00g)
  g5x (1.00c, 1.01a, 1.01b)
  g7x2 (1.01a, 1.01b, 1.10b)

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal