Author Topic: automatic conversion between ufo and tftd palette  (Read 12918 times)

Offline davide

  • Commander
  • *****
  • Posts: 565
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #15 on: June 29, 2014, 12:32:46 am »
so i found the time to work with your numbers today :)

FYI: my tftd palettes were slightly wrong - i fixed that

....
for me it seems manual trumps automatic color assignments not necessarily in regard to color similarity but in less fixing work after conversion

Do you think I should change some color associations in my lookup index ?

From  your example I undestand that probably it is better change color index 16-32 from green base to light brown because it is more near to yellow
« Last Edit: June 29, 2014, 01:15:54 am by davide »

Offline Falko

  • Commander
  • *****
  • Posts: 802
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #16 on: June 29, 2014, 02:14:21 am »
i am not 100 % sure what the text file you attached should be
98 colors are not in the ufo-battlescape pallette and 235 colors are not in the tftd depth0 palette
could you attach something like the ReindexPalette.csv.txt from (https://openxcom.org/forum/index.php?topic=2327.msg24330#msg24330) if you have a new conversion
i put the terrain data against the conversion data mentioned above and my manual conversion
left=original,middle your (old?) automatic conversion, right=my manual conversion
on the palcomp2-image the autoconversion has again slightly better colors (floor, terrain=dirtstuff) but strange errors/spots that need fixing (doors, dinertable,..)
on the palcomp3-image (sea terrain) my conversion fails big time yours is not perfect but usable

the great thing is one could create different  conversions and pick the best (the resulting conversion use of course the same palette)
at the moment i think:
for the weapons the change "green base to light brown" was better - but perhaps for sea or island-dirtstuff your indexing is better - who knows - we can just generate both and let the user/modder decide whats best :)

"What is the index of trasparent color in the UFO palette ?"
index0=transparent for all gifs i produce
also all ufo-act files i have also have pink as index0 color i set it to [0,0,0] but i have no idea if thats "original"

Offline davide

  • Commander
  • *****
  • Posts: 565
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #17 on: June 29, 2014, 09:08:20 am »
could you upload your last palette ?
I wish compare it with mine

Offline Falko

  • Commander
  • *****
  • Posts: 802
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #18 on: June 29, 2014, 11:33:50 am »
zip with act/example image attached

Offline Falko

  • Commander
  • *****
  • Posts: 802
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #19 on: June 29, 2014, 03:25:55 pm »
if you are interested you can try out the conversion here
https://falkooxc.pythonanywhere.com/palconvert
select tftd-depth0 for my conversion or tftd-depth0B for your conversion into ufo-battlescape

Offline davide

  • Commander
  • *****
  • Posts: 565
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #20 on: June 29, 2014, 04:17:34 pm »
thank you I will check it soon.

I made a fix for yellow colors 8)

I load into PCKView all TFTD terrain .PCK files and them are acceptable for me  ::)

I do not understand because PCKView shows tiles with wrong background (dark green) :'(

Offline Falko

  • Commander
  • *****
  • Posts: 802
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #21 on: June 29, 2014, 04:55:11 pm »
new compare image and added as tftd-depth0C on the website

Offline alienfood

  • Captain
  • ***
  • Posts: 79
  • It's people!
    • View Profile
Re: automatic conversion between ufo and tftd palette
« Reply #22 on: June 30, 2014, 02:15:51 am »
This is very interesting work! Thank you!