Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void test_can_load_tons_of_images_from_packfiles_quickly()
- {
- MountVFile("\\dev\\kotg\\img.vpk");
- assert(filesmounted == 1);
- mountstruct* packfile = &pack[0];
- clock_t start, end;
- start = clock();
- for (int i = 0; i < packfile->numfiles; i++)
- {
- filestruct* file = &packfile->files[i];
- std::string filename = (const char*)file->fname;
- if (boost::algorithm::iends_with(filename, ".gif"))
- {
- xLoadImage8(filename.c_str());
- }
- }
- end = clock();
- err("Took %f seconds", (float)(end - start) / CLOCKS_PER_SEC);
- }
Add Comment
Please, Sign In to add comment