microsoft-ui-xaml icon indicating copy to clipboard operation
microsoft-ui-xaml copied to clipboard

CueStyler: Fix outline rendering of TimedTextCue elements

Open softworkz opened this issue 1 year ago • 6 comments
trafficstars

The current method of simulating text outlines is wrong in the way how the visuals are offset in diagonal directions.

Also, the number of visuals for simulating the effect is insufficient for creating an acceptable appearance.

I will follow up with some comparisons.

softworkz avatar Jan 11 '24 01:01 softworkz

Comparison 1: Large Outline Values

Current Implementation

image

This PR but with 8 Iterations

image

This PR but with 16 Iterations

image

This PR (using 32 Iterations)

image

softworkz avatar Jan 11 '24 01:01 softworkz

Comparison 2: Smaller Outlines, Bold and Rounded Font

Current Implementation

image

This PR but with 8 Iterations

image

This PR but with 16 Iterations

image

This PR (using 32 Iterations)

image

softworkz avatar Jan 11 '24 01:01 softworkz

Comparison 2b: Same as 2 but scaled to 200%

Current Implementation

image

This PR but with 8 Iterations

image

This PR but with 16 Iterations

image

This PR (using 32 Iterations)

image

softworkz avatar Jan 11 '24 02:01 softworkz

Further improvement would be to:

  • Remove the alpha component from the outline color before setting it on the elements
  • Put all outline elements into a common container
  • Set the alpha value of the outline color as opacity on that common container
  • This will also allow to implement TimedTextStyle.OutlineRadius (which is currently ignored) by applying a blur effect to that common container

softworkz avatar Jan 11 '24 03:01 softworkz

@bpulliam - What does the removal of the "needs-triage" label mean? What is the outcome of your triage?

softworkz avatar Mar 07 '24 08:03 softworkz

@bpulliam Could this PR be reviewed please?

MartyIX avatar Apr 14 '24 20:04 MartyIX