Monday, October 24, 2016

HTML Logo

Above is the screenshot of the Beats logo I created using HTML. Below is the link to view the image on the web,

file:///Volumes/Student%20Server/Fall%202016/ART/ART%20210%20A%20-%20Foundations%20Digital%20Media%20-%20Corrigan/Student%20Work/Jetta%20Taylor/BeatsLogo.html

Below is the code I used to create this image as well as the graphed image.

<!DOCTYPE HTML>
<html>
<head>
<script>
window.onload = function() {
var canvas = document.getElementById("myCanvas");
var context = canvas.getContext("2d");

////////////////////////////////////// start below this line ˇˇˇˇˇˇˇˇˇˇ

context.beginPath();
context.arc(300, 300, 300, 0, 2*Math.PI, true);  
context.fillStyle = 'rgb(255, 0, 0)';
context.fill();

context.beginPath();
context.arc(300, 300, 150, 0, 2*Math.PI, true); 
context.fillStyle = 'rgb(255, 255, 255)';
context.fill();

context.beginPath();  
context.rect(150.3, 9, 75, 310); 
context.lineWidth = '10'; 
context.fillStyle = 'white';
context.fill();

context.beginPath();
context.arc(300, 300, 87.5, 0, 2*Math.PI, true);  
context.fillStyle = 'rgb(255, 0, 0)';
context.fill();









////////////////////////////////////// end above this line ˆˆˆˆˆˆˆˆˆˆˆˆˆˆˆ

};

</script>
</head>
<body>
<canvas id="myCanvas" width="800" height="600"></canvas>
</body>
</html>




No comments:

Post a Comment