AkTuningTable proposal#860
AkTuningTable proposal#860marcus-w-hobbs wants to merge 4 commits intoAudioKit:developfrom marcus-w-hobbs:aktuningtable_proposal
Conversation
| override func setup() { | ||
| addTitle("Morphing Oscillator Bank") | ||
|
|
||
| let presets = ["Highland BagPipes", "Recurrence Relation 01", "Madhubanti", "Hexany 1,45,135,225", "Hexany 1,5,9,15"] |
There was a problem hiding this comment.
Line Length Violation: Line should be 120 characters or less: currently 125 characters (line_length)
| AKLog("playing \(note) at frequency:\(frequency)") | ||
| osc.play(noteNumber: note, velocity: 127, frequency:Float(frequency)) | ||
| } | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
| } | ||
| }) | ||
| } | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
| keyboard.polyphonicMode = false | ||
| keyboard.delegate = self | ||
| addSubview(keyboard) | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
| ) { multiplier in | ||
| osc.detuningMultiplier = multiplier | ||
| }) | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
| class PlaygroundView: AKPlaygroundView, AKKeyboardDelegate { | ||
|
|
||
| var keyboard: AKKeyboardView! | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
| AKPolyphonicNode.tuningTable.twelveToneEqualTemperament() | ||
|
|
||
| class PlaygroundView: AKPlaygroundView, AKKeyboardDelegate { | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
|
|
||
| var keyboard: AKKeyboardView! | ||
|
|
||
| override func setup() { |
There was a problem hiding this comment.
Function Body Length Violation: Function body should span 40 lines or less excluding comments and whitespace: currently spans 59 lines (function_body_length)
| case "Hexany 1,45,135,225": | ||
| AKPolyphonicNode.tuningTable.scalaFile("hexany_1_45_135_225.scl") | ||
| case "Hexany 1,5,9,15": | ||
| AKPolyphonicNode.tuningTable.hexany(1,5,9,15) |
There was a problem hiding this comment.
Comma Spacing Violation: There should be no space before and one after any comma. (comma)
| open override func play(noteNumber: MIDINoteNumber, velocity: MIDIVelocity) { | ||
| internalAU?.startNote(noteNumber, velocity: velocity) | ||
| // Function to start, play, or activate the node at frequency | ||
| open override func play(noteNumber: MIDINoteNumber, velocity: MIDIVelocity, frequency:Float) { |
There was a problem hiding this comment.
Colon Violation: Colons should be next to the identifier when specifying a type and next to the key in dictionary literals. (colon)
| open override func play(noteNumber: MIDINoteNumber, velocity: MIDIVelocity) { | ||
| internalAU?.startNote(noteNumber, velocity: velocity) | ||
| // Function to start, play, or activate the node at frequency | ||
| open override func play(noteNumber: MIDINoteNumber, velocity: MIDIVelocity, frequency:Float) { |
There was a problem hiding this comment.
Colon Violation: Colons should be next to the identifier when specifying a type and next to the key in dictionary literals. (colon)
| <page name='Telephone'/> | ||
| </pages> | ||
| </playground> No newline at end of file | ||
| <playground version='6.0' target-platform='ios' display-mode='rendered'/> No newline at end of file |
There was a problem hiding this comment.
Can you revert this change? Good to have the pages in there and it looks like your Xcode just accidentally bashed this.
There was a problem hiding this comment.
For sure...Trying to figure out how to revert this change only.
manually reverting the clobbering of contents
| internalAU?.startNote(noteNumber, velocity: velocity) | ||
| // Function to start, play, or activate the node at frequency | ||
| open override func play(noteNumber: MIDINoteNumber, velocity: MIDIVelocity, frequency:Float) { |
There was a problem hiding this comment.
Colon Violation: Colons should be next to the identifier when specifying a type and next to the key in dictionary literals. (colon)
| /// Function to start, play, or activate the node, all do the same thing | ||
| open override func play(noteNumber: MIDINoteNumber, velocity: MIDIVelocity) { | ||
| internalAU?.startNote(noteNumber, velocity: velocity) | ||
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
| } | ||
| } | ||
| } | ||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
|
|
||
| fileprivate var waveform: AKTable? | ||
|
|
||
|
|
There was a problem hiding this comment.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
|
|
||
|
|
||
| open var waveform: AKTable? { | ||
| //TODO: Add error checking for table size...needs to match init() |
There was a problem hiding this comment.
Todo Violation: TODOs should be avoided (Add error checking for table s...). (todo)
|
I manually merged this |
Hi Aure,
New in this pull request:
Modified subclasses of AKPolyphonicNode to use AKTuningTable as default noteOn implementation.
Frequency from AKTuningTable is passed to C++/Soundpipe as a new noteOn function with frequency parameter.
Ideally should have no impact to existing users of AudioKit.
Added Scala file support to AKTuningTable.
I started adding a Microtonal playground page under Synthesis.