|
|
|
@ -773,16 +773,13 @@ namespace MWRender
|
|
|
|
|
int mSize;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
bool RenderingManager::screenshot360(osg::Image* image)
|
|
|
|
|
bool RenderingManager::screenshot360(osg::Image* image, std::string settingStr)
|
|
|
|
|
{
|
|
|
|
|
int screenshotW = mViewer->getCamera()->getViewport()->width();
|
|
|
|
|
int screenshotH = mViewer->getCamera()->getViewport()->height();
|
|
|
|
|
SphericalScreenshot::SphericalScreenshotMapping screenshotMapping = SphericalScreenshot::MAPPING_SPHERICAL;
|
|
|
|
|
int cubeSize = screenshotW / 2;
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
std::string settingStr = Settings::Manager::getString("screenshot type","Video");
|
|
|
|
|
std::vector<std::string> settingArgs;
|
|
|
|
|
boost::algorithm::split(settingArgs,settingStr,boost::is_any_of(" "));
|
|
|
|
|
|
|
|
|
@ -814,12 +811,6 @@ namespace MWRender
|
|
|
|
|
|
|
|
|
|
if (settingArgs.size() > 3)
|
|
|
|
|
cubeSize = std::min(5000,std::atoi(settingArgs[3].c_str()));
|
|
|
|
|
}
|
|
|
|
|
catch (std::runtime_error)
|
|
|
|
|
{
|
|
|
|
|
std::cerr << "Wrong parameters for screenshot type." << std::endl;
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (mCamera->isVanityOrPreviewModeEnabled())
|
|
|
|
|
{
|
|
|
|
|