mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Minor docs change, and addition to AudioThumbnail.
This commit is contained in:
parent
d273693ce2
commit
904e54660f
3 changed files with 11 additions and 0 deletions
|
|
@ -133,6 +133,9 @@ public:
|
|||
//==============================================================================
|
||||
/** Fills-in the given structure with details about the transport's
|
||||
position at the start of the current processing block.
|
||||
|
||||
This method must ONLY be called from within your AudioProcessor::processBlock()
|
||||
method. Calling it at any other time will probably cause a nasty crash.
|
||||
*/
|
||||
virtual bool getCurrentPosition (CurrentPositionInfo& result) = 0;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -740,6 +740,11 @@ bool AudioThumbnail::isFullyLoaded() const noexcept
|
|||
return numSamplesFinished >= totalSamples - samplesPerThumbSample;
|
||||
}
|
||||
|
||||
double AudioThumbnail::getProportionComplete() const noexcept
|
||||
{
|
||||
return jlimit (0.0, 1.0, numSamplesFinished / (double) totalSamples);
|
||||
}
|
||||
|
||||
int64 AudioThumbnail::getNumSamplesFinished() const noexcept
|
||||
{
|
||||
return numSamplesFinished;
|
||||
|
|
|
|||
|
|
@ -168,6 +168,9 @@ public:
|
|||
/** Returns true if the low res preview is fully generated. */
|
||||
bool isFullyLoaded() const noexcept;
|
||||
|
||||
/** Returns a value between 0 and 1 to indicate the progress towards loading the entire file. */
|
||||
double getProportionComplete() const noexcept;
|
||||
|
||||
/** Returns the number of samples that have been set in the thumbnail. */
|
||||
int64 getNumSamplesFinished() const noexcept;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue