I had some old code for iterating over sprites, any advice on how to make it work again?

This code depends on #include “CDefHandler.h” which is not available anymore.

any ideea how to transform the code below with the new alternative?

		CDefEssential * cde = CDefHandler::giveDefEss(fileName);
		
		for (size_t i=0; i<cde->ourImages.size(); i++)
		{
			bfs::path newFilename = spritesPath / (removeExtension(fileName) + (boost::lexical_cast<std::string>(i) + ".bmp"));
			SDL_SaveBMP(cde->ourImages[i].bitmap, newFilename.string().c_str());
		}