You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Removing nested OMP processing from FrameMapper. Adding lock inside time mapping (to prevent crashes when speeding up/slowing down clips). Adding omp critial lock to Frame GetAudioChannelsCount() and GetAudioSamplesCount() methods.
This commit is contained in:
@@ -410,13 +410,19 @@ float* Frame::GetInterleavedAudioSamples(int new_sample_rate, AudioResampler* re
|
||||
// Get number of audio channels
|
||||
int Frame::GetAudioChannelsCount()
|
||||
{
|
||||
return audio->getNumChannels();
|
||||
int i;
|
||||
#pragma omp critical
|
||||
i = audio->getNumChannels();
|
||||
return i;
|
||||
}
|
||||
|
||||
// Get number of audio samples
|
||||
int Frame::GetAudioSamplesCount()
|
||||
{
|
||||
return audio->getNumSamples();
|
||||
int i;
|
||||
#pragma omp critical
|
||||
i = audio->getNumSamples();
|
||||
return i;
|
||||
}
|
||||
|
||||
juce::AudioSampleBuffer *Frame::GetAudioSampleBuffer()
|
||||
|
||||
Reference in New Issue
Block a user