tasks now emit floats rather than integers

Simplifies code for tasks.
This commit is contained in:
itsmattkc
2020-05-19 02:44:38 +10:00
parent b9cd83eff1
commit cb383d760b
10 changed files with 28 additions and 11 deletions
+1 -1
View File
@@ -333,7 +333,7 @@ bool Decoder::HasConformedVersion(const AudioRenderingParams &params)
void Decoder::SignalProcessingProgress(const int64_t &ts)
{
if (stream()->duration() != AV_NOPTS_VALUE && stream()->duration() != 0) {
emit IndexProgress(qRound(100.0 * static_cast<double>(ts) / static_cast<double>(stream()->duration())));
emit IndexProgress(static_cast<double>(ts) / static_cast<double>(stream()->duration()));
}
}
+1 -1
View File
@@ -242,7 +242,7 @@ signals:
* @brief While indexing, this signal will provide progress as a percentage (0-100 inclusive) if
* available
*/
void IndexProgress(int);
void IndexProgress(double);
protected:
void SignalProcessingProgress(const int64_t& ts);