phaser/wip/blendmodes/Phoenix.js
2018-01-25 15:48:33 +00:00

9 lines
235 B
JavaScript

/**
* Phoenix blend mode. This subtracts the lighter color from the darker color, and adds 255, giving a bright result.
*/
var Phoenix = function (a, b)
{
return Math.min(a, b) - Math.max(a, b) + 255;
};
module.exports = Phoenix;