Skip to content

Commit

Permalink
Fixed Alpha reset (regression in 1.0.5)
Browse files Browse the repository at this point in the history
  • Loading branch information
Vitaly Puzrin committed Nov 18, 2014
1 parent 24a8a51 commit d65ed9c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions dist/pica.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* pica 1.0.6 nodeca/pica */!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.pica=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({"./":[function(require,module,exports){
/* pica 1.0.7 nodeca/pica */!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.pica=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({"./":[function(require,module,exports){
'use strict';

/*global window:true*/
Expand Down Expand Up @@ -480,7 +480,7 @@ function convolveVertically(src, dest, srcW, srcH, destW, filters) {

function resetAlpha(dst, width, height) {
var ptr = 3, len = (width * height * 4)|0;
while (ptr < len) { dst[ptr] = 0xFF; ptr += (ptr + 4)|0; }
while (ptr < len) { dst[ptr] = 0xFF; ptr = (ptr + 4)|0; }
}


Expand Down
4 changes: 2 additions & 2 deletions dist/pica.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/pure/resize.js
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ function convolveVertically(src, dest, srcW, srcH, destW, filters) {

function resetAlpha(dst, width, height) {
var ptr = 3, len = (width * height * 4)|0;
while (ptr < len) { dst[ptr] = 0xFF; ptr += (ptr + 4)|0; }
while (ptr < len) { dst[ptr] = 0xFF; ptr = (ptr + 4)|0; }
}


Expand Down

0 comments on commit d65ed9c

Please sign in to comment.