David Capello
a7ea0f7ec5
Add "Snap to Grid" indicator when it's enabled ( fix #122 )
2015-07-28 13:05:59 -03:00
David Capello
9e5ccbcca9
Remove StatusBar color names in status_bar.cpp
2015-07-28 12:25:15 -03:00
David Capello
0898d685c2
Fix minor UI bug in the initial ContextBar::TransparentColorField state
2015-07-28 11:14:12 -03:00
David Capello
58db0fba09
Fix bug clearing an Image with color=0 in rotsprite
...
Introduced in commit 35229e99a6196d71b90ef2762abb32b0a164f594
2015-07-28 11:06:35 -03:00
David Capello
8e2feb31bd
Implement LockAlphaInkProcessing for indexed images
2015-07-28 10:45:35 -03:00
David Capello
bee6baf812
Select faster ink (INK_COPY) when we use an opaque color and opacity = 255
2015-07-28 10:31:09 -03:00
David Capello
88c4cd8d87
Don't show brush boundaries when the brush & zoom are too small
...
We can use the CROSS brush preview type instead of BRUSH_BOUNDARIES
2015-07-28 10:21:33 -03:00
David Capello
a1dcb05a99
Add support to copy cels from Indexed <-> Indexed with different palettes
2015-07-27 13:31:19 -03:00
David Capello
bdbffc8e6c
Fix bug copying cels from Indexed to RGB sprites
2015-07-27 13:08:25 -03:00
David Capello
8f891a4e25
Add asserts to detect bugs adding cels w/pixel format != sprite's pixel format
2015-07-27 12:40:02 -03:00
David Capello
5a5579973c
Add missing palette parameter to render::composite_image()
...
This is needed when we copy a cel (or cel range) from an Indexed image
to an RGB image.
2015-07-27 12:24:54 -03:00
David Capello
41bb23f1f1
Change opaque/transparent selection by default depending on the layer
2015-07-27 11:43:48 -03:00
David Capello
bc29cd4bc5
Set alpha compositing as default
...
And "replace pixel" and "set alpha" were merged into "copy color" ink.
2015-07-27 11:24:00 -03:00
David Capello
940dd5f45c
Fix alpha compositing on background layer using colors with alpha < 255
2015-07-27 10:53:02 -03:00
David Capello
0f38a7dace
Don't use the ColorBar bg color when Background is visible in Flatten
2015-07-27 08:34:05 -03:00
David Capello
64ae80f0d3
Remove some TODO items
2015-07-27 08:21:51 -03:00
David Capello
02d0d7203a
Show background layer after Flatten command
2015-07-27 08:20:15 -03:00
David Capello
ea09ada11b
Add custom clipboard format on Win32 to copy/paste image+mask+palette
2015-07-26 19:07:51 -03:00
David Capello
c5f898e6a7
Fix compilation error resolving doc::color_t type in gcc and clang
2015-07-23 22:52:49 -03:00
David Capello
35229e99a6
Add opaque/transparent mode in context bar for transformations ( fix #546 )
...
With this change now we add a "mask" image/parameter in rotation
functions. In this way we can identify which specific pixels are
inside the original mask/selection, and in opaque mode we can
include/scale/rotate all those pixels inside the mask, whatever
value they are, even if they are the mask color.
Fixes #730
2015-07-23 22:42:14 -03:00
David Capello
ba4c34a70f
Add options to sort the palette by RGBA channels
2015-07-23 11:13:43 -03:00
David Capello
6aeee0b8fa
Show opacity when brush is an image (ignoring the ink type)
2015-07-23 10:43:16 -03:00
David Capello
66ddc62a76
Add an option to share ink/opacity parameters between all tools
2015-07-23 10:07:07 -03:00
David Capello
692a4cf009
Include layer opacity on merge down command
2015-07-23 09:19:08 -03:00
David Capello
ce7c34bb72
Avoid 32-bit integer overflow in median cut algorithm ( fix #727 )
...
This fixes a problem generating invalid RGBA entries for an optimized
palette. (E.g. Generating non-opaque pixels when we feed the algorithm
only with opaque pixels.)
2015-07-23 09:05:48 -03:00
David Capello
dd0a6d6a40
Make minor changes in color_histogram.h and median_cut.h
2015-07-23 08:52:37 -03:00
David Capello
5f44ac9d25
Remove unused dithering property in GifOptions
2015-07-23 06:50:08 -03:00
David Capello
b35fc87ec1
Add progress bar when a palette is created from a RGB file
2015-07-22 18:26:25 -03:00
David Capello
96080a378c
Remove frameNum from GifEncoder::writeLoopExtension()
2015-07-22 17:41:14 -03:00
David Capello
e71fd36c24
Fix gif_format.cpp compilation on Linux and with giflib 4
2015-07-22 17:30:11 -03:00
David Capello
7f4d4936e1
Re-implement GIF encoder
...
- Correct usage of disposal methods (and possibility to generate records
with "restore previous frame" disposal method)
- Create color maps for each frame when necessary
- Remove options to dither RGB images (to simplify encoder)
2015-07-22 16:40:44 -03:00
David Capello
91988de955
Remove unused function create_palette_from_images()
2015-07-22 14:31:59 -03:00
David Capello
8fbf0854b0
Fix layout bug when a file cannot be opened from the recent list in HomeView
2015-07-22 13:14:41 -03:00
David Capello
cee355ee61
Fix minor layout issues in the Preferences dialog
2015-07-18 13:29:23 -03:00
David Capello
65fe7dbccf
A GIF color map cannot have more than 256 colors
2015-07-17 12:57:32 -03:00
David Capello
ae2f04f855
Fix creation of local colormaps in GifFormat::onSave()
2015-07-17 12:45:59 -03:00
David Capello
cb867b7f84
Re-implement GIF decoder to load some .gif files correctly ( fix #729 )
...
- Better palette creation depending on local colormaps
- Reuse palette colors from previous frames
- Use frame transparent index correctly
- Convert to RGB automatically if the image has more than 256 colors
- Remove onPostLoad()
- Add progress bar feedback
2015-07-17 12:26:11 -03:00
David Capello
065825c373
Change DisposalMethod type to enum class
2015-07-15 17:13:37 -03:00
David Capello
5036ffd738
Change the message to convert a GIF file to RGB on GifFormat::onPostLoad
2015-07-15 16:50:47 -03:00
David Capello
37478688c0
Fix problem loading gif files using subset of the original color map ( fix #729 )
...
There are gif files that use a subset of the original color map remapping
used entries into first indexes. E.g. the main palette contains 256 colors,
but then a frame can use 4-bit per pixel to reference 16 colors from the
original 256 color palette.
2015-07-15 15:42:54 -03:00
David Capello
008dceb55d
Replace iterators with range-based loop in gif_format.cpp
2015-07-15 15:09:07 -03:00
David Capello
b426171679
Add new_mask_color parameter to convert_pixel_format() function
...
When we converted an Indexed image to RGB, the original sprite
transparent color was being kept but the mask color of all its images
was reset to 0. With this change we kept the same mask color on all images
to avoid an assert() in the render code.
Anyway the whole RGB <-> Indexed conversion should be reviewed in these
cases. I think there are some situation where a transparent color = 0 is
expected in RGB sprites (as we shouldn't be able to change the transparent
color of an RGB sprite).
2015-07-14 09:44:31 -03:00
David Capello
accc0e7942
Fix conversion from Indexed to RGB when multiple palettes are present ( fix #726 )
2015-07-14 08:23:26 -03:00
David Capello
af9d5c917f
Keep the relative order of equal entries in sort_palette()
2015-07-14 07:47:22 -03:00
David Capello
cdc7ab32fc
Merge branch 'link-fixes'
2015-07-13 22:22:29 -03:00
David Capello
7281ef1467
Include Allegro flags in PLATFORM_LIBS when the shared version is used
2015-07-13 13:02:34 -03:00
David Capello
e4138fdf69
Fix order of target_link_libraries() for tests
...
Generic libraries at the end.
2015-07-13 13:01:48 -03:00
David Capello
55f90d8b8b
Add target_link_libraries() for sublibraries
...
With this change we remove some internal variables/lists like sys_libs,
libs3rdparty, etc. And we fix dependencies problems between targets.
2015-07-13 12:16:55 -03:00
David Capello
420b38e426
Fix HSV Alpha slider in Palette Editor when only one entry is selected
2015-07-10 17:37:09 -03:00
David Capello
3dcffc828d
Fix crash on Linux with the new mouse callback introduced in PR #709
...
The callback is called when the unique_display is null, or display
scale is == 0.
2015-07-09 15:08:05 -03:00