Add a pixel shading tool #85

Closed
aseprite-bot opened this Issue Aug 20, 2014 · 6 comments

Comments

Projects
None yet
3 participants

From anasion....@gmail.com on March 02, 2012 21:22:01

What do you need to do? Shading tool

A tool for adding midtones/highlights to the canvas How would you like to do it? Add another brush option

Original issue: http://code.google.com/p/aseprite/issues/detail?id=85

Tasks:

  • Simple shading mode (added in v1.1.0.1)
  • X key should swap the whole gradient (related in someway with #854)
  • Drag-and-drop colors in the Shading bar/widget
  • Store previous gradients in a combo-box so we can easily re-select them
  • Load/Save shades between sessions

dacap added this to the v1.1 milestone Aug 31, 2014

I think, more than a tool this feature could be implemented using a drawing mode to be able to use it with the existing the pencil, box and circle tools.

Since you have to pre-define a gradient or ramp beforehand anyways, you could automatically go into that mode when that gradient is selected.
You want the highlights or shadings to be taken from a predefined ramp to get the results you expect, so that would be a core requirement for this. A way to order the ramp manually would also be fairly important to get the expected results.

In our conversation you mentioned a bucket, which i assume is some sort of split area in the palette panel? This could work fairly well!

Highlighting should work through the use of the left mouse button, while the right mouse would shade, moving the index within the ramp up or down accordingly.

Owner

dacap commented Feb 17, 2015

could be implemented using a drawing mode

Sure! Indeed there is already some (commented) code. Also I think there were some 1.0 beta (0.9.6) that included a Shading mode in the combobox where "Default / Set Alpha / Lock Alpha" ink

you could automatically go into that mode when that gradient is selected.

That's a good idea.

some sort of split area in the palette panel?

Exactly.

Highlighting should work through the use of the left mouse button, while the right mouse would shade, moving the index within the ramp up or down accordingly.

👍

@dacap dacap added high priority and removed medium priority labels Aug 5, 2015

dacap self-assigned this Aug 26, 2015

Owner

dacap commented Aug 26, 2015

Fixed

dacap closed this Aug 26, 2015

@dacap dacap added a commit that referenced this issue Aug 27, 2015

@dacap dacap Add shading ink (fix #85) f3ac563

Great work so far. Works as well as expected!
Let me express few desires and suggestions in terms of workflow and usability:

Using Left/Rightclick to move the ramp up and down works well with a mouse, however it proves to be difficult when using a stylus. Having a button(hotkey e.g. x like the color left/right flip) to flip the order of the selected color ramp so you can remain using the stylus would be a great improvement.

I found it weird that the shading tool works only on any of the colors in the ramp.
It would be cool to get a check box so it also works on any color/transparency, where it starts with either end of the ramp, depending on which direction you start from (left/right).

The selection of colors are always sorted in order of the color index instead of the color selection order, which makes it difficult to get the color progression you want. It would be appreciated if you could drag-drop/rearrange the colors in the selected ramp to get the progression how you like it.

When working with different custom ramps in one image it can be quite the hassle to either sort the palette so the selection is lined up (if at all possible) or to reorder/rearrange the palette every time you want to change your ramp. For that it would be good to have drop down history on the ramp you can select previously created ramps (either saved per .ase or palette file)

Thanks for the great work. Really love the feature so far <3

Owner

dacap commented Sep 2, 2015

Using Left/Rightclick to move the ramp up and down works well with a mouse, however it proves to be difficult when using a stylus. Having a button(hotkey e.g. x like the color left/right flip) to flip the order of the selected color ramp so you can remain using the stylus would be a great improvement.

I was thinking that in Shading mode, X key could swap the whole gradient.

I found it weird that the shading tool works only on any of the colors in the ramp.
It would be cool to get a check box so it also works on any color/transparency, where it starts with either end of the ramp, depending on which direction you start from (left/right).

The good thing about the current mode is that you can be safe that colors that aren't in the gradient aren't modified. One question, in this new mode, if I press left key above a color outside the gradient, do I paint with the right-most color in the gradient?

The selection of colors are always sorted in order of the color index instead of the color selection order, which makes it difficult to get the color progression you want. It would be appreciated if you could drag-drop/rearrange the colors in the selected ramp to get the progression how you like it.

👍 It's planned but didn't make the first version of the shading widget.

When working with different custom ramps in one image it can be quite the hassle to either sort the palette so the selection is lined up (if at all possible) or to reorder/rearrange the palette every time you want to change your ramp. For that it would be good to have drop down history on the ramp you can select previously created ramps (either saved per .ase or palette file)

👍 I thought exactly same but it wasn't included in the final release. It's probably related to #787

dacap reopened this Sep 2, 2015

I was thinking that in Shading mode, X key could swap the whole gradient.

Excellent!

if I press left key above a color outside the gradient, do I paint with the right-most color in the gradient?

Yeah, I'd imagine it starts on the right most color and works its way up, and vice versa for the right click respectively.

In fact i personally find it confusing that left click works from right to left side in the gradient. even if left/right click coincides with the direction on the gradient, i'd imagine it more like left click works forward on the gradient. it feels more intuitive to me if the default action works left to right. it doesn't really matter with the x-swap though.

@dacap dacap added a commit that referenced this issue Nov 20, 2015

@dacap dacap Switch shading colors with X key
Related to #85 and #854
e683b8f

@dacap dacap added a commit that referenced this issue Nov 24, 2015

@dacap dacap Convert InkShadesField in a combobox-like widget to store several sha…
…des (#85)

Changes:
* Added new ui::IconButton widget to create widgets with one skin icon
  that is colored depending on the button state.
* ContextBar::InkShadesField was divided into a couple widgets (ShadeWidget
  and IconButton to drop-down a little menu with saved shades)
* Fixed CommonLockedSurface::drawColoredRgbaSurface() impl.
* Removed invalid gfx::setr/g/b/a() functions.
cf7c475

dacap closed this in 8a7a585 Nov 25, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment