#define DALI_TEST_GRAPHICS_COMMAND_BUFFER_H
/*
- * Copyright (c) 2024 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2025 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
{
mCommands.emplace_back();
mCommands.back().type = CommandType::BIND_TEXTURES;
- mCommands.back().data.bindTextures.textureBindings = std::move(textureBindings);
+ mCommands.back().data.bindTextures.textureBindings = textureBindings;
mCallStack.PushCall("BindTextures", "");
}
void BindSamplers(const std::vector<Graphics::SamplerBinding>& samplerBindings) override
{
mCommands.emplace_back();
- mCommands.back().data.bindSamplers.samplerBindings = std::move(samplerBindings);
+ mCommands.back().data.bindSamplers.samplerBindings = samplerBindings;
mCallStack.PushCall("BindSamplers", "");
}
/*
- * Copyright (c) 2024 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2025 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
return false;
}
-void FontClient::Plugin::CacheHandler::CacheFontData(const std::string& fontPath, Dali::Vector<uint8_t>& fontDataBuffer, std::streampos& dataSize)
+void FontClient::Plugin::CacheHandler::CacheFontData(const std::string& fontPath, Dali::Vector<uint8_t>&& fontDataBuffer, std::streampos& dataSize)
{
mFontDataCache[fontPath] = std::make_pair(std::move(fontDataBuffer), dataSize);
}
#define DALI_INTERNAL_TEXT_ABSTRACTION_FONT_CLIENT_PLUGIN_CACHE_HANDLER_H
/*
- * Copyright (c) 2023 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2025 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* @param[in] fontDataBuffer A vector containing the font data to cache.
* @param[in] dataSize The size of the font data to cache.
*/
- void CacheFontData(const std::string& fontPath, Dali::Vector<uint8_t>& fontDataBuffer, std::streampos& dataSize);
+ void CacheFontData(const std::string& fontPath, Dali::Vector<uint8_t>&& fontDataBuffer, std::streampos& dataSize);
/**
* @brief Checks if FreeType face for the specified font path is cached.
FontDescriptionSizeCacheContainer mFontDescriptionSizeCache; ///< Caches font identifiers for the pairs of font point size and the index to the vector with font descriptions of the validated fonts.
- std::unordered_map<std::string, std::pair<Dali::Vector<uint8_t>, std::streampos>> mFontDataCache; ///< Caches font data with each font path as the key, allowing faster loading of fonts later on.
- std::unordered_map<std::string, FT_Face> mFontFTFaceCache; ///< Caches freetype font face for font pre-load.
+ std::unordered_map<std::string, std::pair<Dali::Vector<uint8_t>, std::streampos>> mFontDataCache; ///< Caches font data with each font path as the key, allowing faster loading of fonts later on.
+ std::unordered_map<std::string, FT_Face> mFontFTFaceCache; ///< Caches freetype font face for font pre-load.
std::vector<EllipsisItem> mEllipsisCache; ///< Caches ellipsis glyphs for a particular point size.
std::vector<BitmapFontCacheItem> mBitmapFontCache; ///< Stores bitmap fonts.
/*
- * Copyright (c) 2024 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2025 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
const float FROM_266 = 1.0f / 64.0f;
const float POINTS_PER_INCH = 72.f;
-const uint32_t ELLIPSIS_CHARACTER = 0x2026;
+const uint32_t ELLIPSIS_CHARACTER = 0x2026;
const uint32_t CUSTOM_FONTS_MAX_COUNT = 10u;
} // namespace
}
// Cache font data
- mCacheHandler->CacheFontData(fontPath, fontDataBuffer, dataSize);
+ mCacheHandler->CacheFontData(fontPath, std::move(fontDataBuffer), dataSize);
}
void FontClient::Plugin::CacheFontFaceFromFile(const std::string& fontPath) const