TTLG|Thief|Bioshock|System Shock|Deus Ex|Mobile
Results 1 to 10 of 10

Thread: How to make transparent textures compatible with Dark in Gimp

  1. #1
    Zombified
    Registered: Sep 2004

    How to make transparent textures compatible with Dark in Gimp

    I didn't manage to find any tutorials on how to make/modify object textures with transparent parts using tools that wouldn't require a win95 virtual machine, so I've tried my luck with Gimp and found out it's actually pretty easy - as posted on systemshock.org;

    If you are creating or modifying object textures that have transparent parts, you might have noticed how easy it is to break them - typically, the texture will display some transparency artifacts, looking like small holes when viewed ingame. Fixing this is quite easy, fortunately - you just need to get Gimp (freeware), and follow the instructions below:

    - load the texture into Gimp
    - go image/mode, select RGB
    - click on the currently selected color, pick a custom color, set it to ff00ff (it's what is being used by vanilla SS2 textures, so lets go with that)
    - color all parts that should be transparent with this color
    - go image/mode, select indexed
    - set it to generate optimum palette, number of colors 254, and convert
    - go windows/dockable dialogs/colormap
    - rightclick on the ff00ff pixel, choose rearrange colormap, move it to spot 0, click ok
    - export as gif (or pcx)

    The resulting texture should have proper transparency, both under NewDark and oldDark. I'm guessing the same result can be achieved with other image editing tools as well, as long as they support all the required functionality.


    Notes: if you observe similar transparency artifacts on a texture that doesn't need any transparency, saving it as png should be enough to fix it (but you could apply the colormap fix as well if you really want to, or if oldDark compatibility is required). Also, remember that all Dark textures should be power of two sized.


    it is possible that I have missed some link with an already existing tutorial similar or identical to this (as mentioned a couple of times before, the TTLG FAQs are basically unusable), but I'm pretty sure that someone will let me know in case I'm reinventing the wheel here (will delete this if that turns out to be the case).
    Last edited by voodoo47; 29th Apr 2019 at 17:18.

  2. #2
    Member
    Registered: Aug 2006
    Location: France (Saint-Gobain)
    never used Gimp to do gif. textures with transparencies , i have to to try this program, png texture have a good quality but for some objects it doesn't render well, while with gif. format it always render well in newdark.

  3. #3
    ZylonBane
    Registered: Sep 2000
    Location: ZylonBane
    Quote Originally Posted by Cardia View Post
    png texture have a good quality but for some objects it doesn't render well, while with gif. format it always render well in newdark.
    This is only because you have no idea what you're doing.

  4. #4
    Member
    Registered: Aug 2006
    Location: France (Saint-Gobain)
    Quote Originally Posted by ZylonBane View Post
    This is only because you have no idea what you're doing.
    I agree with you.

  5. #5
    Member
    Registered: Sep 2008
    Location: Deutschland/Germany
    Quote Originally Posted by voodoo47 View Post
    - export as gif (or pcx)
    And .TGA if I remember right. Example: http://spirited-tech.com/thief/2015/...ols-by-ottoj55 ... or is that another type of transparent texture?
    My FM campaigns Garrett's Young Years XTra, Reunion With Basso
    Want your upcoming FM translated in foreign languages?

  6. #6
    Zombified
    Registered: Sep 2004
    not sure whether you can make indexed/paletted TGAs, or whether there is an actual reason you would want to.

  7. #7
    Desperately Dodgy Moderator
    Registered: Nov 2001
    Location: Dragonsreach
    You can but there is no reason to. Because, unless you're building your mission using and for OldDark, there is no reason at all to use image file formats other than PNG and DDS. None.

  8. #8
    Zombified
    Registered: Sep 2004
    PNGs are not too efficient if memory serves (no compression), but that shouldn't matter too much unless you go completely bonkers with both the amount and resolution (or are running on 20 years old hardware).

    but I have to admit I prefer to stay as efficient as possible, as I like to run Dark on 500MHz cpus with 16MB gpus sometimes.

  9. #9
    ZylonBane
    Registered: Sep 2000
    Location: ZylonBane
    Quote Originally Posted by Yandros View Post
    You can but there is no reason to. Because, unless you're building your mission using and for OldDark, there is no reason at all to use image file formats other than PNG and DDS. None.
    I have a reason to, albeit not a great one. PaintShop Pro 7 (which I'm still stubbornly sticking with) has an unfortunate optimization with transparent PNGs. When you save them, any pixels that are 100% transparent are converted to black. This reduces the file size, but introduces a subtle black fringe around the edges when the PNG is used as a filtered texture. TGA doesn't have this problem since the alpha channel is stored as a separate layer.

    As for PNG over GIF/PCX, I have a suspicion that GIF/PCX textures load faster due to the simpler format, but I've never run any tests to actually confirm this.

    Quote Originally Posted by voodoo47 View Post
    PNGs are not too efficient if memory serves (no compression)
    You're probably thinking of lossy vs lossless compression. PNG is lossless, but it does use the Deflate algorithm to compress things as much as possible.

  10. #10
    Zombified
    Registered: Sep 2004
    right. not an expert in the texture field by any stretch of the imagination.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •