dir.by  
  Search  
Programming, development, testing
p5.js - JavaScript library for drawing graphics 2D (drawing pictures, lines, movements), 3D graphics (Drawing materials, light, texture)
Пример "рисуем эллипс" | p5.js
  Looked at 3037 times    
 Пример "рисуем эллипс" | p5.js 
last updated: 14 March 2020
Создаем файл 1.html
  Html     File 1.html
<html>
     <head>
          <script src="https://dir.by/example_lib/p5_js/p5.min.js"></script>
     </head>

     <script>
          // function setup() Required. It is used by the library p5.js
          function setup() {

               // create canvas
               createCanvas(320, 280); // function is declared in p5.js
          }

          // function draw() Required. It is used by the library p5.js
          function draw() {

               // fill canvas by gray color
               background("#EEEEEE"); // function is declared in p5.js

               // draw ellipse (function from p5.js)
               ellipse(50, 50, 80, 80); // function is declared in p5.js
          }
     </script>

     <body>
     </body>

</html>
Example we look, we test
 
← Previous topic
p5.js where to download and how to connect?
 
Next topic →
image
 
Your feedback ... Comments ...
   
Your Name
Your comment (www links can only be added by a logged-in user)

  Объявления  
  Объявления  
 
What the p5.js ?
p5.js where to download and how to connect?
Пример "рисуем эллипс" | p5.js
image

  Ваши вопросы присылайте по почте: info@dir.by  
Яндекс.Метрика