forked from organicmaps/organicmaps
removed unused Pen::m_isWrapped field.
This commit is contained in:
parent
bb19a489f0
commit
ee425ef178
3 changed files with 6 additions and 14 deletions
|
@ -67,7 +67,7 @@ namespace graphics
|
|||
|
||||
float rawTileLen = (float)pen->rawTileLen();
|
||||
|
||||
if ((offset < 0) && (!pen->m_isWrapped))
|
||||
if (offset < 0)
|
||||
offset = offset - rawTileLen * ceil(offset / rawTileLen);
|
||||
|
||||
bool skipToOffset = true;
|
||||
|
@ -127,12 +127,9 @@ namespace graphics
|
|||
|
||||
while (segLenRemain > 0)
|
||||
{
|
||||
rawTileLen = pen->m_isWrapped
|
||||
? segLen
|
||||
: std::min(((float)pen->rawTileLen() - rawTileStartLen), segLenRemain);
|
||||
rawTileLen = std::min(((float)pen->rawTileLen() - rawTileStartLen), segLenRemain);
|
||||
|
||||
|
||||
float texMinX = pen->m_isWrapped ? 0 : pen->m_texRect.minX() + 2 + rawTileStartLen;
|
||||
float texMinX = pen->m_texRect.minX() + 2 + rawTileStartLen;
|
||||
float texMaxX = texMinX + rawTileLen;
|
||||
|
||||
rawTileStartLen += rawTileLen;
|
||||
|
|
|
@ -156,8 +156,7 @@ namespace graphics
|
|||
Resource * Pen::Info::createResource(m2::RectU const & texRect,
|
||||
uint8_t pipelineID) const
|
||||
{
|
||||
return new Pen(false,
|
||||
texRect,
|
||||
return new Pen(texRect,
|
||||
pipelineID,
|
||||
*this);
|
||||
}
|
||||
|
@ -194,13 +193,11 @@ namespace graphics
|
|||
return false;
|
||||
}
|
||||
|
||||
Pen::Pen(bool isWrapped,
|
||||
m2::RectU const & texRect,
|
||||
Pen::Pen(m2::RectU const & texRect,
|
||||
int pipelineID,
|
||||
Info const & info)
|
||||
: Resource(EPen, texRect, pipelineID),
|
||||
m_info(info),
|
||||
m_isWrapped(isWrapped),
|
||||
m_isSolid(info.m_isSolid)
|
||||
{
|
||||
if (m_isSolid)
|
||||
|
|
|
@ -65,14 +65,12 @@ namespace graphics
|
|||
|
||||
Info m_info;
|
||||
|
||||
bool m_isWrapped;
|
||||
bool m_isSolid;
|
||||
|
||||
m2::PointU m_centerColorPixel;
|
||||
m2::PointU m_borderColorPixel;
|
||||
|
||||
Pen(bool isWrapped,
|
||||
m2::RectU const & texRect,
|
||||
Pen(m2::RectU const & texRect,
|
||||
int pipelineID,
|
||||
Info const & info);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue