Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(71)

Side by Side Diff: src/gpu/GrDrawState.h

Issue 695813003: Add class GrGLTextureRenderTarget for GL texture/rendertarget objects (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: forgot to save file Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 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 #ifndef GrDrawState_DEFINED 8 #ifndef GrDrawState_DEFINED
9 #define GrDrawState_DEFINED 9 #define GrDrawState_DEFINED
10 10
(...skipping 512 matching lines...) Expand 10 before | Expand all | Expand 10 after
523 523
524 /////////////////////////////////////////////////////////////////////////// 524 ///////////////////////////////////////////////////////////////////////////
525 /// @name Render Target 525 /// @name Render Target
526 //// 526 ////
527 527
528 /** 528 /**
529 * Retrieves the currently set render-target. 529 * Retrieves the currently set render-target.
530 * 530 *
531 * @return The currently set render target. 531 * @return The currently set render target.
532 */ 532 */
533 GrRenderTarget* getRenderTarget() const { 533 GrRenderTarget* getRenderTarget() const { return fRenderTarget.get(); }
534 return static_cast<GrRenderTarget*>(fRenderTarget.getResource());
535 }
536 534
537 /** 535 /**
538 * Sets the render-target used at the next drawing call 536 * Sets the render-target used at the next drawing call
539 * 537 *
540 * @param target The render target to set. 538 * @param target The render target to set.
541 */ 539 */
542 void setRenderTarget(GrRenderTarget* target) { 540 void setRenderTarget(GrRenderTarget* target) {
543 fRenderTarget.set(SkSafeRef(target), kWrite_GrIOType); 541 fRenderTarget.set(SkSafeRef(target), kWrite_GrIOType);
544 this->invalidateOptState(); 542 this->invalidateOptState();
545 } 543 }
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
853 mutable uint32_t fCachedCapsID; 851 mutable uint32_t fCachedCapsID;
854 852
855 friend class GrOptDrawState; 853 friend class GrOptDrawState;
856 854
857 typedef SkRefCnt INHERITED; 855 typedef SkRefCnt INHERITED;
858 }; 856 };
859 857
860 GR_MAKE_BITFIELD_OPS(GrDrawState::BlendOptFlags); 858 GR_MAKE_BITFIELD_OPS(GrDrawState::BlendOptFlags);
861 859
862 #endif 860 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698