Sha256: f6c5af919ff18e5b3696da3e7a49ea3a30a55370ca7720f2f9249ac3114badc5

Contents?: true

Size: 289 Bytes

Versions: 5

Compression:

Stored size: 289 Bytes

Contents

'use strict';

function isPSD (buffer) {
  return ('8BPS' === buffer.toString('ascii', 0, 4));
}

function calculate (buffer) {
  return {
    'width': buffer.readUInt32BE(18),
    'height': buffer.readUInt32BE(14)
  };
}

module.exports = {
  'detect': isPSD,
  'calculate': calculate
};

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
ilog-0.4.1 node_modules/image-size/lib/types/psd.js
ilog-0.4.0 node_modules/image-size/lib/types/psd.js
ilog-0.3.3 node_modules/image-size/lib/types/psd.js
less-execjs-2.6.0.4 lib/less/js/image-size/lib/types/psd.js
less-execjs-2.6.0.3 lib/less/js/image-size/lib/types/psd.js