Changeset 11071 for code/trunk/src/modules/designtools/ScreenshotManager.cc
- Timestamp:
- Jan 17, 2016, 10:29:21 PM (8 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
-
code/trunk/src/modules/designtools/ScreenshotManager.cc
r10624 r11071 69 69 Constructor. 70 70 */ 71 ScreenshotManager::ScreenshotManager() : finalPicturePB_( NULL), data_(NULL)71 ScreenshotManager::ScreenshotManager() : finalPicturePB_(nullptr), data_(nullptr) 72 72 { 73 73 RegisterObject(ScreenshotManager); … … 90 90 void ScreenshotManager::cleanup(void) 91 91 { 92 if(this->finalPicturePB_ != NULL)92 if(this->finalPicturePB_ != nullptr) 93 93 { 94 94 delete this->finalPicturePB_; 95 this->finalPicturePB_ = NULL;96 } 97 if(this->data_ != NULL)95 this->finalPicturePB_ = nullptr; 96 } 97 if(this->data_ != nullptr) 98 98 { 99 99 delete this->data_; 100 this->data_ = NULL;100 this->data_ = nullptr; 101 101 } 102 102 if(!this->tempTexture_.isNull()) … … 151 151 // Get the screenshot. 152 152 Ogre::Image* finalImage = getScreenshot(); 153 if(finalImage != NULL)153 if(finalImage != nullptr) 154 154 { 155 155 // Save it. … … 173 173 Ogre::Image* ScreenshotManager::getScreenshot() 174 174 { 175 if(CameraManager::getInstance().getActiveCamera() == NULL)176 return NULL;175 if(CameraManager::getInstance().getActiveCamera() == nullptr ) 176 return nullptr; 177 177 return this->getScreenshot(CameraManager::getInstance().getActiveCamera()->getOgreCamera()); 178 178 } … … 189 189 Ogre::Image* ScreenshotManager::getScreenshot(Ogre::Camera* camera) 190 190 { 191 if(camera == NULL)192 return NULL;191 if(camera == nullptr) 192 return nullptr; 193 193 194 194 // Update the internal parameters.
Note: See TracChangeset
for help on using the changeset viewer.