Commit Graph

162 Commits

Author SHA1 Message Date
Panagiotis Georgiadis
0bdcdbfc49 [docs] Improve phrasing for Tileset image data length
Clarified the description for the data length field of the
compressed Tileset image when flag 2 is set.
2024-08-12 17:22:05 -03:00
David Capello
657e679461 Some extra comments to the coding style guide 2024-08-08 16:17:56 -03:00
David Capello
3c44831831 We can use = {} for default arg values in function declarations 2024-07-19 17:10:39 -03:00
David Capello
e48e71ba28 Update to tinyxml2 2024-04-22 18:28:03 -03:00
David Capello
10dda30a15 Don't write color2 chunk for files with more than 256 colors (fix #4322)
We were incorrectly saving a wrong number of entries for palettes with
more than 256 colors in color2 chunk, anyway it doesn't make sense to
use this chunks as it doesn't support more than 256 colors. So we
removed it for this case.

We've also removed the palette chunk for cases where it's not required
at all, e.g. when we have less than 256 colors and doesn't have alpha
channel, it makes sense to use the color2 chunk as it's smaller in the
output file.
2024-02-22 19:46:34 -03:00
David Capello
302d998218 Add support to match flipped tiles automatically in Auto/Stack modes
By default Aseprite will not try to match flipped versions of the
tiles (as it requires more CPU), but when we create a tileset we can
specify which flips can be matched automatically (new
Tileset::matchFlags() property).

These flags are just for the Auto mode, if we manually insert a
flipped tile, that is always supported, even when the matchFlags() are
not specified.
2023-11-09 16:44:46 -03:00
David Capello
d114b62483 New tile flags meaning (x/y/diagonal flip) + serialize then correctly
* Changed the "90cw" flag to "diagonal flip" (the tile should be
  rendered with X/Y axis switched in this case)
* Each time we read/write an .aseprite file we have to convert
  the mask/shift from the file to the values expected in
  memory (tile_f_xflip/yflip/dflip)
2023-11-09 16:44:46 -03:00
David Capello
5c41d96db3 Reword notes about compressed data in .aseprite specs (fix #3897) 2023-06-01 11:38:03 -03:00
Martín Capello
da80192d0f Add UUID type to user properties (fix #3810) 2023-05-08 17:13:34 -03:00
David Capello
dbfc7d745f Minor change to specs: put Notes in the table of content 2023-05-08 12:37:10 -03:00
David Capello
943f0df625 Add info about how to order layers depending on z-index in the specs 2023-05-08 12:14:45 -03:00
David Capello
24846eae10 Add z-index property to cels (fix aseprite/Attachment-System#88)
* Now a Cel has a z-index property to change the order of layers per frame
* A new doc::RenderPlan class can calculate the order of cels to be rendered
* z-index is saved as a int16_t in the .aseprite files
* This new field can be set/get from Lua with Cel.zIndex
2023-04-10 19:23:16 -03:00
David Capello
cbe62e09e3 Add note about size of chunks and properties on .aseprite specs 2023-02-22 17:11:37 -03:00
Martín Capello
8b547adfb7 Update vector spec to support mixed types of elements 2023-02-22 12:51:51 -03:00
David Capello
c70cb0d882 Minor rewording in the .aseprite specs 2023-02-16 17:20:12 -03:00
David Capello
64ce25fae2 Add property to disable the standard tilemap UI
Added a Sprite.tileManagementPlugin property for plugins that want to
replace the standard tilemap/tileset interface. This includes a new
external file field in .aseprite files to specify that the sprite
tiles are controlled by a specific plugin.

Once this property is set, the standard tilemap/tileset modes
selectors will disappear and the only way to make then available will
be setting this property to nil/empty string again.

Fix https://github.com/aseprite/Attachment-System/issues/21
2023-02-15 18:55:21 -03:00
David Capello
8f09728105 Merge branch 'custom-properties-serialization' (fix #3632, #3645) 2023-01-06 10:03:19 -03:00
David Capello
a0ddefb732 Remove note about "extension:" prefix in external files chunk 2023-01-05 16:28:47 -03:00
Martín Capello
03d66aa203 Introduce FLOAT and DOUBLE types 2023-01-05 15:30:45 -03:00
David Capello
d3aac6a1cd Add support for .qoi file format (fix #3121) 2023-01-05 14:23:01 -03:00
David Capello
84765c5052 Add several notes related to macOS 10.9 limitations 2023-01-05 10:21:50 -03:00
Martín Capello
243fbc3fbc Extend User Data Chunk to support custom properties 2023-01-03 16:59:26 -03:00
Martín Capello
9fef25a674 Clarify where the external files chunk is in the file 2023-01-03 13:18:05 -03:00
David Capello
4f96d37b1f Add repeat field to animation tags (#1275, #1740) 2022-10-19 12:25:06 -03:00
David Capello
4817f0a64b Merge branch 'main' into beta 2022-08-24 16:56:34 -03:00
David Capello
282328d6d6 Remove dependency with stringencoders library 2022-08-24 12:50:30 -03:00
David Capello
f8f925c634 Merge branch 'main' into beta 2022-07-13 19:49:03 -03:00
David Capello
4f2eae6b77 Use C++17 [[fallthrough]] if needed 2022-06-29 20:14:03 -03:00
David Capello
8f44b521b6 Merge branch 'main' into beta 2022-06-10 10:31:13 -03:00
David Capello
4471dab289 [osx] We cannot use std::optional::value() if we want to support macOS 10.9
It looks like value() member was introduced in macOS 10.13 (error
detected because we use CMAKE_OSX_DEPLOYMENT_TARGET=10.9).
2022-06-09 19:07:08 -03:00
David Capello
71d885d2a0 Replace base::clamp -> std::clamp as now we use C++17 2022-06-09 19:05:48 -03:00
David Capello
d077900fe5 Merge branch 'main' into beta 2021-10-13 10:15:39 -03:00
David Capello
d1e8552491 Add IXWebSocket license 2021-10-12 19:43:07 -03:00
David Capello
f318a42f19 Merge branch 'main' into beta 2021-09-29 10:16:02 -03:00
David Capello
8512ea6f98 Add Sentry license 2021-09-23 19:47:21 -03:00
David Capello
adc9c109da Merge branch 'main' into beta 2021-08-31 09:06:09 -03:00
David Capello
6d67d91335 Add note about const usage in coding style 2021-08-27 17:42:44 -03:00
David Capello
95e6b5ddd6 Update .aseprite file specs with v1.3 updates 2021-08-20 14:48:01 -03:00
David Capello
c42c5e1453 Backport new laf API to main branch of aseprite
Some features from the beta branch of aseprite & laf were backported
to the main branch of aseprite.

Related commits:
- New memory handling (db4504e816)
- New get event with timeout (e6ec13cc31)
- Convert os::NativeCursor to an enum (06a5b4f3ae)
- Adapt code to the new os::Display -> os::Window refactor (5d31314cdb)
- Save/load main window layout correctly and limit to current workarea (d6acb9e20f)
- Redraw window immediately on "live resizing" (d0b39ebade)
2021-07-05 17:51:29 -03:00
David Capello
d618bada49 Merge branch 'main' into beta 2021-06-04 13:31:51 -03:00
David Capello
d13f10212a Update broken link to compiler features (close #2677) 2021-05-29 10:59:35 -03:00
David Capello
694ec4a86c Merge branch 'main' into beta 2021-05-11 18:59:24 -03:00
David Capello
4c1a13bf07 More info about coding style 2021-05-04 18:32:38 -03:00
David Capello
80322af02e Use CityHash for tiles
This reduces the level of collisions between hash buckets between
different image tiles.
2021-04-19 15:56:47 -03:00
David Capello
289a6ab864 Merge branch 'master' into beta 2021-01-29 12:19:43 -03:00
David Capello
ffbe4863ca Minor fix in coding style guide 2021-01-14 12:45:32 -03:00
Gaspar Capello
5d70ba46a3 Add documentation about Sprite User Data 2020-12-17 10:42:32 -03:00
David Capello
a3286fc20a Minor refactor "first visible index" -> "base index" 2020-10-30 20:58:45 -03:00
David Capello
c2e5e69882 Simplify tilesets impl using tile index 0 = an empty tile
In this way we always have an empty tile available in the drawing
process. We've also added the Tileset::firstVisibleIndex field to
change the visible index of the tile 1 so we can offset the visible
number by the user (just as a visual aid / simulate old tilesets with
index=0=non-empty tile).
2020-10-30 16:33:34 -03:00
David Capello
bff884b4c8 Merge branch 'master' into beta 2020-10-22 12:18:30 -03:00