Page 1 of 1

Image2TexturesPlus: generate per-pixel TEXTURES compositions

Posted: Mon Feb 22, 2016 8:32 am
by Nash
Image Image

Image 1: Can you tell which one is the stock Doom door and which one is the generated one? ;)
Image 2: What the generated TEXTURES lump looks like
A command line tool that scans all PNGs in the current directory, and generates
a per-pixel reconstruction of said graphics in TEXTURES format.

How to use:

Place Image2TexturesPlus.exe in the same directory as your graphics and simply
run the application. An "Output.txt" will be generated - just copy and paste
the output to where it needs to be in your project hierarchy.

- OR -

Add Image2TexturesPlus.exe into your Windows PATH variable so that you can
invoke it from any directory.

You will need an image called "pixel" placed into /patches in your project for
the reconstruction to be successful; I have included it in this package!

Credits:

carlcyber - original "Image2Textures" program which was used as a base.
Nash Muhandes - Image2TexturesPlus variant.
Made this little tool because I thought it would help in the 64 KB compo, theory got busted, decided to upload it anyway so that it doesn't get lost in oblivion (and because I could not find the program some other guy wrote on this forum which apparently did the same thing, so I figured giving this a project thread makes it easier to search for). Written in C#. Thanks to carlcyber for writing the original Image2Textures.

Download | Demo map | Source code

Re: Image2TexturesPlus: generate per-pixel TEXTURES composit

Posted: Mon Feb 22, 2016 8:44 am
by The Zombie Killer
If you ported this to GDCC (C) using HudMessages, then this could be used in GLOOME to write things like ACS raycasters, if you're insane :p

Re: Image2TexturesPlus: generate per-pixel TEXTURES composit

Posted: Mon Feb 22, 2016 8:46 am
by Nash
LOL! People have done all kinds of crazy shit with Doom; I won't be surprised if one day someone writes an entire freaking game running within the ACS VM with HudMessages as the graphics API. :S

(Say, that might be a cool idea for the 64 KB compo, HMMMMM...)

Re: Image2TexturesPlus: generate per-pixel TEXTURES composit

Posted: Mon Feb 22, 2016 12:24 pm
by kodi
I've been planning a hudmessage roguelike or simple platformer with downscaled doom2.wad sprites for the competition, we'll see how that goes. I've also been thinking of how cool it would be if there was a mod containing a handheld console "weapon" and a simple "OS" for it that could launch ACS scripts (games) supplied through other pk3's loaded along with it. Just like in TimeSplitters 2 eh?

A big problem with a hudmessage raycaster other than the sheer insanity is going to be sprite scaling I'd imagine.

Re: Image2TexturesPlus: generate per-pixel TEXTURES composit

Posted: Tue Feb 23, 2016 2:05 am
by The Zombie Killer
That actually sounds really neat, I still need to get something done for the 64k competition.
kodi wrote:I've also been thinking of how cool it would be if there was a mod containing a handheld console "weapon" and a simple "OS" for it that could launch ACS scripts (games) supplied through other pk3's loaded along with it. Just like in TimeSplitters 2 eh?
Hah, back when I first posted Classic Arcade on YouTube, people asked me to do a similar thing to that, but with an ingame calculator. I'd love to see that if you ever make it

Re: Image2TexturesPlus: generate per-pixel TEXTURES composit

Posted: Tue Feb 23, 2016 7:06 pm
by XCVG
I wrote a nearly identical tool last year hoping to use it for the shitty wad competition that never happened. I went through several iterations, starting with a manual (and VERY tedious) proof of concept, then making one that layered existing textures in a specific order (extremely limited palette and actually more complicated) before realizing I could exploit translations to do the same thing. However, I used a piece of an existing texture instead of adding my own patch. One thing I found out very quickly is that the resulting file size was quite large even after compression.

Re: Image2TexturesPlus: generate per-pixel TEXTURES composit

Posted: Wed Feb 24, 2016 12:34 am
by zrrion the insect
If you were going to use this to make large textures/sprites in TEXTURES it might be worth making it have a different graphic for every index in the palette so that you could cut out the translation part of each line in the definition of the texture/sprite and instead use one of the pre-translated graphics.
Depending on the size/complexity of what you were doing, that could cut the filesize down quite a bit.