Example #1
0
void AssetBrowser::addResource(const char* path, const char* filename)
{
	char ext[10];
	Lumix::PathUtils::getExtension(ext, sizeof(ext), filename);

	char fullpath[Lumix::MAX_PATH_LENGTH];
	Lumix::copyString(fullpath, path);
	Lumix::catString(fullpath, "/");
	Lumix::catString(fullpath, filename);
	
	int index = getResourceTypeIndex(ext);

	if (Lumix::startsWith(path, "/render_tests") != 0) return;
	if (Lumix::startsWith(path, "/unit_tests") != 0) return;
	if (index < 0) return;

	Lumix::Path path_obj(fullpath);
	if (m_resources[index].indexOf(path_obj) == -1)
	{
		m_resources[index].push(path_obj);
	}
}
Example #2
0
bool is_xtreemfs_path(const char *path) {
  Path path_obj(path);
  return path_obj.IsXtreemFS();
}