sandflow / imscJS

JavaScript library for rendering IMSC Text and Image Profile documents to HTML5
BSD 2-Clause "Simplified" License
83 stars 31 forks source link

Add presentation customisation options #256

Open nigelmegitt opened 5 months ago

nigelmegitt commented 5 months ago

Some players want to provide customisation adjustments to modify the appearance of the rendered subtitles. Add a mechanism for doing this.

I suggest basing this on bbc/imscjs#2 which adds an optional options parameter to imscHTML.render().

Color customisation can be quite complex. I have some experimental code that separates out the concept of matching a color or a range of colors from the resulting action to take to modify the color, so that it can be extended. For example, rotating the hue around a color circle, adjusting the saturation or brightness, simply replacing one color with another, etc. are all potential options.