I could only find std::string in spine::RTTI (I'm using the 3.7 branch).
For the other that might stumble upon this issue:
I'm saving paths in WCHAR arrays (Windows) and when using the Atlas constructor that asks for the full atlas path in char, (even after I convert it to UTF8) it still refused to load the .atlas file (problems when parsing for the last backslash, didn't investigate a lot why it wasn't loading it).
In order to avoid this I used the constructor that asks for the file data array and size and I'm just passing an empty string in the dir param to "force" the Atlas loader to pass along the unmodified image names to the custom texture loader (no folder concatenations and other processing that the constructor does). The texture loader is the one that concatenates the path to the received image file name to create the final file path.
I hope that makes sense.
bool CSpineManager::LoadAtlas(WCHAR * wcsFolder, WCHAR * wcsFile)
{
WCHAR wcsPath[MAX_PATH];
StringCchPrintf(wcsPath, MAX_PATH, L"%s%s", wcsFolder, wcsFile);
int buffSize = 0;
char* buff = OS_readFileToBuffer(wcsPath, buffSize);
if (buff == null)
{
ErrorBox(K_ERR_WARNING, L"[WARNING]CSpineManager::LoadAtlas - file not found: %s", wcsPath);
return false;
}
//set prefix for the tex loader so it knows where to load the images from (it will only receive the filenames without folder)
m_TexMgr->SetFilesPrefix(wcsFolder);
//load with empty "dir" param so it doesn't process the filenames
m_atlas = new Atlas(buff, buffSize, "", m_TexMgr);
//release file buffer
SAFE_DELETE_ARRAY(buff);
// check atlas loaded - could be smthg like m_atlas.IsLoaded()...?
if (m_atlas.getPages().size() == 0)
{
delete m_atlas;
ErrorBox(K_ERR_WARNING, L"[WARNING]CSpineManager::LoadAtlas - couldn't load atlas: %s", wcsPath);
return false;
}
return true;
}