This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/index.js b/lib/index.js | |
index c05ed36..e4b0e07 100644 | |
--- a/lib/index.js | |
+++ b/lib/index.js | |
@@ -8,7 +8,37 @@ var auth = require("./auth"); | |
var util = require("./util"); | |
var Metadata = require('./metadata'); | |
var async = require('async'); | |
-var xmlutil = require('xml2json'); | |
+var xml2js = require('xml2js'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func getSampleRate() { | |
var session: AVAudioSession = AVAudioSession.sharedInstance() | |
var audioSessionError: NSError? | |
session.setCategory(AVAudioSessionCategoryPlayback, error:&audioSessionError) | |
if (audioSessionError != nil) { | |
println("Error \(audioSessionError?.code), (audioSessionError?.localizedDescription)") | |
} | |
var bufferDuration = NSTimeInterval(0.005) | |
session.setPreferredIOBufferDuration(bufferDuration, error:&audioSessionError) |