How to use the ieee754.read function in ieee754

To help you get started, we’ve selected a few ieee754 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github perliedman / leaflet-underneath / dist / leaflet-underneath-src.js View on Github external
    readDoubleLE: function(pos) { return ieee754.read(this, pos, true, 52, 8); },
github petrosagg / papagal / src / vendor / buffer / index.js View on Github external
i.prototype.readFloatLE = function(e, t) {
        if (!t) {
            O(e, 4, this.length)
        };
        return K.read(this, e, true, 23, 4);
    };
    i.prototype.readFloatBE = function(e, t) {
github ShareIt-project / WebP2P.io / dist / WebP2P.js View on Github external
function _readFloat (buf, offset, littleEndian, noAssert) {
  if (!noAssert) {
    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')
    assert(offset + 3 < buf.length, 'Trying to read beyond buffer length')
  }

  if (browserSupport) {
    return buf._dataview.getFloat32(offset, littleEndian)
  } else {
    return ieee754.read(buf, offset, littleEndian, 23, 4)
  }
}
github cujojs / rest / util / _stream.js View on Github external
function _readFloat (buf, offset, littleEndian, noAssert) {
  if (!noAssert) {
    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')
    assert(offset + 3 < buf.length, 'Trying to read beyond buffer length')
  }

  return ieee754.read(buf, offset, littleEndian, 23, 4)
}
github cujojs / rest / util / _stream.js View on Github external
function _readDouble (buf, offset, littleEndian, noAssert) {
  if (!noAssert) {
    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')
    assert(offset + 7 < buf.length, 'Trying to read beyond buffer length')
  }

  return ieee754.read(buf, offset, littleEndian, 52, 8)
}
github BastianHofmann / vue-grid / build / grid.js View on Github external
function _readDouble (buf, offset, littleEndian, noAssert) {
  if (!noAssert) {
    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')
    assert(offset + 7 < buf.length, 'Trying to read beyond buffer length')
  }

  return ieee754.read(buf, offset, littleEndian, 52, 8)
}
github grz0zrg / fsynth / client / dist / worker / image_to_audio.js View on Github external
Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)
  return ieee754.read(this, offset, false, 23, 4)
}
github Lapple / ErrorBoard / node_modules / browserify / node_modules / buffer / index.js View on Github external
Buffer.prototype.readFloatLE = function (offset, noAssert) {
  if (!noAssert)
    checkOffset(offset, 4, this.length)
  return ieee754.read(this, offset, true, 23, 4)
}
github goodybag / mongo-sql / build / mosql.js View on Github external
function readDouble (buf, offset, littleEndian, noAssert) {
  if (!noAssert) {
    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')
    assert(offset + 7 < buf.length, 'Trying to read beyond buffer length')
  }

  return ieee754.read(buf, offset, littleEndian, 52, 8)
}
github grimmdude / MidiPlayerJS / browser / index.js View on Github external
Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) {
  offset = offset >>> 0
  if (!noAssert) checkOffset(offset, 8, this.length)
  return ieee754.read(this, offset, false, 52, 8)
}

ieee754

Read/write IEEE754 floating point numbers from/to a Buffer or array-like object

BSD-3-Clause
Latest version published 4 years ago

Package Health Score

67 / 100
Full package analysis

Popular ieee754 functions