mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-20 05:13:58 +00:00
Format all C++ and Java code via clang-format
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
This commit is contained in:
@@ -6,7 +6,10 @@ namespace dp
|
||||
{
|
||||
Texture::ResourceInfo::ResourceInfo(m2::RectF const & texRect) : m_texRect(texRect) {}
|
||||
|
||||
m2::RectF const & Texture::ResourceInfo::GetTexRect() const { return m_texRect; }
|
||||
m2::RectF const & Texture::ResourceInfo::GetTexRect() const
|
||||
{
|
||||
return m_texRect;
|
||||
}
|
||||
|
||||
void Texture::Create(ref_ptr<dp::GraphicsContext> context, Params const & params)
|
||||
{
|
||||
@@ -20,8 +23,8 @@ void Texture::Create(ref_ptr<dp::GraphicsContext> context, Params const & params
|
||||
m_hwTexture->Create(context, params, data);
|
||||
}
|
||||
|
||||
void Texture::UploadData(ref_ptr<dp::GraphicsContext> context, uint32_t x, uint32_t y,
|
||||
uint32_t width, uint32_t height, ref_ptr<void> data)
|
||||
void Texture::UploadData(ref_ptr<dp::GraphicsContext> context, uint32_t x, uint32_t y, uint32_t width, uint32_t height,
|
||||
ref_ptr<void> data)
|
||||
{
|
||||
ASSERT(m_hwTexture != nullptr, ());
|
||||
m_hwTexture->UploadData(context, x, y, width, height, data);
|
||||
@@ -81,10 +84,12 @@ bool Texture::IsPowerOfTwo(uint32_t width, uint32_t height)
|
||||
return glm::isPowerOfTwo(static_cast<int>(width)) && glm::isPowerOfTwo(static_cast<int>(height));
|
||||
}
|
||||
|
||||
void Texture::Destroy() { m_hwTexture.reset(); }
|
||||
void Texture::Destroy()
|
||||
{
|
||||
m_hwTexture.reset();
|
||||
}
|
||||
|
||||
bool Texture::AllocateTexture(ref_ptr<dp::GraphicsContext> context,
|
||||
ref_ptr<HWTextureAllocator> allocator)
|
||||
bool Texture::AllocateTexture(ref_ptr<dp::GraphicsContext> context, ref_ptr<HWTextureAllocator> allocator)
|
||||
{
|
||||
if (allocator != nullptr)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user