Page 1 of 6
Flame Painter Dev Thread
Posted: Thu Dec 30, 2010 7:56 pm
by xiphirx
Build 4:
http://arse.voidteam.net/Personal/fp4.zip (click to draw)
Build 3:
http://arse.voidteam.net/Personal/fp3.zip (click to draw)
Build 2:
http://arse.voidteam.net/Personal/fp2.zip
Build 1:
http://arse.voidteam.net/Personal/fp1.zip
http://www.escapemotions.com/experiment ... x.html#top
Please, someone, explain what type of math functions or algorithms are used for the trail?
I want to create something very similar to that D:
EDIT: It uses Processing http://processing.org/
And I noticed that the trails spiral into the cursor, but the spiral is jiggly...
Re: Question about Math and Algorithm
Posted: Thu Dec 30, 2010 8:04 pm
by Ginto8
I haven't really looked at the link, but the first thing I think of when I hear "fire painter" is this:
http://en.wikipedia.org/wiki/Computatio ... d_dynamics
Re: Question about Math and Algorithm
Posted: Thu Dec 30, 2010 8:08 pm
by xiphirx
That looks a bit off of what the application uses, maybe a bit too complicated for it..
Re: Question about Math and Algorithm
Posted: Thu Dec 30, 2010 9:22 pm
by avansc
Its just looks like a list of points, where each is attracted to each previous one, with the first one being attracted to the mouse, looks like some random noise is added. no real algorithm.
Re: Question about Math and Algorithm
Posted: Thu Dec 30, 2010 9:28 pm
by xiphirx
avansc wrote:Its just looks like a list of points, where each is attracted to each previous one, with the first one being attracted to the mouse, looks like some random noise is added. no real algorithm.
Okay that sounds right since that's all I observed... So attraction then.... That would be as easy as easing the movement on a vector from one point to another point right?
Re: Question about Math and Algorithm
Posted: Thu Dec 30, 2010 11:21 pm
by dandymcgee
xiphirx wrote:avansc wrote:Its just looks like a list of points, where each is attracted to each previous one, with the first one being attracted to the mouse, looks like some random noise is added. no real algorithm.
Okay that sounds right since that's all I observed... So attraction then.... That would be as easy as easing the movement on a vector from one point to another point right?
Sounds like a good start.
Re: Question about Math and Algorithm
Posted: Fri Dec 31, 2010 9:38 pm
by xiphirx
Hmm... Actually, looking at the "jigglyness", it seems like he uses the easing from
http://www.robertpenner.com/easing/easing_demo.html (choose easeInOutBack)
I'll try to start programing a prototype soon and post results.
Re: Question about Math and Algorithm
Posted: Fri Dec 31, 2010 10:09 pm
by avansc
Id probably just use the inverse of the gravitational constant, as i suspect that is what is going on there.
1/(gravitational_constant * m1*m1/r^2
r is the distance from the two bodies so dont mess with the sqrt
return m1.x*m2.x +m1.y*m2.y;
something like that.
ps: happy new new year folks.
Re: Question about Math and Algorithm
Posted: Fri Dec 31, 2010 10:25 pm
by xiphirx
Sorry, idiot terms please? lol I didn't understand all of that D:
What do m1 and m2 represent? and where do I use this equation, to move points to one another?
Re: Question about Math and Algorithm
Posted: Fri Dec 31, 2010 10:35 pm
by avansc
xiphirx wrote:Sorry, idiot terms please? lol I didn't understand all of that D:
What do m1 and m2 represent? and where do I use this equation, to move points to one another?
http://en.wikipedia.org/wiki/Newton's_l ... ravitation
altho i would apply only the force to the bodie "following"
Re: Question about Math and Algorithm
Posted: Tue Jan 04, 2011 1:32 pm
by xiphirx
Alright, I started to program my own version. I'll post builds as I finish them :P
http://arse.voidteam.net/Personal/fp1.zip
Re: Question about Math and Algorithm
Posted: Tue Jan 04, 2011 1:57 pm
by thejahooli
That is awesome. I played with it for about 10 minutes and now I really want to make my own program like this.
Re: Question about Math and Algorithm
Posted: Tue Jan 04, 2011 3:31 pm
by Singleton
Haha pretty nice application, seeing cool stuff like that is really inspirational, as thejahooli said. Good job
Re: Question about Math and Algorithm
Posted: Tue Jan 04, 2011 4:41 pm
by dandymcgee
That would make an awesome screensaver.
Re: Question about Math and Algorithm
Posted: Tue Jan 04, 2011 4:46 pm
by xiphirx
Another build, I think I'm digressing from the original goal, oh well, I think its cool D:
http://arse.voidteam.net/Personal/fp2.zip