Giter Club home page Giter Club logo

d1-graphics-tool's People

Contributors

ajenbo avatar glebm avatar lislib avatar pionere avatar savagesteel avatar tetektoza avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

d1-graphics-tool's Issues

Reproduce handling of TRNs in Diablo

In Diablo 1 when a TRN file is loaded, every value of 0xFF is set to zero. In order to reproduce the in-game result, it would be nice to apply this logic here as well.
This is not true for translations of unique monsters -> make it optional?

Add support for font .bin files

Font symbol width are contained in .bin files, they are simply 256 bytes, with each byte being the width of a single frame

Depends on #100 for PCX support

Width detection fails for certain (GFX) cl2 files

Width detection might fail for invalid/inconsistent cel/cl2 files, but the game might still handle it correctly.
At the moment the following files are affected in the vanilla game:

  • PlrGFX\Warrior\wlb\wlbat.CL2
  • PlrGFX\Warrior\wmb\wmbat.CL2
  • PlrGFX\Warrior\whb\whbat.CL2

Suggestion: make the width field editable. In case the value is changed to a valid integer, try to load the file with the given width, otherwise use the current heuristic.

LevelCelView: Changing height of tiles should be foolproof

Currently in LevelCelView, if we load level tiles to the GUI, we can set height of a tile, but if user feeds the line edit with any random number - it will take it, potentially freezing the app and making user to lose the progress.

My idea was to clip the value if it exceeds certain limit of height, for example 1000.

Talking specifically about this functionality:
image

MainWindow: Decouple/rename Palette menu

Currently "Palette" menu isn't named too accurately, it contains actions for Palette, Translation and Unique Translation, this probably needs some sort of decoupling and moving it to separate menus OR renaming current "Palette" menu to something that by name would unify all those actions. Then, after this menu is renamed, a good idea would be to make separate menus nested in this menu, each one separately for Pallete, Translation and Unique Translation, and then all those actions that are available (for Palette, Translation and Unique Translation) right now could be moved into those menus.

Add support for loading frames from png/bmp/pcx/gif

This would be needed as part of adding support for converting graphics in to the formats supported by the game.

It's not required that all 4 formats be supported. They are just the 4 most relevant formats
bmp is used by The Dark Graphics
png is pngs2cel and widely supported by other tools
pcx is used by various Diasurgical tools and the common format used by Diablo (menus)
gif is was evidently used originally (see l4data/*.gif) and has a fitting spec (256 color animated)

Prebuild Linux binery

Hey @savagesteel the situation with Qt6 on Linux has gotten a lot better. 6.2.4 is available on Ubuntu since 21.10.

As such it's now possible to create a .deb install file that depends on it for a minimal installation size.

Attached is a build of the latest master (no changes), I also added an application short cut for it (using the .svg file as the icon).

d1-graphics-tool-0.5.0.zip

I tested the package on Ubuntu 22.04 LTS with a clean install in a VM

image

The additional dependencies (fetched form the official Ubuntu repo) is pretty manageable:

Need to get 9,516 kB of archives.
After this operation, 33.3 MB of additional disk space will be used.

(worst case senario, if no other Qt6 apps are installed)

Hope this is helpful :)

Use of CEL decoding in DGEngine

Hi there,

First of all, this is a really nice tool.

I'm the author of DGEngine (https://github.com/dgengin/DGEngine) and I have written a new implementation for CEL/CL2 decoding based on this project (which is more accurate than the one I was using before) that I would like to integrate with DGEngine. I modified it not to use QT related classes, etc.

I would like to know if it's OK to do so and if I can keep using the ZLib license, since your project uses GPL which is incompatible.

Update: I have committed the new CEL decoder code today (22/04/2018). Let me know if you have any objection.

Regards,
DGEngine author

EditMenu: Rename all "Add" QAction instances to "Append" or create another nested menu called "Add"

Currently, if we go to Edit -> Frame/Tile/Megatile menu, we have two options - Insert and Add. Insert is already an "Add" option (it adds frames/tiles/megatiles but before the current), and the "Add" option is differentiated in the source code as "Append", and it acts as append - it appends the image that user wants to insert to the end of the list. In my opinion, this should be renamed

OR

those two options could be added in another nested submenu, called "Add", so then this would go like this, for example in Frame submenu:

Edit -> Frame -> Add -----> Insert
                     \
                      \---> Append

Then do the same for Tile/Megatile.

Add clone tile/sub-tile

It should be possible select "Clone tile" from the edit menu to copy the current tile to a new one.

This would allow for more easily adding variants of existing tiles

Consider parsing MIN files to determine the correct CEL frame type

@savagesteel Very happy and excited to see that you've been working on a range of Diablo 1 related projects! As @dgengin has now incorporated a CEL decoder based on https://github.com/savagesteel/d1-graphics-tool, it would be great to ensure that its output is correct in 100% of the cases (this may already be the case today, even based on heuristics). Even still, I'll present my case for moving towards a CEL frame type lookup table based approach for parsing CEL images, with lookup tables automatically generated by parsing MIN files.

The current CEL decoder implementation relies on heuristics to determine which CEL type a specific frame is.

For instance, one heuristic employed is to determine if a set of bytes are zero at specified offsets (e.g. https://github.com/savagesteel/d1-graphics-tool/blob/master/source/d1cel.cpp#L39). Another is to parse a frame of size 0x400 using regular CEL decoding to determine whether the number of decoded pixels correspond to a 32x32 image.

While both of these heuristics are unlikely to fail, it would be preferable to not have to rely on heuristics all together.

For background and reference implementations: https://github.com/mewrnd/blizzconv/blob/master/images/cel/decode.go was based on similar (although less reliable heuristics), and decoding tables generated by parsing MIN files was determined to be more reliable as incorrectly decoded frames were discovered.

Hope to hear from you and get to know your thoughts.

Cheerful regards,
/u

Replacing a tile wipes the tile properties

When replacing the graphics for a tile it's properties are reset.
This makes adding new graphics very tedious as you have to remember all flags and reapply them manually

image
Expected:
image

Feature Request: open level CEL via MIN file

Currently the only way to open a level-CEL file is to select an existing CEL file and let the program guess its type.
This works for the existing level-CEL files, but prevents the user from experimenting with new assets, because D1Cel::load expects at least 512 matching (trapezoid, triangle or square) entries before D1CEL_TYPE::V1_LEVEL is set.
Since this approach is quite ad hoc (the new assets might have no such entries at all) and requires a huge amount of assets up-front, it would be nice to have an option to open MIN files directly.

order of translations (TRN)

At the moment the handling of multiple translations is unintuitive, because the user has to select the translations in reversed order.
For example in case of "Shadowdrinker" (where the "Monsters\SkelSd\SklSr*.CL2" file is used with "Levels\L2Data\L2_*.pal") the base translation is "Monsters\SkelSd\Black.TRN" from the monster-type and the unique translation is "Monsters\Monsters\SHDR.TRN". To recreate the look in the game, the SHDR.TRN has to be set as "Translation 1", while the Black.TRN must be the "Translation 2".

I tried to change the order of D1Trn entities in my branch, but the update order would have to be updated as well. The result would be an unnecessary complicated code so maybe a simpler approach would be preferred.
E.g. re-label the fields to "Base Translation"/"Unique Translation", or change the order on the gui, or add some tooltip, or just leave it as it is. Or maybe you have a better idea?

PS: this is a very useful tool.

View SOL attributes for level tile pices

The .sol format is a simple set of flags that informs the engine what attributes a tile piece has.

Each byte in the file is a bit flag corresponding to the tile of the same number as the byte.

  • 0x01 Solid
  • 0x02 Blocks light
  • 0x04 Blocks missiles
  • 0x08 Transparent
  • 0x10 Left masked arch
  • 0x20 Right masked arch
  • 0x40 Unused
  • 0x80 Can hold wall object

Note that once this is implemented my next request would be for an option to edit an save .sol, so probably use some checkboxes for displaying this info 😅

Error Launching

Can you reuplaod it? it doesn’t work when I download. Error when launched :(… for the latest patch 1.0.

Fix MSVCP140D.dll error.

I can't launch Software on windows. Even if I installed all redistributable packages.

From the web I seen :
The message of missing VCRUNTIME140D.dll is indicative of trying to run a debug binary on a machine that does not have the debug VisualC++ run time binaries installed. The VisualC++ debug run time is installed with Visual Studio. If you wish to run the binary on a different machine, please rebuild the project as Release.

Also, I tried previous build "0.5.0" this version run without problem.

Cant start it - Error - This application failed to start brcause no QT platform plugin could be inicialized.

Hello,
i cannot start the tool, i getting this error:
This application failed to start brcause no QT platform plugin could be inicialized.

I tried multiple Win10 machines, Win 7 machien and WinXP 32 bit machine, its nothing working only of them.

Version 0.0.3 is fine, but it has much more files that version 0.0.3.

I found newer version here:
https://github.com/Elidevin/Diablo-1-Graphics-Tool

But it has not possibility to add the issues.. I dunno how exactly are these project connected.

Add support for .amp files

AMP files contain cel level data for the automap based on tile indexes.

See develutionx for the format specs

Add support for CLX

DevilutionX uses a modefied .cl2 format called .clx. The only difference is that the header contains width and height instead of chunk offsets.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.