and fixed pixel alignment issue also.
Change-Id: I8fb79eafd58714b1f2fcb42d650b7f6a1ca4eeea
{
mAtlasManager = Dali::Toolkit::AtlasManager::New();
mSampler = Sampler::New();
- mSampler.SetFilterMode( FilterMode::NEAREST, FilterMode::NEAREST );
+ mSampler.SetFilterMode( FilterMode::LINEAR, FilterMode::LINEAR );
}
void AtlasGlyphManager::Add( const Text::GlyphInfo& glyph,
}
// Move the origin (0,0) of the mesh to the center of the actor
- const Vector2 position = *( positionsBuffer + i ) - halfTextSize - lineOffsetPosition;
+ const Vector2& temp = *( positionsBuffer + i );
+ const Vector2 position = Vector2( roundf( temp.x ), temp.y ) - halfTextSize - lineOffsetPosition; // roundf() avoids pixel alignment issues.
if ( 0u != slot.mImageId ) // invalid slot id, glyph has failed to be added to atlas
{