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

Side by Side Diff: Source/platform/graphics/GraphicsContext.h

Issue 658603002: 2D canvas: fix shadow rendering with compositing modes that require temp layers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: comment fix Created 6 years, 2 months 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2008-2009 Torch Mobile, Inc. 3 * Copyright (C) 2008-2009 Torch Mobile, Inc.
4 * Copyright (C) 2013 Google Inc. All rights reserved. 4 * Copyright (C) 2013 Google Inc. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 345
346 // Instead of being dispatched to the active canvas, draw commands following beginRecording() 346 // Instead of being dispatched to the active canvas, draw commands following beginRecording()
347 // are stored in a display list that can be replayed at a later time. Pass i n the bounding 347 // are stored in a display list that can be replayed at a later time. Pass i n the bounding
348 // rectangle for the content in the list. 348 // rectangle for the content in the list.
349 void beginRecording(const FloatRect&, uint32_t = 0); 349 void beginRecording(const FloatRect&, uint32_t = 0);
350 PassRefPtr<DisplayList> endRecording(); 350 PassRefPtr<DisplayList> endRecording();
351 351
352 bool hasShadow() const; 352 bool hasShadow() const;
353 void setShadow(const FloatSize& offset, float blur, const Color&, 353 void setShadow(const FloatSize& offset, float blur, const Color&,
354 DrawLooperBuilder::ShadowTransformMode = DrawLooperBuilder::ShadowRespec tsTransforms, 354 DrawLooperBuilder::ShadowTransformMode = DrawLooperBuilder::ShadowRespec tsTransforms,
355 DrawLooperBuilder::ShadowAlphaMode = DrawLooperBuilder::ShadowRespectsAl pha); 355 DrawLooperBuilder::ShadowAlphaMode = DrawLooperBuilder::ShadowRespectsAl pha, ShadowMode = DrawShadowAndForeground);
356 void clearShadow() { clearDrawLooper(); } 356 void clearShadow() { clearDrawLooper(); }
357 357
358 // It is assumed that this draw looper is used only for shadows 358 // It is assumed that this draw looper is used only for shadows
359 // (i.e. a draw looper is set if and only if there is a shadow). 359 // (i.e. a draw looper is set if and only if there is a shadow).
360 // The builder passed into this method will be destroyed. 360 // The builder passed into this method will be destroyed.
361 void setDrawLooper(PassOwnPtr<DrawLooperBuilder>); 361 void setDrawLooper(PassOwnPtr<DrawLooperBuilder>);
362 void clearDrawLooper(); 362 void clearDrawLooper();
363 363
364 void drawFocusRing(const Vector<IntRect>&, int width, int offset, const Colo r&); 364 void drawFocusRing(const Vector<IntRect>&, int width, int offset, const Colo r&);
365 void drawFocusRing(const Path&, int width, int offset, const Color&); 365 void drawFocusRing(const Path&, int width, int offset, const Color&);
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
541 bool m_accelerated : 1; 541 bool m_accelerated : 1;
542 bool m_isCertainlyOpaque : 1; 542 bool m_isCertainlyOpaque : 1;
543 bool m_printing : 1; 543 bool m_printing : 1;
544 bool m_antialiasHairlineImages : 1; 544 bool m_antialiasHairlineImages : 1;
545 bool m_shouldSmoothFonts : 1; 545 bool m_shouldSmoothFonts : 1;
546 }; 546 };
547 547
548 } // namespace blink 548 } // namespace blink
549 549
550 #endif // GraphicsContext_h 550 #endif // GraphicsContext_h
OLDNEW
« no previous file with comments | « Source/core/html/canvas/CanvasRenderingContext2D.cpp ('k') | Source/platform/graphics/GraphicsContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698