diff --git a/es-core/src/components/LottieAnimComponent.cpp b/es-core/src/components/LottieAnimComponent.cpp index 862a7ebc7..a2ba86f94 100644 --- a/es-core/src/components/LottieAnimComponent.cpp +++ b/es-core/src/components/LottieAnimComponent.cpp @@ -343,6 +343,22 @@ void LottieAnimComponent::applyTheme(const std::shared_ptr& theme, mIterationCount *= 2; } + if (elem->has("interpolation")) { + const std::string& interpolation {elem->get("interpolation")}; + if (interpolation == "linear") { + mTexture->setLinearMagnify(true); + } + else if (interpolation == "nearest") { + mTexture->setLinearMagnify(false); + } + else { + mTexture->setLinearMagnify(false); + LOG(LogWarning) << "LottieAnimComponent: Invalid theme configuration, property " + "\"interpolation\" for element \"" + << element.substr(10) << "\" defined as \"" << interpolation << "\""; + } + } + if (elem->has("cornerRadius")) mCornerRadius = glm::clamp(elem->get("cornerRadius"), 0.0f, 0.5f) * mRenderer->getScreenWidth();