Works with webgl1 and 2.