Skip to content

Commit

Permalink
slightly improve naming for otherwise potentially confusing variable
Browse files Browse the repository at this point in the history
  • Loading branch information
dmrschmidt committed Nov 15, 2022
1 parent 07d8033 commit 5814189
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/DSWaveformImage/WaveformImageDrawer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,8 @@ private extension WaveformImageDrawer {
let path = CGMutablePath()
var maxAmplitude: CGFloat = 0.0 // we know 1 is our max in normalized data, but we keep it 'generic'

for (y, sample) in samples.enumerated() {
var x = y + lastOffset
for (index, sample) in samples.enumerated() {
var x = index + lastOffset
if case .striped = configuration.style, x % Int(configuration.scale) != 0 || x % stripeBucket(configuration) != 0 {
// skip sub-pixels - any x value not scale aligned
// skip any point that is not a multiple of our bucket width (width + spacing)
Expand Down

0 comments on commit 5814189

Please sign in to comment.