blob: ab30728b93f41b1215ae88076992bd3b7f8cff87 [file] [log] [blame]
Kevin Lubickf3d6c362020-01-06 08:11:52 -05001CanvasKit._extraInitializations = CanvasKit._extraInitializations || [];
2CanvasKit._extraInitializations.push(function() {
3 CanvasKit.SkRuntimeEffect.prototype.makeShader = function(floats, isOpaque, matrix) {
4 var fptr = copy1dArray(floats, CanvasKit.HEAPF32);
5 // Our array has 4 bytes per float, so be sure to account for that before
6 // sending it over the wire.
7 if (!matrix) {
8 return this._makeShader(fptr, floats.length * 4, !!isOpaque);
9 }
10 return this._makeShader(fptr, floats.length * 4, !!isOpaque, matrix);
11 }
12});