projects
/
platform
/
core
/
uifw
/
dali-toolkit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Store VisualUrl's hash result, and reuse it
[platform/core/uifw/dali-toolkit.git]
/
dali-toolkit
/
internal
/
visuals
/
visual-factory-cache.h
diff --git
a/dali-toolkit/internal/visuals/visual-factory-cache.h
b/dali-toolkit/internal/visuals/visual-factory-cache.h
index
b19bad4
..
417f4d4
100644
(file)
--- a/
dali-toolkit/internal/visuals/visual-factory-cache.h
+++ b/
dali-toolkit/internal/visuals/visual-factory-cache.h
@@
-2,7
+2,7
@@
#define DALI_TOOLKIT_VISUAL_FACTORY_CACHE_H
/*
#define DALI_TOOLKIT_VISUAL_FACTORY_CACHE_H
/*
- * Copyright (c) 202
1
Samsung Electronics Co., Ltd.
+ * Copyright (c) 202
2
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.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@
-25,9
+25,9
@@
#include <dali/public-api/rendering/shader.h>
// INTERNAL INCLUDES
#include <dali/public-api/rendering/shader.h>
// INTERNAL INCLUDES
+#include <dali-toolkit/internal/texture-manager/texture-manager-impl.h>
#include <dali-toolkit/internal/visuals/npatch-loader.h>
#include <dali-toolkit/internal/visuals/svg/svg-rasterize-thread.h>
#include <dali-toolkit/internal/visuals/npatch-loader.h>
#include <dali-toolkit/internal/visuals/svg/svg-rasterize-thread.h>
-#include <dali-toolkit/internal/visuals/texture-manager-impl.h>
#include <dali/devel-api/rendering/renderer-devel.h>
namespace Dali
#include <dali/devel-api/rendering/renderer-devel.h>
namespace Dali
@@
-201,8
+201,11
@@
public:
* @brief Update the broken image Renderer object
* @param[in,out] renderer renderer for broken image
* @param[in] size the size of actor
* @brief Update the broken image Renderer object
* @param[in,out] renderer renderer for broken image
* @param[in] size the size of actor
+ * @param[in] rendererIsImage True if input renderer use image shader already.
+ * If true, we don't need to create new renderer when broken image is single image.
+ * Most of user experience use normal images. So It can reduce runtime.
*/
*/
- void UpdateBrokenImageRenderer(Renderer& renderer, const Vector2& size);
+ void UpdateBrokenImageRenderer(Renderer& renderer, const Vector2& size
, const bool& rendererIsImage = true
);
public:
/**
public:
/**
@@
-298,12
+301,12
@@
private:
struct BrokenImageInfo
{
BrokenImageInfo()
struct BrokenImageInfo
{
BrokenImageInfo()
- :visualType(),
- url(""),
- npatchId(NPatchData::INVALID_NPATCH_DATA_ID),
- texture(),
- width(0),
- height(0)
+ :
visualType(),
+
url(""),
+
npatchId(NPatchData::INVALID_NPATCH_DATA_ID),
+
texture(),
+
width(0),
+
height(0)
{
}
{
}
@@
-312,20
+315,20
@@
private:
}
// Data
}
// Data
- VisualUrl::Type
visualType;
- std::string
url;
- NPatchData::NPatchDataId
npatchId;
- Texture
texture;
- uint32_t
width;
- uint32_t
height;
+ VisualUrl::Type visualType;
+ std::string url;
+ NPatchData::NPatchDataId npatchId;
+ Texture texture;
+ uint32_t width;
+ uint32_t height;
};
Geometry mGeometry[GEOMETRY_TYPE_MAX + 1];
Shader mShader[SHADER_TYPE_MAX + 1];
};
Geometry mGeometry[GEOMETRY_TYPE_MAX + 1];
Shader mShader[SHADER_TYPE_MAX + 1];
- ImageAtlasManagerPtr
mAtlasManager;
- TextureManager
mTextureManager;
- NPatchLoader
mNPatchLoader;
+ ImageAtlasManagerPtr mAtlasManager;
+ TextureManager mTextureManager;
+ NPatchLoader mNPatchLoader;
SvgRasterizeThread* mSvgRasterizeThread;
std::unique_ptr<VectorAnimationManager> mVectorAnimationManager;
SvgRasterizeThread* mSvgRasterizeThread;
std::unique_ptr<VectorAnimationManager> mVectorAnimationManager;