Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose wave height property #1

Open
iDevelopper opened this issue Jun 6, 2021 · 0 comments
Open

Expose wave height property #1

iDevelopper opened this issue Jun 6, 2021 · 0 comments

Comments

@iDevelopper
Copy link

Hi,

Awesome, thanks for this library!

Can the height of the wave be exposed as a configuration property instead of using an arbitrary value (frame.height * 0.5)?

    func loadWaveformData(from audioURL: URL) {
        loadState.loading = true
        ASAudioWaveformDataFactory.loadAudioWaveformData(from: audioURL, formateSize: (waveformConfig.maxSamplesCount, frame.height * 0.5), timeRange: waveformConfig.timeRange) { (samples, assetData) in
            self.loadState = (true, false)
            self.filteredSamples = samples
            self.drawWaveform()
        }
    }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant