pitch class

- pitch class added to physical strips

prelim pester tests for potato pass
manual test for potato passes
- recallpreset()
This commit is contained in:
pblivingston 2025-12-07 14:52:20 -05:00
parent 2cf265b3b6
commit a5bade4fbb
4 changed files with 74 additions and 0 deletions

View File

@ -49,6 +49,14 @@ Recorder.FileType changed from method to write-only property
- StripAudibility class with Strip.Audibility.Knob - StripAudibility class with Strip.Audibility.Knob
- Strip.Denoiser.Threshold - Strip.Denoiser.Threshold
- Strip.VAIO - Strip.VAIO
- Strip.Pitch, StripPitch class
- on
- drywet
- pitchvalue
- loformant
- medformant
- hiformant
- recallpreset($presetIndex)
### Changed ### Changed

View File

@ -208,6 +208,21 @@ for example:
$vmr.strip[3].denoiser.knob = 5 $vmr.strip[3].denoiser.knob = 5
``` ```
#### pitch
The following strip.pitch commands are available:
- on: bool
- drywet: float, from -100.00 to 100.00
- pitchvalue: float, from -12.00 to 12.00
- loformant: float, from -12.00 to 12.00
- medformant: float, from -12.00 to 12.00
- hiformant: float, from -12.00 to 12.00
The following strip.pitch methods are available:
- RecallPreset($presetIndex) : int, from 0 to 7
#### audibility #### audibility
The following strip.audibility commands are available: The following strip.audibility commands are available:

View File

@ -78,6 +78,7 @@ class PhysicalStrip : Strip {
[Object]$eq [Object]$eq
[Object]$device [Object]$device
[Object]$audibility [Object]$audibility
[Object]$pitch
PhysicalStrip ([int]$index, [Object]$remote) : base ($index, $remote) { PhysicalStrip ([int]$index, [Object]$remote) : base ($index, $remote) {
AddFloatMembers -PARAMS @('color_x', 'color_y', 'fx_x', 'fx_y') AddFloatMembers -PARAMS @('color_x', 'color_y', 'fx_x', 'fx_y')
@ -88,6 +89,7 @@ class PhysicalStrip : Strip {
$this.comp = [StripComp]::new($index, $remote) $this.comp = [StripComp]::new($index, $remote)
$this.gate = [StripGate]::new($index, $remote) $this.gate = [StripGate]::new($index, $remote)
$this.denoiser = [StripDenoiser]::new($index, $remote) $this.denoiser = [StripDenoiser]::new($index, $remote)
$this.pitch = [StripPitch]::new($index, $remote)
$this.audibility = [StripAudibility]::new($index, $remote) $this.audibility = [StripAudibility]::new($index, $remote)
$this.eq = [StripEq]::new($index, $remote) $this.eq = [StripEq]::new($index, $remote)
$this.device = [StripDevice]::new($index, $remote) $this.device = [StripDevice]::new($index, $remote)
@ -155,6 +157,21 @@ class StripDenoiser : IRemote {
) )
} }
class StripPitch : IRemote {
StripPitch ([int]$index, [Object]$remote) : base ($index, $remote) {
AddBoolMembers -PARAMS @('on')
AddFloatMembers -PARAMS @('drywet', 'pitchvalue', 'loformant', 'medformant', 'hiformant')
}
[string] identifier () {
return 'Strip[' + $this.index + '].Pitch'
}
[void] RecallPreset ([int]$presetIndex) {
$this.Setter('RecallPreset', $presetIndex)
}
}
class StripAudibility : IRemote { class StripAudibility : IRemote {
StripAudibility ([int]$index, [Object]$remote) : base ($index, $remote) { StripAudibility ([int]$index, [Object]$remote) : base ($index, $remote) {
} }

View File

@ -40,6 +40,13 @@ Describe -Tag 'higher', -TestName 'All Higher Tests' {
$vmr.strip[$index].vaio | Should -Be $expected $vmr.strip[$index].vaio | Should -Be $expected
} }
Context 'Pitch' -Skip:$ifNotPotato {
It "Should set Strip[$index].Pitch.On" {
$vmr.strip[$index].pitch.on = $value
$vmr.strip[$index].pitch.on | Should -Be $expected
}
}
Context 'Eq' -Skip:$ifNotPotato -ForEach @( Context 'Eq' -Skip:$ifNotPotato -ForEach @(
@{ Eq = $vmr.strip[$index].eq } @{ Eq = $vmr.strip[$index].eq }
) { ) {
@ -332,6 +339,33 @@ Describe -Tag 'higher', -TestName 'All Higher Tests' {
} }
} }
Context 'Pitch' -Skip:$ifNotPotato {
It "Should set Strip[$index].Pitch.drywet" {
$vmr.strip[$index].pitch.drywet = $slide
$vmr.strip[$index].pitch.drywet | Should -Be $slide
}
It "Should set Strip[$index].Pitch.pitchvalue" {
$vmr.strip[$index].pitch.pitchvalue = $slide
$vmr.strip[$index].pitch.pitchvalue | Should -Be $slide
}
It "Should set Strip[$index].Pitch.loformant" {
$vmr.strip[$index].pitch.loformant = $slide
$vmr.strip[$index].pitch.loformant | Should -Be $slide
}
It "Should set Strip[$index].Pitch.medformant" {
$vmr.strip[$index].pitch.medformant = $slide
$vmr.strip[$index].pitch.medformant | Should -Be $slide
}
It "Should set Strip[$index].Pitch.hiformant" {
$vmr.strip[$index].pitch.hiformant = $slide
$vmr.strip[$index].pitch.hiformant | Should -Be $slide
}
}
Context 'Audibility' -Skip:$ifNotBasic { Context 'Audibility' -Skip:$ifNotBasic {
It "Should set Strip[$index].Audibility" { It "Should set Strip[$index].Audibility" {
$vmr.strip[$index].audibility.knob = $knob $vmr.strip[$index].audibility.knob = $knob