i am moving from AS3 and Java to Expression Blend/WPF, but cant seem to figure out how to replicate EnterFrame
event in C#, is there a update()
or frameUpdate()
function.
Asked
Active
Viewed 1,025 times
1

Ankit
- 11
- 2
2 Answers
1
this should be helpful: http://www.shinedraw.com/mathematics/difference-on-timer-enter-frame-dispatcher-timer-and-composition-target/
and this too
http://insideria.com/2009/01/scripted-animation-in-silverli.html

Eugene
- 2,226
- 1
- 14
- 15
-
+1, Silverlight handles animation very differently from Flash - arguably, more efficiently, but makes some tasks harder than in AS. Storyboards should be the way to go; however, even in Flash, framerate dependent scripting shouldn't be used unless it really is suitable for the task, and you don't care about the _actual_ time spent each frame, because it _will_ be variable. Silverlight disposes of this problem altogether by enforcing (to some extent) time-based animation/scripting. – Alex Paven Sep 01 '10 at 08:44
0
CompositionTarget.Rendering is called every frame. You could also use timer such as DispatcherTimer.

Kris
- 7,110
- 2
- 24
- 26