PyonFX icon indicating copy to clipboard operation
PyonFX copied to clipboard

Images decoding

Open CoffeeStraw opened this issue 4 years ago • 4 comments

Be able to convert small images (like 150x150) to pixels could be used to reduce a lot of effort in manually producing shapes, boosting productivity. There are a lot of libraries in Python that could help in this task, like Pillow.

CoffeeStraw avatar Feb 01 '20 17:02 CoffeeStraw

Additionally a reduction of output shapes by vectorization of (raster) images would be appreciated. If images aren't for particle effects, every bit of less subtitle code has a lot worth for generation time and render performance - especially because most are simple drawings for main audience "anime".

Youka avatar Feb 01 '20 18:02 Youka

Back then there are two base scripts that we used to make KFX. One is ssa_pwaa_xd.pyc by Tenka Muteki:

ssa_pawaa_xd.zip

and another one is PyFX by 50119 which is MIA for a long time. It is actually based on ssa_pwaa_xd though.

PyFX.zip

This is an example script we created (use it with ssa_pwaa_xd): Clannad_OP.py

Hope they are useful for later references. Please note that they were legacy scripts and only work with Python 2.5.4 and below (with PIL installed).

Doko-Demo-Doa avatar Feb 14 '21 08:02 Doko-Demo-Doa

Thank you for your references. I've taken a look at them, but they're quite outdated and the code doesn't look that good...

Using PIL, this is quite an easy task to do in Python 3. I will surely like to have this implemented to let users do not use directly PIL, but we have other priorities right now (still, PRs are always well seen!).

CoffeeStraw avatar Feb 14 '21 23:02 CoffeeStraw

Additionally a reduction of output shapes by vectorization of (raster) images would be appreciated.

Probably, we could use the project pypotrace to import this feature. I still have to further investigate on it.

CoffeeStraw avatar Apr 12 '21 10:04 CoffeeStraw