| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 Google Inc. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #include "PictureRenderer.h" | 8 #include "PictureRenderer.h" |
| 9 #include "picture_utils.h" | 9 #include "picture_utils.h" |
| 10 #include "SamplePipeControllers.h" | 10 #include "SamplePipeControllers.h" |
| (...skipping 886 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 897 } | 897 } |
| 898 | 898 |
| 899 SkString MultiCorePictureRenderer::getConfigNameInternal() { | 899 SkString MultiCorePictureRenderer::getConfigNameInternal() { |
| 900 SkString name = this->INHERITED::getConfigNameInternal(); | 900 SkString name = this->INHERITED::getConfigNameInternal(); |
| 901 name.appendf("_multi_%i_threads", fNumThreads); | 901 name.appendf("_multi_%i_threads", fNumThreads); |
| 902 return name; | 902 return name; |
| 903 } | 903 } |
| 904 | 904 |
| 905 ////////////////////////////////////////////////////////////////////////////////
/////////////// | 905 ////////////////////////////////////////////////////////////////////////////////
/////////////// |
| 906 | 906 |
| 907 void PlaybackCreationRenderer::setup() { | 907 void PlaybackCreationRenderer::setup1() { |
| 908 fReplayer.reset(this->createPicture()); | 908 fReplayer.reset(this->createPicture()); |
| 909 SkCanvas* recorder = fReplayer->beginRecording(this->getViewWidth(), this->g
etViewHeight(), | 909 SkCanvas* recorder = fReplayer->beginRecording(this->getViewWidth(), this->g
etViewHeight(), |
| 910 this->recordFlags()); | 910 this->recordFlags()); |
| 911 this->scaleToScaleFactor(recorder); | 911 this->scaleToScaleFactor(recorder); |
| 912 recorder->drawPicture(*fPicture); | 912 recorder->drawPicture(*fPicture); |
| 913 } | 913 } |
| 914 | 914 |
| 915 bool PlaybackCreationRenderer::render(SkBitmap** out) { | 915 bool PlaybackCreationRenderer::render(SkBitmap** out) { |
| 916 fReplayer->endRecording(); | 916 fReplayer->endRecording(); |
| 917 // Since this class does not actually render, return false. | 917 // Since this class does not actually render, return false. |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 995 virtual SkString getConfigNameInternal() SK_OVERRIDE { | 995 virtual SkString getConfigNameInternal() SK_OVERRIDE { |
| 996 return SkString("picture_clone"); | 996 return SkString("picture_clone"); |
| 997 } | 997 } |
| 998 }; | 998 }; |
| 999 | 999 |
| 1000 PictureRenderer* CreatePictureCloneRenderer() { | 1000 PictureRenderer* CreatePictureCloneRenderer() { |
| 1001 return SkNEW(PictureCloneRenderer); | 1001 return SkNEW(PictureCloneRenderer); |
| 1002 } | 1002 } |
| 1003 | 1003 |
| 1004 } // namespace sk_tools | 1004 } // namespace sk_tools |
| OLD | NEW |