Enviar pesquisa
Carregar
Proga 0622
•
1 gostou
•
650 visualizações
Atsushi Tadokoro
Seguir
Educação
Denunciar
Compartilhar
Denunciar
Compartilhar
1 de 47
Baixar agora
Baixar para ler offline
Recomendados
The Ring programming language version 1.10 book - Part 64 of 212
The Ring programming language version 1.10 book - Part 64 of 212
Mahmoud Samir Fayed
Intro to Game Programming
Intro to Game Programming
Richard Jones
The Ring programming language version 1.5.1 book - Part 51 of 180
The Ring programming language version 1.5.1 book - Part 51 of 180
Mahmoud Samir Fayed
ES6(ES2015) is beautiful
ES6(ES2015) is beautiful
monikagupta18jan
Gazr
Gazr
kuro7
Introduction to Game Programming Tutorial
Introduction to Game Programming Tutorial
Richard Jones
ตัวอย่างข้อสอบเก่า วิชาคณิตศาสตร์ ม.6 ปีการศึกษา 2553
ตัวอย่างข้อสอบเก่า วิชาคณิตศาสตร์ ม.6 ปีการศึกษา 2553
Destiny Nooppynuchy
Mobile Gameand Application with J2ME
Mobile Gameand Application with J2ME
Jenchoke Tachagomain
Recomendados
The Ring programming language version 1.10 book - Part 64 of 212
The Ring programming language version 1.10 book - Part 64 of 212
Mahmoud Samir Fayed
Intro to Game Programming
Intro to Game Programming
Richard Jones
The Ring programming language version 1.5.1 book - Part 51 of 180
The Ring programming language version 1.5.1 book - Part 51 of 180
Mahmoud Samir Fayed
ES6(ES2015) is beautiful
ES6(ES2015) is beautiful
monikagupta18jan
Gazr
Gazr
kuro7
Introduction to Game Programming Tutorial
Introduction to Game Programming Tutorial
Richard Jones
ตัวอย่างข้อสอบเก่า วิชาคณิตศาสตร์ ม.6 ปีการศึกษา 2553
ตัวอย่างข้อสอบเก่า วิชาคณิตศาสตร์ ม.6 ปีการศึกษา 2553
Destiny Nooppynuchy
Mobile Gameand Application with J2ME
Mobile Gameand Application with J2ME
Jenchoke Tachagomain
Mobile Gameand Application withJ2ME - Collision Detection
Mobile Gameand Application withJ2ME - Collision Detection
Jenchoke Tachagomain
Disney Effects: Building web/mobile castle in OpenGL 2D & 3D
Disney Effects: Building web/mobile castle in OpenGL 2D & 3D
SVWB
The Ring programming language version 1.7 book - Part 48 of 196
The Ring programming language version 1.7 book - Part 48 of 196
Mahmoud Samir Fayed
The Ring programming language version 1.4 book - Part 16 of 30
The Ring programming language version 1.4 book - Part 16 of 30
Mahmoud Samir Fayed
662305 LAB13
662305 LAB13
Nitigan Nakjuatong
The Ring programming language version 1.5 book - Part 8 of 31
The Ring programming language version 1.5 book - Part 8 of 31
Mahmoud Samir Fayed
openGl example
openGl example
Brian Goggins
Raspberry Pi à la GroovyFX
Raspberry Pi à la GroovyFX
Stephen Chin
The Ring programming language version 1.3 book - Part 50 of 88
The Ring programming language version 1.3 book - Part 50 of 88
Mahmoud Samir Fayed
Javasccript MV* frameworks
Javasccript MV* frameworks
Kerry Buckley
NTU ML TENSORFLOW
NTU ML TENSORFLOW
Mark Chang
The Ring programming language version 1.5.1 book - Part 57 of 180
The Ring programming language version 1.5.1 book - Part 57 of 180
Mahmoud Samir Fayed
mobl
mobl
Eelco Visser
Corona sdk
Corona sdk
Dom Dominic Toretto
X2 T06 01 Discs & Washers
X2 T06 01 Discs & Washers
Nigel Simmons
ECMAScript 6 major changes
ECMAScript 6 major changes
hayato
The Ring programming language version 1.5.4 book - Part 68 of 185
The Ring programming language version 1.5.4 book - Part 68 of 185
Mahmoud Samir Fayed
Computational Linguistics week 10
Computational Linguistics week 10
Mark Chang
Sokoban Game Development Using Java ( Updated using Screenshots & Class Diagr...
Sokoban Game Development Using Java ( Updated using Screenshots & Class Diagr...
British Council
The Ring programming language version 1.4.1 book - Part 18 of 31
The Ring programming language version 1.4.1 book - Part 18 of 31
Mahmoud Samir Fayed
Web Presen1 0625
Web Presen1 0625
Atsushi Tadokoro
Proga 0601
Proga 0601
Atsushi Tadokoro
Mais conteúdo relacionado
Mais procurados
Mobile Gameand Application withJ2ME - Collision Detection
Mobile Gameand Application withJ2ME - Collision Detection
Jenchoke Tachagomain
Disney Effects: Building web/mobile castle in OpenGL 2D & 3D
Disney Effects: Building web/mobile castle in OpenGL 2D & 3D
SVWB
The Ring programming language version 1.7 book - Part 48 of 196
The Ring programming language version 1.7 book - Part 48 of 196
Mahmoud Samir Fayed
The Ring programming language version 1.4 book - Part 16 of 30
The Ring programming language version 1.4 book - Part 16 of 30
Mahmoud Samir Fayed
662305 LAB13
662305 LAB13
Nitigan Nakjuatong
The Ring programming language version 1.5 book - Part 8 of 31
The Ring programming language version 1.5 book - Part 8 of 31
Mahmoud Samir Fayed
openGl example
openGl example
Brian Goggins
Raspberry Pi à la GroovyFX
Raspberry Pi à la GroovyFX
Stephen Chin
The Ring programming language version 1.3 book - Part 50 of 88
The Ring programming language version 1.3 book - Part 50 of 88
Mahmoud Samir Fayed
Javasccript MV* frameworks
Javasccript MV* frameworks
Kerry Buckley
NTU ML TENSORFLOW
NTU ML TENSORFLOW
Mark Chang
The Ring programming language version 1.5.1 book - Part 57 of 180
The Ring programming language version 1.5.1 book - Part 57 of 180
Mahmoud Samir Fayed
mobl
mobl
Eelco Visser
Corona sdk
Corona sdk
Dom Dominic Toretto
X2 T06 01 Discs & Washers
X2 T06 01 Discs & Washers
Nigel Simmons
ECMAScript 6 major changes
ECMAScript 6 major changes
hayato
The Ring programming language version 1.5.4 book - Part 68 of 185
The Ring programming language version 1.5.4 book - Part 68 of 185
Mahmoud Samir Fayed
Computational Linguistics week 10
Computational Linguistics week 10
Mark Chang
Sokoban Game Development Using Java ( Updated using Screenshots & Class Diagr...
Sokoban Game Development Using Java ( Updated using Screenshots & Class Diagr...
British Council
The Ring programming language version 1.4.1 book - Part 18 of 31
The Ring programming language version 1.4.1 book - Part 18 of 31
Mahmoud Samir Fayed
Mais procurados
(20)
Mobile Gameand Application withJ2ME - Collision Detection
Mobile Gameand Application withJ2ME - Collision Detection
Disney Effects: Building web/mobile castle in OpenGL 2D & 3D
Disney Effects: Building web/mobile castle in OpenGL 2D & 3D
The Ring programming language version 1.7 book - Part 48 of 196
The Ring programming language version 1.7 book - Part 48 of 196
The Ring programming language version 1.4 book - Part 16 of 30
The Ring programming language version 1.4 book - Part 16 of 30
662305 LAB13
662305 LAB13
The Ring programming language version 1.5 book - Part 8 of 31
The Ring programming language version 1.5 book - Part 8 of 31
openGl example
openGl example
Raspberry Pi à la GroovyFX
Raspberry Pi à la GroovyFX
The Ring programming language version 1.3 book - Part 50 of 88
The Ring programming language version 1.3 book - Part 50 of 88
Javasccript MV* frameworks
Javasccript MV* frameworks
NTU ML TENSORFLOW
NTU ML TENSORFLOW
The Ring programming language version 1.5.1 book - Part 57 of 180
The Ring programming language version 1.5.1 book - Part 57 of 180
mobl
mobl
Corona sdk
Corona sdk
X2 T06 01 Discs & Washers
X2 T06 01 Discs & Washers
ECMAScript 6 major changes
ECMAScript 6 major changes
The Ring programming language version 1.5.4 book - Part 68 of 185
The Ring programming language version 1.5.4 book - Part 68 of 185
Computational Linguistics week 10
Computational Linguistics week 10
Sokoban Game Development Using Java ( Updated using Screenshots & Class Diagr...
Sokoban Game Development Using Java ( Updated using Screenshots & Class Diagr...
The Ring programming language version 1.4.1 book - Part 18 of 31
The Ring programming language version 1.4.1 book - Part 18 of 31
Destaque
Web Presen1 0625
Web Presen1 0625
Atsushi Tadokoro
Proga 0601
Proga 0601
Atsushi Tadokoro
Web Presen1 0709
Web Presen1 0709
Atsushi Tadokoro
Tau Web0609
Tau Web0609
Atsushi Tadokoro
Sbaw090623
Sbaw090623
Atsushi Tadokoro
Proga 0615
Proga 0615
Atsushi Tadokoro
Meteor.js for DOers
Meteor.js for DOers
ShavonnahTiera
Destaque
(7)
Web Presen1 0625
Web Presen1 0625
Proga 0601
Proga 0601
Web Presen1 0709
Web Presen1 0709
Tau Web0609
Tau Web0609
Sbaw090623
Sbaw090623
Proga 0615
Proga 0615
Meteor.js for DOers
Meteor.js for DOers
Semelhante a Proga 0622
Create a java project that - Draw a circle with three random init.pdf
Create a java project that - Draw a circle with three random init.pdf
arihantmobileselepun
Proga 090525
Proga 090525
Atsushi Tadokoro
Ocr code
Ocr code
wi7sonjoseph
Ssaw08 0624
Ssaw08 0624
Atsushi Tadokoro
Include
Include
Munkherdene Batsaikhan
[3] 프로세싱과 아두이노
[3] 프로세싱과 아두이노
Chiwon Song
ARTDM 170, Week 13: Text Elements + Arrays
ARTDM 170, Week 13: Text Elements + Arrays
Gilbert Guerrero
Proga 0518
Proga 0518
Atsushi Tadokoro
Proga 0706
Proga 0706
Atsushi Tadokoro
Matlab assignment
Matlab assignment
Rutvik
Creating an Uber Clone - Part IV.pdf
Creating an Uber Clone - Part IV.pdf
ShaiAlmog1
C Code and the Art of Obfuscation
C Code and the Art of Obfuscation
guest9006ab
Grand centraldispatch
Grand centraldispatch
Yuumi Yoshida
Haskellで学ぶ関数型言語
Haskellで学ぶ関数型言語
ikdysfm
PRACTICAL COMPUTING
PRACTICAL COMPUTING
Ramachendran Logarajah
Numerical Method Assignment
Numerical Method Assignment
ashikul akash
import java.util.Scanner;public class Main { public static in.pdf
import java.util.Scanner;public class Main { public static in.pdf
anwarsadath111
Beyond Scala Lens
Beyond Scala Lens
Julien Truffaut
Exploring Canvas
Exploring Canvas
Kevin Hoyt
package chapter15;import javafx.application.Application;import j.pdf
package chapter15;import javafx.application.Application;import j.pdf
KARTIKINDIA
Semelhante a Proga 0622
(20)
Create a java project that - Draw a circle with three random init.pdf
Create a java project that - Draw a circle with three random init.pdf
Proga 090525
Proga 090525
Ocr code
Ocr code
Ssaw08 0624
Ssaw08 0624
Include
Include
[3] 프로세싱과 아두이노
[3] 프로세싱과 아두이노
ARTDM 170, Week 13: Text Elements + Arrays
ARTDM 170, Week 13: Text Elements + Arrays
Proga 0518
Proga 0518
Proga 0706
Proga 0706
Matlab assignment
Matlab assignment
Creating an Uber Clone - Part IV.pdf
Creating an Uber Clone - Part IV.pdf
C Code and the Art of Obfuscation
C Code and the Art of Obfuscation
Grand centraldispatch
Grand centraldispatch
Haskellで学ぶ関数型言語
Haskellで学ぶ関数型言語
PRACTICAL COMPUTING
PRACTICAL COMPUTING
Numerical Method Assignment
Numerical Method Assignment
import java.util.Scanner;public class Main { public static in.pdf
import java.util.Scanner;public class Main { public static in.pdf
Beyond Scala Lens
Beyond Scala Lens
Exploring Canvas
Exploring Canvas
package chapter15;import javafx.application.Application;import j.pdf
package chapter15;import javafx.application.Application;import j.pdf
Mais de Atsushi Tadokoro
「クリエイティブ・ミュージック・コーディング」- オーディオ・ビジュアル作品のための、オープンソースなソフトウエア・フレームワークの現状と展望
「クリエイティブ・ミュージック・コーディング」- オーディオ・ビジュアル作品のための、オープンソースなソフトウエア・フレームワークの現状と展望
Atsushi Tadokoro
プログラム初級講座 - メディア芸術をはじめよう
プログラム初級講座 - メディア芸術をはじめよう
Atsushi Tadokoro
Interactive Music II ProcessingとSuperColliderの連携 -2
Interactive Music II ProcessingとSuperColliderの連携 -2
Atsushi Tadokoro
coma Creators session vol.2
coma Creators session vol.2
Atsushi Tadokoro
Interactive Music II ProcessingとSuperColliderの連携1
Interactive Music II ProcessingとSuperColliderの連携1
Atsushi Tadokoro
Interactive Music II Processingによるアニメーション
Interactive Music II Processingによるアニメーション
Atsushi Tadokoro
Interactive Music II Processing基本
Interactive Music II Processing基本
Atsushi Tadokoro
Interactive Music II SuperCollider応用 2 - SuperColliderとPure Dataの連携
Interactive Music II SuperCollider応用 2 - SuperColliderとPure Dataの連携
Atsushi Tadokoro
Media Art II openFrameworks アプリ間の通信とタンジブルなインターフェイス
Media Art II openFrameworks アプリ間の通信とタンジブルなインターフェイス
Atsushi Tadokoro
Interactive Music II SuperCollider応用 - SuperColliderと OSC (Open Sound Control)
Interactive Music II SuperCollider応用 - SuperColliderと OSC (Open Sound Control)
Atsushi Tadokoro
iTamabi 13 ARTSAT API 実践 5 - 衛星の軌道を描く
iTamabi 13 ARTSAT API 実践 5 - 衛星の軌道を描く
Atsushi Tadokoro
メディア芸術基礎 II 第11回:HTML5実践 表現のための様々なJavaScriptライブラリ
メディア芸術基礎 II 第11回:HTML5実践 表現のための様々なJavaScriptライブラリ
Atsushi Tadokoro
芸術情報演習デザイン(Web) 第8回: CSSフレームワークを使う
芸術情報演習デザイン(Web) 第8回: CSSフレームワークを使う
Atsushi Tadokoro
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 2
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 2
Atsushi Tadokoro
iTamabi 13 第9回:ARTSAT API 実践 3 ジオコーディングで衛星の位置を取得
iTamabi 13 第9回:ARTSAT API 実践 3 ジオコーディングで衛星の位置を取得
Atsushi Tadokoro
Tamabi media131118
Tamabi media131118
Atsushi Tadokoro
Webデザイン 第10回:HTML5実践 Three.jsで3Dプログラミング
Webデザイン 第10回:HTML5実践 Three.jsで3Dプログラミング
Atsushi Tadokoro
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 1
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 1
Atsushi Tadokoro
iTamabi 13 第8回:ARTSAT API 実践 2 衛星アプリを企画する
iTamabi 13 第8回:ARTSAT API 実践 2 衛星アプリを企画する
Atsushi Tadokoro
Media Art II openFrameworks 複数のシーンの管理・切替え
Media Art II openFrameworks 複数のシーンの管理・切替え
Atsushi Tadokoro
Mais de Atsushi Tadokoro
(20)
「クリエイティブ・ミュージック・コーディング」- オーディオ・ビジュアル作品のための、オープンソースなソフトウエア・フレームワークの現状と展望
「クリエイティブ・ミュージック・コーディング」- オーディオ・ビジュアル作品のための、オープンソースなソフトウエア・フレームワークの現状と展望
プログラム初級講座 - メディア芸術をはじめよう
プログラム初級講座 - メディア芸術をはじめよう
Interactive Music II ProcessingとSuperColliderの連携 -2
Interactive Music II ProcessingとSuperColliderの連携 -2
coma Creators session vol.2
coma Creators session vol.2
Interactive Music II ProcessingとSuperColliderの連携1
Interactive Music II ProcessingとSuperColliderの連携1
Interactive Music II Processingによるアニメーション
Interactive Music II Processingによるアニメーション
Interactive Music II Processing基本
Interactive Music II Processing基本
Interactive Music II SuperCollider応用 2 - SuperColliderとPure Dataの連携
Interactive Music II SuperCollider応用 2 - SuperColliderとPure Dataの連携
Media Art II openFrameworks アプリ間の通信とタンジブルなインターフェイス
Media Art II openFrameworks アプリ間の通信とタンジブルなインターフェイス
Interactive Music II SuperCollider応用 - SuperColliderと OSC (Open Sound Control)
Interactive Music II SuperCollider応用 - SuperColliderと OSC (Open Sound Control)
iTamabi 13 ARTSAT API 実践 5 - 衛星の軌道を描く
iTamabi 13 ARTSAT API 実践 5 - 衛星の軌道を描く
メディア芸術基礎 II 第11回:HTML5実践 表現のための様々なJavaScriptライブラリ
メディア芸術基礎 II 第11回:HTML5実践 表現のための様々なJavaScriptライブラリ
芸術情報演習デザイン(Web) 第8回: CSSフレームワークを使う
芸術情報演習デザイン(Web) 第8回: CSSフレームワークを使う
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 2
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 2
iTamabi 13 第9回:ARTSAT API 実践 3 ジオコーディングで衛星の位置を取得
iTamabi 13 第9回:ARTSAT API 実践 3 ジオコーディングで衛星の位置を取得
Tamabi media131118
Tamabi media131118
Webデザイン 第10回:HTML5実践 Three.jsで3Dプログラミング
Webデザイン 第10回:HTML5実践 Three.jsで3Dプログラミング
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 1
Interactive Music II SuperCollider応用 JITLib - ライブコーディング 1
iTamabi 13 第8回:ARTSAT API 実践 2 衛星アプリを企画する
iTamabi 13 第8回:ARTSAT API 実践 2 衛星アプリを企画する
Media Art II openFrameworks 複数のシーンの管理・切替え
Media Art II openFrameworks 複数のシーンの管理・切替え
Último
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
Association for Project Management
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
RaunakKeshri1
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
heathfieldcps1
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
RAM LAL ANAND COLLEGE, DELHI UNIVERSITY.
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
Jayanti Pande
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
eniolaolutunde
9548086042 for call girls in Indira Nagar with room service
9548086042 for call girls in Indira Nagar with room service
discovermytutordmt
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
GeoBlogs
microwave assisted reaction. General introduction
microwave assisted reaction. General introduction
Maksud Ahmed
Measures of Dispersion and Variability: Range, QD, AD and SD
Measures of Dispersion and Variability: Range, QD, AD and SD
Thiyagu K
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
sanyamsingh5019
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
misteraugie
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
Celine George
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
GaneshChakor2
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
Shobhayan Kirtania
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
fonyou31
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
EduSkills OECD
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
dawncurless
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
SafetyChain Software
Último
(20)
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
9548086042 for call girls in Indira Nagar with room service
9548086042 for call girls in Indira Nagar with room service
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
microwave assisted reaction. General introduction
microwave assisted reaction. General introduction
Measures of Dispersion and Variability: Range, QD, AD and SD
Measures of Dispersion and Variability: Range, QD, AD and SD
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
Proga 0622
1.
2.
3.
•
F = -kx k F = -kx ma = -kx x = -sin k t m x = Csin(!t + " x
4.
springForce = -stiffness
* stretch springForce = -stiffness * (position - restPosition)
5.
•
springForce = stiffness * (restPositon - position) velocity = friction * (velocity + springFroce)
6.
float stiffness =
0.1; // float damping = 0.9; // float velocity = 0.0; // float targetY; // float y; // void setup() { size(400, 400); noStroke(); } void draw() { fill(0, 12); rect(0, 0, width, height); fill(255); float force = stiffness * (targetY - y); // f = -kx velocity = damping * (velocity + force); // y += velocity; // rect(10, y, width - 20, 10); // targetY = mouseY; // Y }
7.
8.
•
F = ma a=F/m acceleration = springForce / mass
9.
//2 float y1, y2;
// float velocity1, velocity2; // float mass1 = 1.0; // 1 float mass2 = 6.0; // 2 float stiffness = 0.1; // float damping = 0.9; // void setup() { size(400, 400); noStroke(); } void draw() { fill(0, 12); rect(0, 0, width, height); fill(255); float targetY = mouseY; // // 1 float forceA = stiffness * (targetY - y1); // float accelerationY1 = forceA / mass1; // velocity1 = damping * (velocity1 + accelerationY1); // y1 += velocity1; //
10.
rect(0, y1, width/2,
15); // 2 float forceB = stiffness * (targetY - y2); // float accelerationY2 = forceB / mass2; // velocity2 = damping * (velocity2 + accelerationY2); // y2 += velocity2; // rect(width/2, y2, width/2, 15); }
11.
12.
13.
float
stiffness = 0.05; float damping = 0.9; float mass = 3.0; float gravity = 0.0; float velocityX = 0.0, velocityY = 0.0; float targetX, targetY; float x, y; void setup() { size(600, 600); smooth(); } void draw() { background(0); //X float forceX = stiffness * (targetX - x); float accelerationX = forceX / mass; velocityX = damping * (velocityX + accelerationX); x += velocityX; //Y float forceY = stiffness * (targetY - y); forceY += gravity; float accelerationY = forceY / mass; velocityY = damping * (velocityY + accelerationY); y += velocityY;
14.
//
noStroke(); fill(255); ellipse(x, y, 40, 40); // stroke(127); noFill(); line(mouseX, mouseY, x, y); // targetX = mouseX; targetY = mouseY; }
15.
16.
17.
//Spring2D Spring2D s1, s2; float
gravity = 5.0; float mass = 2.0; void setup() { size(400, 400); smooth(); fill(0); // x , y , , s1 = new Spring2D(0.0, width / 2, mass, gravity); s2 = new Spring2D(0.0, width / 2, mass, gravity); } void draw() { background(204); s1.update(mouseX, mouseY); s1.display(mouseX, mouseY); s2.update(s1.x, s1.y); s2.display(s1.x, s1.y); }
18.
// class
Spring2D // class Spring2D { float vx, vy; float x, y; float gravity; float mass; float radius = 10; float stiffness = 0.2; float damping = 0.7; // Spring2D(float xpos, float ypos, float m, float g) { x = xpos; y = ypos; mass = m; gravity = g; } // void update(float targetX, float targetY) { float forceX = (targetX - x) * stiffness; float ax = forceX / mass; vx = damping * (vx + ax); x += vx; float forceY = (targetY - y) * stiffness;
19.
forceY += gravity;
float ay = forceY / mass; vy = damping * (vy + ay); y += vy; } // void display(float nx, float ny) { noStroke(); ellipse(x, y, radius*2, radius*2); stroke(255); line(x, y, nx, ny); } }
20.
21.
22.
// int numSprings =
10; // Spring2D[] s = new Spring2D[numSprings]; float gravity = 5.0; float mass = 5.0; float stiffness = 0.2; float damping = 0.8; void setup() { size(600, 600); smooth(); fill(0); for (int i = 0; i < numSprings; i++) { s[i] = new Spring2D(width / 2, i*(height / numSprings), mass, gravity, stiffness, damping); } } void draw() { background(204); s[0].update(mouseX, mouseY); s[0].display(mouseX, mouseY); for (int i = 1; i < numSprings; i++) { s[i].update(s[i-1].x, s[i-1].y); s[i].display(s[i-1].x, s[i-1].y); } }
23.
24.
25.
26.
27.
28.
import traer.physics.*; ParticleSystem physics; Particle
mouse; Particle[] p; Spring[] s; void setup(){ size( 400, 400 ); smooth(); //Physics physics = new ParticleSystem( 1.0, 0.05 ); p = new Particle[10]; s = new Spring[10]; // for(int i = 0; i < p.length; i++){ p[i] = physics.makeParticle( 1.0, width/2, 20 * i, 0); if(i > 0){ s[i] = physics.makeSpring( p[i], p[i-1], 1.0, 0.1, 20); } } // p[0].makeFixed(); }
29.
void draw(){
background(0); physics.tick(); // p[0].moveTo(mouseX, mouseY, 0); // for(int i = 0; i < p.length; i++){ noStroke(); fill(128); ellipse( p[i].position().x(), p[i].position().y(), 10, 10 ); if(i > 0){ stroke(255); line(p[i].position().x(), p[i].position().y(), p[i-1].position().x(), p[i-1].position().y()); } } }
30.
31.
32.
p[0]
p[1] p[2] p[3] ... p[n] p[1] p[2] p[3] p[4] for(int i = 0; i < n; i++){ ... • • for(j = i + 1; j < n; j++){ p[n] • p[2] p[3] • } p[4] • } p[5] ... ... p[n] p[n]
33.
import processing.opengl.*; import traer.physics.*; ParticleSystem
physics; Particle[] particles; int num = 80; void setup(){ size(800, 800, OPENGL ); fill(255); smooth(); rectMode(CENTER); physics = new ParticleSystem(0, 0.0); particles = new Particle[num]; for (int i = 0; i < num; i++){ particles[i] = physics.makeParticle(0.2, random(width), random(height), 0); for (int j = i + 1; j < num; j++){ particles[j] = physics.makeParticle(0.2, random(width), random(height), 0); particles[j].setMass(0.5); physics.makeSpring(particles[i], particles[j], 0.1, 0.0, width/2); } } }
34.
void draw(){
physics.tick(0.01); background(0); for (int i = 0; i < num; i++){ rect(particles[i].position().x(), particles[i].position().y(), 8, 8); } }
35.
36.
37.
import processing.opengl.*; import traer.physics.*; ParticleSystem
physics; Particle[] particles; int num = 80; void setup(){ size(800, 800, OPENGL ); fill(255); smooth(); rectMode(CENTER); physics = new ParticleSystem(0, 0.0); particles = new Particle[num]; for (int i = 0; i < num; i++){ particles[i] = physics.makeParticle(0.2, random(width), random(height), 0); for (int j = i + 1; j < num; j++){ particles[j] = physics.makeParticle(0.2, random(width), random(height), 0); particles[j].setMass(0.5); physics.makeSpring(particles[i], particles[j], 0.1, 0.0, width/2); } } }
38.
void
draw(){ physics.tick(0.01); background(0); for (int i = 0; i < num; i++){ fill(255); noStroke(); rect(particles[i].position().x(), particles[i].position().y(), 8, 8); stroke(127,50); //Spring line for (int j = i + 1; j < num; j++){ line(particles[j].position().x(), particles[j].position().y(), particles[i].position().x(), particles[i].position().y()); } } }
39.
40.
41.
import processing.opengl.*; import traer.physics.*; ParticleSystem
physics; Particle[] particles; int num = 80; void setup(){ size(800, 800, OPENGL ); fill(255); smooth(); rectMode(CENTER); physics = new ParticleSystem(0, 0.0); particles = new Particle[num]; for (int i = 0; i < num; i++){ particles[i] = physics.makeParticle(0.2, random(width), random(height), 0); for (int j = i + 1; j < num; j++){ particles[j] = physics.makeParticle(0.2, random(width), random(height), 0); particles[j].setMass(0.5); physics.makeSpring(particles[i], particles[j], 0.1, 0.0, width/2); } } }
42.
void
draw(){ physics.tick(0.01); background(0); for (int i = 0; i < num; i++){ rect(particles[i].position().x(), particles[i].position().y(), 4, 4); for (int j = i + 1; j < num; j++){ float l = dist(particles[j].position().x(), particles[j].position().y(), particles[i].position().x(), particles[i].position().y()); stroke(255, 100 - l); line(particles[j].position().x(), particles[j].position().y(), particles[i].position().x(), particles[i].position().y()); } } }
43.
44.
45.
import processing.opengl.*; import traer.physics.*; ParticleSystem
physics; Particle[] particles; int num = 80; void setup(){ size(800, 800, OPENGL ); smooth(); fill(255); rectMode(CENTER); physics = new ParticleSystem(0, 0.0); particles = new Particle[num]; for (int i = 0; i < num; i++){ particles[i] = physics.makeParticle(0.2, random(width), random(height), 0); for (int j = i + 1; j < num; j++){ particles[j] = physics.makeParticle(0.2, random(width), random(height), 0); particles[j].setMass(0.5); physics.makeAttraction(particles[i], particles[j], 1000, width); } } }
46.
void draw(){
physics.tick(1); background(0); for (int i = 0; i < num; i++) { rect(particles[i].position().x(), particles[i].position().y(), 3, 3); for (int j = i + 1; j < num; j++) { float l = dist(particles[j].position().x(), particles[j].position().y(), particles[i].position().x(), particles[i].position().y()); stroke(255, 100 - l); line(particles[j].position().x(), particles[j].position().y(), particles[i].position().x(), particles[i].position().y()); } } }
Baixar agora