About the same issue: I wish SFML would let us get the m_cacheID(not the GL ID, the internal SFML 64 bit ID), now it's private and RenderTexture/Window are friends. Why not let user get the cache ID too?
Sort of related, do you think I should use the SFML cache ID rather than the GL ID?
Looking at the source code, It looks like the use of the assignment operator causes the object to generate a new cacheID for itself.
Texture& Texture::operator =(const Texture& right)
{
Texture temp(right);
std::swap(m_size, temp.m_size);
std::swap(m_actualSize, temp.m_actualSize);
std::swap(m_texture, temp.m_texture);
std::swap(m_isSmooth, temp.m_isSmooth);
std::swap(m_isRepeated, temp.m_isRepeated);
std::swap(m_pixelsFlipped, temp.m_pixelsFlipped);
// New cache ID
m_cacheId = getUniqueId();
return *this;
}
I assume that would make it difficult to compare texture equality.
Also, i'm not quite sure if you were being sarcastic there...