DragonMoffon / lux-aenigma

A short light-based puzzle game built with Python Arcade
0 stars 0 forks source link

Feature Request: Photosensitivity warning #2

Open pushfoo opened 6 months ago

pushfoo commented 6 months ago

TL;DR: Add a pre-game warning for photosensitive epilepsy

@DigiDuncan showed the progress on lights and shaders over screen-share. It was amazing, but the flashing lights immediately raised a concern about epilepsy.

There are two options that come to mind:

  1. (Easiest Option) Easy option: photosensitive epilepsy warning
  2. Hard option: shader-based anti-flash approach

For the shader-based approach, it seems like filtering out 12-15HZ flashes may be important, especially in the red band [1]. I'm not sure how to implement that, especially on the GPU side. I know @DragonMoffon mentioned GPU-side FFTs, so maybe it's worth finding or implementing something which operates on a downscaled screen representation to save VRAM?

Note that certain patterns may also affect individuals more or less:

Certain individuals are born with special sensitivity to flashing lights or contrasting visual patterns, such as stripes, grids and checkerboards. Because of this condition, their brain will produce seizure-like discharges when exposed to this type of visual stimulation.

This means that even flat texture-rendering modes for accessibility may cause problems if they flicker. [2] Given that the game is real-time, this presents complexity.

Works Cited (Skipping APA because this is GitHub):

  1. Pocket Monster incident and low luminance visual stimuli: Special reference to deep red flicker stimulation, https://onlinelibrary.wiley.com/doi/10.1111/j.1442-200X.1998.tb02006.x
  2. Shedding Light on Photosensitivity, One of Epilepsy's Most Complex Conditions: https://www.epilepsy.com/stories/shedding-light-photosensitivity-one-epilepsys-most-complex-conditions-0