Ticket #569 (closed enhancement: fixed)

Opened 7 years ago

Last modified 7 years ago

Customizable alpha threshold value for outlines / outlining

Reported by: ChrisOelmueller Owned by: FIFE
Priority: normal Milestone: 0.3.3
Component: engine/core/view Version: trunk
Severity: normal Keywords:
Cc: Blocked By:
Blocking: Time planned:
Time remaining: Time spent:


Over at UH, we have some assets with pixels of alpha 254 or a bit lower (due to the rendering).

When a player selects them, we display a unit outline by default. This outline highlights all pixels with alpha != 255, which looks pretty awful and really noisy.

As a client, we would like to have a customizable value. The check in question is found at instancerenderer.cpp:445

<helios2k> an adjustable value of alpha would make sense. I did the same for instance picking
<vtchill> so you want the client to be able to select the alpha value for testing?
<kozmo> yep, currently its addOutline(instance, r,g,b,width)
<vtchill> hmm can they set the alpha test in another way not connected to outline... it may be used for other purposes in the future
<kozmo> (instancerenderer.cpp:445) if ((a == 0 || prev_a == 0) && (a != prev_a)) { just need to make 0 configurable with 0 being default
<helios2k> most of our functions have a optional alpha (if they have r,g,b)
<vtchill> i see so its just filtering the alpha without letting the client specify it
<vtchill> makes sense to pass in alpha into addOutline and store it then i think

Change History

comment:1 Changed 7 years ago by kozmo

(In [3740]) * Added new parameter for outlines - threshold with a default value of 1 (old behavior) refs #569

comment:2 Changed 7 years ago by kozmo

(In [3741]) * Customizable alpha threshold value for outlines - 2nd approach refs #569

comment:3 Changed 7 years ago by prock

  • Status changed from new to closed
  • Resolution set to fixed


Note: See TracTickets for help on using tickets.