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
Fixes the change of style when the text-field grabs the keyboard focus.
[platform/core/uifw/dali-toolkit.git]
/
dali-toolkit
/
internal
/
atlas-manager
/
atlas-manager-impl.h
diff --git
a/dali-toolkit/internal/atlas-manager/atlas-manager-impl.h
b/dali-toolkit/internal/atlas-manager/atlas-manager-impl.h
index
d120f4f
..
5b301f0
100644
(file)
--- a/
dali-toolkit/internal/atlas-manager/atlas-manager-impl.h
+++ b/
dali-toolkit/internal/atlas-manager/atlas-manager-impl.h
@@
-60,15
+60,14
@@
public:
struct AtlasDescriptor
{
Dali::Atlas mAtlas; // atlas image
struct AtlasDescriptor
{
Dali::Atlas mAtlas; // atlas image
- SizeType mWidth; // width of atlas
- SizeType mHeight; // height of atlas
- SizeType mBlockWidth; // width of a block in atlas
- SizeType mBlockHeight; // height of a block in atlas
+ Toolkit::AtlasManager::AtlasSize mSize; // size of atlas
Pixel::Format mPixelFormat; // pixel format used by atlas
Pixel::Format mPixelFormat; // pixel format used by atlas
- BufferImage m
EdgeX;
// Image used to pad upload
- BufferImage m
EdgeY;
// Image used to pad upload
+ BufferImage m
HorizontalStrip;
// Image used to pad upload
+ BufferImage m
VerticalStrip;
// Image used to pad upload
Material mMaterial; // material used for atlas texture
Material mMaterial; // material used for atlas texture
- SizeType mNextFreeBlock; // next free block will be placed here ( actually +1 )
+ Sampler mSampler; // sampler used for atlas texture
+ SizeType mTotalBlocks; // total number of blocks in atlas
+ SizeType mAvailableBlocks; // number of blocks available in atlas
Dali::Vector< SizeType > mFreeBlocksList; // unless there are any previously freed blocks
};
Dali::Vector< SizeType > mFreeBlocksList; // unless there are any previously freed blocks
};
@@
-93,11
+92,7
@@
public:
/**
* @copydoc: Toolkit::AtlasManager::CreateAtlas
*/
/**
* @copydoc: Toolkit::AtlasManager::CreateAtlas
*/
- AtlasId CreateAtlas( SizeType width,
- SizeType height,
- SizeType blockWidth,
- SizeType blockHeight,
- Pixel::Format pixelformat );
+ AtlasId CreateAtlas( const Toolkit::AtlasManager::AtlasSize& size, Pixel::Format pixelformat );
/**
* @copydoc Toolkit::AtlasManager::SetAddPolicy
/**
* @copydoc Toolkit::AtlasManager::SetAddPolicy
@@
-116,23
+111,17
@@
public:
*/
void GenerateMeshData( ImageId id,
const Vector2& position,
*/
void GenerateMeshData( ImageId id,
const Vector2& position,
- MeshData& mesh );
+ Toolkit::AtlasManager::Mesh2D& mesh,
+ bool addReference );
/**
* @copydoc Toolkit::AtlasManager::StitchMesh
*/
/**
* @copydoc Toolkit::AtlasManager::StitchMesh
*/
- void StitchMesh(
MeshData
& first,
- const
MeshData
& second,
+ void StitchMesh(
Toolkit::AtlasManager::Mesh2D
& first,
+ const
Toolkit::AtlasManager::Mesh2D
& second,
bool optimize );
/**
bool optimize );
/**
- * @copydoc Toolkit::AtlasManager::StitchMesh
- */
- void StitchMesh( const MeshData& first,
- const MeshData& second,
- MeshData& out, bool optimize );
-
- /**
* @copydoc Toolkit::AtlasManager::Remove
*/
bool Remove( ImageId id );
* @copydoc Toolkit::AtlasManager::Remove
*/
bool Remove( ImageId id );
@@
-150,13
+139,12
@@
public:
/**
* @copydoc Toolkit::AtlasManager::SetNewAtlasSize
*/
/**
* @copydoc Toolkit::AtlasManager::SetNewAtlasSize
*/
- void SetNewAtlasSize( const Vector2& size,
- const Vector2& blockSize );
+ void SetNewAtlasSize( const Toolkit::AtlasManager::AtlasSize& size );
/**
* @copydoc Toolkit::AtlasManager::GetAtlasSize
*/
/**
* @copydoc Toolkit::AtlasManager::GetAtlasSize
*/
-
Vector2
GetAtlasSize( AtlasId atlas );
+
const Toolkit::AtlasManager::AtlasSize&
GetAtlasSize( AtlasId atlas );
/**
* @copydoc Toolkit::AtlasManager::GetBlockSize
/**
* @copydoc Toolkit::AtlasManager::GetBlockSize
@@
-183,17
+171,28
@@
public:
*/
void GetMetrics( Toolkit::AtlasManager::Metrics& metrics );
*/
void GetMetrics( Toolkit::AtlasManager::Metrics& metrics );
+ /**
+ * @copydoc Toolkit::AtlasManager::GetMaterial
+ */
+ Material GetMaterial( AtlasId atlas ) const;
+
+/**
+ * @copydoc Toolkit::AtlasManager::GetSampler
+ */
+ Sampler GetSampler( AtlasId atlas ) const;
+
private:
private:
- std::vector< AtlasDescriptor > mAtlasList; // List of atlases created
- std::vector< AtlasSlotDescriptor > mImageList; // List of bitmaps store in atlases
+ std::vector< AtlasDescriptor > mAtlasList; // List of atlases created
+ std::vector< AtlasSlotDescriptor > mImageList; // List of bitmaps store in atlases
+ Toolkit::AtlasManager::AtlasSize mNewAtlasSize; // Atlas size to use in next creation
+ Toolkit::AtlasManager::AddFailPolicy mAddFailPolicy; // Policy for faling to add an Image
SizeType CheckAtlas( SizeType atlas,
SizeType width,
SizeType height,
Pixel::Format pixelFormat,
SizeType CheckAtlas( SizeType atlas,
SizeType width,
SizeType height,
Pixel::Format pixelFormat,
- SizeType& blockArea,
- SizeType& totalBlocks );
+ SizeType& blockArea );
void CreateMesh( SizeType atlas,
SizeType imageWidth,
void CreateMesh( SizeType atlas,
SizeType imageWidth,
@@
-201,23
+200,20
@@
private:
const Vector2& position,
SizeType widthInBlocks,
SizeType heightInBlocks,
const Vector2& position,
SizeType widthInBlocks,
SizeType heightInBlocks,
-
Dali::MeshData& meshData
,
+
Toolkit::AtlasManager::Mesh2D& mesh
,
AtlasSlotDescriptor& desc );
AtlasSlotDescriptor& desc );
- void OptimizeVertices( const MeshData::VertexContainer& in,
- MeshData::FaceIndices& faces,
- MeshData::VertexContainer& out );
+ void OptimizeMesh( const Toolkit::AtlasManager::Mesh2D& in,
+ Toolkit::AtlasManager::Mesh2D& out );
void UploadImage( const BufferImage& image,
const AtlasSlotDescriptor& desc );
void UploadImage( const BufferImage& image,
const AtlasSlotDescriptor& desc );
- void PrintMeshData( const MeshData& meshData );
+ void PrintMeshData( const Toolkit::AtlasManager::Mesh2D& mesh );
+
+ Shader mShaderL8;
+ Shader mShaderRgba;
- Vector2 mNewAtlasSize;
- Vector2 mNewBlockSize;
- Toolkit::AtlasManager::AddFailPolicy mAddFailPolicy;
- PixelBuffer* mEdgeBuffer;
- uint32_t mEdgeBufferSize;
};
} // namespace Internal
};
} // namespace Internal
@@
-245,4
+241,4
@@
inline Internal::AtlasManager& GetImplementation(Toolkit::AtlasManager& manager)
} // namespace Dali
} // namespace Dali
- #endif // __DALI_TOOLKIT_ATLAS_MANAGER_IMPL_H__
\ No newline at end of file
+ #endif // __DALI_TOOLKIT_ATLAS_MANAGER_IMPL_H__