Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm currently developing a 2D, top-down Windows Phone 7 game involving the surface of a pond. I'm trying to make the surface feel like actual water (as opposed to just a blue background with sprites drawn on top of it), and one of the effects I'm looking into is a sort of aquatic distortion effect. Basically, something similar to the first few seconds of this:

Any idea on how to do this in XNA? I'm sure I could figure out how to apply the answer to my particular application, but if it helps, my game involves a lot of ripples and I'd like to specifically distort the areas around and just behind the expanding sprite-based ripples.


share|improve this question
Look into HLSL, distortion effects are not complicated to do using a simple pixel shader. The Bloom sample on the XNA site is a good place to start. Also, Aquaria is open source ;) – zfedoran May 20 '11 at 0:31
I just noticed that you are targeting the Windows Phone 7, in that case forget my HLSL suggestion (XNA does not give you access to programmable shaders on the phones). Instead, here is the ripple effect code from Aquaria (Line 615):… – zfedoran May 20 '11 at 0:42

Render your scene to a render target.

Render your render target to the screen on a procedurally-generated full-screen mesh with animated vertices or texture coordinates.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.