This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://processing.org/reference/saveFrame_.html | |
void mousePressed() { | |
// enregistre chaque frame -> screen-0001.tif, screen-0002.tif, etc. | |
saveFrame(); | |
// ou | |
// enregistre chaque frame -> line-000001.png, line-000002.png, etc. | |
saveFrame("line-######.png"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int circleFillColor = 0; | |
void setup() { | |
// la taille du canvas (fenêtre) | |
size(500, 500); | |
} | |
void draw() { | |
// les couleurs varient entre 0 et 255 | |
circleFillColor = circleFillColor + 1; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int startX, startY, endX, endY; | |
int red, green, blue; | |
void setup() { | |
startX = (width / 2) - 100; | |
startY = (height / 2) - 100; | |
endX = (width / 2) + 100; | |
endY = (height / 2) + 100; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script setup> | |
import paper from "paper" | |
import { ref, onMounted } from 'vue' | |
const canvas = ref(null) | |
onMounted(()=>{ | |
paper.setup(canvas.value); | |
var path = new paper.Path(); | |
path.strokeColor = 'black'; |