Comparing version 1.0.0 to 1.1.0
@@ -205,2 +205,16 @@ (function() { | ||
//~api~ | ||
//---- | ||
//### .timetagToTimestamp(timeTag) | ||
// Convert a timetag array to the number of seconds since the UNIX epoch. | ||
// | ||
exports.timetagToTimestamp = utils.timetagToTimestamp; | ||
//~api~ | ||
//---- | ||
//### .timestampToTimetag(timeStamp) | ||
// Convert a number of seconds since the UNIX epoch to a timetag array. | ||
// | ||
exports.timestampToTimetag = utils.timestampToTimetag; | ||
}).call(this); |
@@ -140,2 +140,8 @@ // Generated by CoffeeScript 1.10.0 | ||
exports.timetagToTimestamp = function(timetag) { | ||
var seconds; | ||
seconds = timetag[0] + exports.ntpToFractionalSeconds(timetag[1]); | ||
return seconds - UNIX_EPOCH; | ||
}; | ||
makeTimetag = function(unixseconds, fracSeconds) { | ||
@@ -142,0 +148,0 @@ var ntpFracs, ntpSecs; |
{ | ||
"name": "osc-min", | ||
"version": "1.0.0", | ||
"version": "1.1.0", | ||
"main": "lib/index", | ||
@@ -5,0 +5,0 @@ "author": { |
@@ -178,2 +178,12 @@ [![build status](https://secure.travis-ci.org/russellmcc/node-osc-min.png)](http://travis-ci.org/russellmcc/node-osc-min) [![Coverage Status](https://coveralls.io/repos/russellmcc/node-osc-min/badge.png?branch=master)](https://coveralls.io/r/russellmcc/node-osc-min?branch=master) [![dependencies](https://david-dm.org/russellmcc/node-osc-min.png)](https://david-dm.org/russellmcc/node-osc-min) | ||
---- | ||
### .timetagToTimestamp(timeTag) | ||
Convert a timetag array to the number of seconds since the UNIX epoch. | ||
---- | ||
### .timestampToTimetag(timeStamp) | ||
Convert a number of seconds since the UNIX epoch to a timetag array. | ||
---- | ||
## Javascript representations of the OSC types. | ||
@@ -180,0 +190,0 @@ See the [spec][spec] for more information on the OSC types. |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
121794
1227
263