Code Sketch


Shri Damodar Ji (Vasco Saptah)
By: Saanvi Mahesh Madgaonkar
Category: Art
clear()
setSpeed(slow)


setPenColor(gray)




    

def backgroundColor = cm.radialMultipleGradient(
    0, 0, 
    500, 
    Seq(0,0.4,0.7), 
    Seq(yellow, Color(255, 255, 204), Color(255, 0, 102)), 
    false)
    
    setBackground(backgroundColor)
val x = Array(10,20,40,60)
setFillColor(yellow)
setPosition(-20, 200)
repeatFor(rangeTo(0,72)) { i =>
    savePosHe()
    forward(x(i%4))
    restorePosHe()
    right()
    forward(15)
    left(85)

}




def leftside() {
    setPenColor(black)
    right(120, 25)
    setPenColor(noColor)
    right(240, 25)

}
def rightside() {
    setPenColor(black)
    right(120, 25)
    setPenColor(noColor)
    right(240, 25)
}

def curve() {
    setPenColor(black)
   
    setHeading(140)
    left(120, 20)
    setHeading(180)
    right(120, 10)
}

def baseColor = cm.linearGradient(
    0, 0,
    Color(0, 0, 0),
    200, 0,
    gray,
    true)

setFillColor(baseColor)








setPosition(-130, 50)
right(160, 60)
left(90)
setHeading(70)
right(160, 60)

forward(30)
setHeading(268)
forward(30)
setHeading(265)
forward(30)
setHeading(255)
forward(40)
right(78,110)
setHeading(151)
right(68,210)

setPenColor(Color(255, 204, 0))
setPenThickness(20)


setPosition(-130, 60)
right(160, 60)
left(90)
setHeading(70)
right(160, 60)
setHeading(90)
setPenThickness(3)
val cl = cm.radialGradient(0, 0, Color(204, 204, 204), 100, white, true)

setPenColor(darkGray)
setFillColor(cl)
setHeading(50)
left(100,80)
setHeading(50)
left(100,20)
lineTo(0,250)

setPosition(-130, 60)
setHeading(125)
right(100,80)
setHeading(125)
right(100,20)
lineTo(0,250)

val c2= cm.radialGradient(0, 0, Color(204, 204, 204), 100, white, true)
setFillColor(c2)
def shape(len: Int) {
    repeat(2) {
        right(90, len)
        right()
    }
}

setSpeed(medium)

setPenThickness(2)

setPosition(-10,150)
repeatFor(rangeTo(1, 10)) { e =>
    repeatFor(rangeTo(1, 40)) { e =>
        
        setPenColor(darkGray)
        shape(e * 1 + 1)
        right(1)
    }
    left(40)
   right(36)
}

setPenColor(white)
setPenThickness(8)
setHeading(0)
setPosition(-50,50)
forward(65)
setPosition(-50,50)
setHeading(270)
setPenColor(noColor)
forward(10)
setHeading(0)
setPenColor(white)
forward(65)

setPosition(-50,50)
setHeading(270)
setPenColor(noColor)
forward(20)
setHeading(0)
setPenColor(white)
forward(65)

setPosition(-15,50)
setHeading(90)
setPenThickness(15)
forward(-15)
setPenColor(red)
setPenThickness(10)
forward(-5)

setPenThickness(3)
setFillColor(white)
setPenColor(white)
setPosition(-75,-15)
right(160,20)
setPosition(-75,-15)
left(160,20)



setPosition(50,-15)
left(160,20)
setPosition(50,-15)
right(160,20)


setPosition(-70,-10)
setFillColor(black)
right(360,15)


setPosition(-60,-10)
setFillColor(white)
right(360,3)


setPosition(15,-10)
setFillColor(black)
right(360,15)


setPosition(25,-10)
setFillColor(white)
right(360,3)

setPosition(-25,0)
setPenColor(black)
forward(-50)

setPenColor(noColor)
forward(-10)
setHeading(180)
invisible()
setPenColor(black)
setFillColor(noColor)
right(180,8)


setPosition(0,0)
setHeading(90)
setPenColor(black)
forward(-50)

setPenColor(noColor)
forward(-10)
setHeading(180)
invisible()
setPenColor(black)
setFillColor(noColor)
right(180,8)

visible()
setPosition(-20,-70 )
setPenColor(Color(51, 51, 51))
setHeading(180)
setPenThickness(10)
curve()
setPenColor(Color(51, 51, 51))
setHeading(26)
setPosition(-10,-68 )
curve2()





def curve2() {
    setPenColor(black)
   
    //setHeading(140)
    right(115, 20)
    setHeading(0)
    left(120, 10)
}
invisible()
setPosition(-50,-85)
setPenThickness(4)
setHeading(320)
left(90,50)
setPosition(-50,-70)
setHeading(320)
left(50,50)


setPosition(0,0)

val path="~/Downloads"

   val pic= Picture.image(s"$path/flowerRose.png")
  // val E1 = scale(0.3) -> pic
val look = picStack(
    scale(0.08)*trans(-1900, -2000)  *rot(30)-> pic,
    
)


val look2 = picStack(
    scale(0.08)*trans(-1500, -2500)  *rot(30)-> pic,
    
)
val look3= picStack(
    scale(0.08)*trans(-1000, -2900)  *rot(30)-> pic,
    
)

val look4= picStack(
    scale(0.08)*trans(-500, -3200)  *rot(30)-> pic,
    
)


val look5= picStack(
    scale(0.08)*trans(200, -3000)  *rot(30)-> pic,
    
)

val look6= picStack(
    scale(0.08)*trans(800, -2500)  *rot(30)-> pic,
    
)

val look7= picStack(
    scale(0.08)*trans(1000, -2000)  *rot(30)-> pic,
    
)


draw(look)
draw(look2)
draw(look3)

draw(look4)
draw(look5)
draw(look6)
draw(look7)


val pathh="~/Downloads"

   val pic2= Picture.image(s"$pathh/f11.png")
   val E1 = scale(0.3) -> pic
   val showf = picStack(
    scale(0.03)*trans(-5000, -2600)  *rot(30)-> pic2,
    
)
draw(showf)

val showg = picStack(
    scale(0.03)*trans(-5100, -1600)  *rot(30)-> pic2,
    
)



draw(showg)

val showh = picStack(
    scale(0.03)*trans(-5200, -800)  *rot(30)-> pic2,
    
)
draw(showh)



val showi = picStack(
    scale(0.03)*trans(-5230, -100)  *rot(30)-> pic2,
    
)
draw(showi)

val showj = picStack(
    scale(0.03)*trans(3400, -100)  *rot(30)-> pic2,
    
)
draw(showj)

val showk = picStack(
    scale(0.03)*trans(3400, -1200)  *rot(30)-> pic2,
    
)
draw(showk)



val showl = picStack(
    scale(0.03)*trans(3400, -2300)  *rot(30)-> pic2,
    
)
draw(showl)
setSpeed(superFast)
setPenColor(cm.white)
setPenThickness(3)


setPosition(-550, -250)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}

setPosition(-400, -250)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}

setPosition(-240, -250)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}



setPosition(-85, -280)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}

setPosition(85, -280)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}


setPosition(240, -250)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}

setPosition(400, -250)
setPenColor(purple)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}




setSpeed(superFast)
setPenColor(cm.white)
setPenColor(purple)
setPenThickness(3)
setPosition(550, -250)
repeatFor(rangeTo(1, 50)) { a =>
    repeat(60) {
        forward(a)
        right(50 * 2 + 120)
    }
    right(90)
}




val pathhh="~/Downloads"

   val image= Picture.image(s"$pathhh/omm.png")
   //val E1 = scale(0.3) -> pic
   val design = picStack(
    scale(1)*trans(-600, -170)  *rot(0)-> image,
    
)

draw(design)


val design2 = picStack(
    scale(1)*trans(235, -170)  *rot(0)-> image,
    
)

draw(design2)



setPenFontSize(40)
setPenColor(blue)
setPosition(-270,300)
setHeading(90)
setPenFont(Font("Algerian", 40))
        // write with Algerian font
write("||Shri Damodar Prasanna||")


setPenFontSize(20)
setPenFont(Font("Cambria", 30))
        // write with Cambria font
setPenColor(Color(0, 214, 239))
setPosition(-80,320)
setHeading(90)
write("Vasco Saptah")