Igis Snippet: Clearing the Canvas Every Frame

From Coder Merlin
Jump to navigation Jump to search
func clearCanvas(canvas:Canvas) {
    if let canvasSize = canvas.canvasSize {
        let canvasRect = Rect(topLeft:Point(), size:canvasSize)
        let canvasClearRectangle = Rectangle(rect:canvasRect, fillMode:.clear)

override func render(canvas:Canvas) {

CoderMerlin™ proudly recommends:

Your purchase via these links helps keep  Coder Merlin™ 's orbuculum ablaze. As an Amazon Associate we earn from qualifying purchases. Thank you for your support!

Designed with pride in Silicon Valley, CA, USA