![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
| |
| | #1 (permalink) |
| | Rendering Thread & 3d animation Hello, has anybody tried to animate objects (actually I'm trying to animate objects in 3d viewport) WITHOUT using the WPF animation system? I can't use the animation system because I'm trying to represents the evolution of a dynamic simulation. In the past, with GL or DirectX I was able to call a Render, says each hundred loops of simulation. But now I seem to be stuck with the WPF rendering system where I can't force the render wich is, from what I understood running in its own thread... I've made some tries with VisualTarget.Rendering event but it's called only when the rendering has been done and I've no way to force this rendering so it seems to be useless in my case... Is there any way to force the rendering based on a state inside the client Application? Thanks, Lois |
My System Specs![]() |
| | #2 (permalink) |
| | Re: Rendering Thread & 3d animation The CompositionTarget.Rendering event is probably what you're looking for... Florian |
My System Specs![]() |
| | #3 (permalink) |
| | Re: Rendering Thread & 3d animation Hi Lois, I know that Kevin Moore coded a Panel that uses the Rendering event to "animate" the position of the Panel items... This is availlable in the "Bag'O'Tricks" he generated... You can find it in his blog!!! http://blogs.msdn.com/okoboji/archiv...14/631433.aspx Hope this will help you! Lois Lacroux wrote: > Hello, > has anybody tried to animate objects (actually I'm trying to animate objects > in 3d viewport) WITHOUT using the WPF animation system? > > I can't use the animation system because I'm trying to represents the > evolution of a dynamic simulation. In the past, with GL or DirectX I was able > to call a Render, says each hundred loops of simulation. But now I seem to be > stuck with the WPF rendering system where I can't force the render wich is, > from what I understood running in its own thread... > > I've made some tries with VisualTarget.Rendering event but it's called only > when the rendering has been done and I've no way to force this rendering so > it seems to be useless in my case... > > Is there any way to force the rendering based on a state inside the client > Application? > > Thanks, > > Lois |
My System Specs![]() |
| | #4 (permalink) |
| | Re: Rendering Thread & 3d animation There are a couple of other options, each with its limitation: 1) Use CompositionTarget.Rendering: this gives you a callback before each frame is rendered. The drawback is this will be called at maximum framerate. You can choose to ignore renders if you don't need to change any objects. 2) Use RenderTargetBitmap, and render a Visual tree to that bitmap. The drawback is this is software only, so it may not be very performant for 3D objects. 3) Create your own object that derives from UIElement, and call InvalidateVisual() whenever you want a render to occur. This will eventually call OnRender() for the appropriate elements on your Visual tree. This would also have the benefit of only invalidating portions of the tree that have changed. Hope this helps. Thanks, Ed Maia [WPF PM] "Marcus" <larochem@gmail.com> wrote in message news:1152191194.182115.72670@j8g2000cwa.googlegroups.com... > Hi Lois, > > I know that Kevin Moore coded a Panel that uses the Rendering event > to "animate" the position of the Panel items... > > This is availlable in the "Bag'O'Tricks" he generated... You can > find it in his blog!!! > > http://blogs.msdn.com/okoboji/archiv...14/631433.aspx > > Hope this will help you! > > Lois Lacroux wrote: >> Hello, >> has anybody tried to animate objects (actually I'm trying to animate >> objects >> in 3d viewport) WITHOUT using the WPF animation system? >> >> I can't use the animation system because I'm trying to represents the >> evolution of a dynamic simulation. In the past, with GL or DirectX I was >> able >> to call a Render, says each hundred loops of simulation. But now I seem >> to be >> stuck with the WPF rendering system where I can't force the render wich >> is, >> from what I understood running in its own thread... >> >> I've made some tries with VisualTarget.Rendering event but it's called >> only >> when the rendering has been done and I've no way to force this rendering >> so >> it seems to be useless in my case... >> >> Is there any way to force the rendering based on a state inside the >> client >> Application? >> >> Thanks, >> >> Lois > |
My System Specs![]() |
| | #5 (permalink) |
| | RE: Rendering Thread & 3d animation I have a sample that does 3D z-ordering using the VisualTarget.Rendering at http://www.therhogue.com/WinFX - it's the collageview sample. It looks like Ed, gave you some other options too. "Lois Lacroux" wrote: > Hello, > has anybody tried to animate objects (actually I'm trying to animate objects > in 3d viewport) WITHOUT using the WPF animation system? > > I can't use the animation system because I'm trying to represents the > evolution of a dynamic simulation. In the past, with GL or DirectX I was able > to call a Render, says each hundred loops of simulation. But now I seem to be > stuck with the WPF rendering system where I can't force the render wich is, > from what I understood running in its own thread... > > I've made some tries with VisualTarget.Rendering event but it's called only > when the rendering has been done and I've no way to force this rendering so > it seems to be useless in my case... > > Is there any way to force the rendering based on a state inside the client > Application? > > Thanks, > > Lois > > |
My System Specs![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| How do the current thread get thread notification of OS intruption | .NET General | |||
| Start a new thread from an existing thread, which was started from atimer | .NET General | |||
| consent.exe not rendering | Vista security | |||
| games Rendering everywhere! | Vista Games | |||
| Page Rendering | Vista mail | |||