I just watched a video of the iphone beer app and it's more simple than I thought it would be. It's basically a big quad or a warpy grid with the beer and head or maybe 2 quads, one being for the liquid and one for the head (so the head can get tall). Looks like they maybe do some texture animation to get the fizzing or head bubbling. After that it looks like a bunch of quads/point sprites on the screen after the beer is down to make it look sudsy.
Combine that with the accelerometer hooked to a field to control rotation and you've got yourself iBeer. There are other ways to do more dynamic effects, though: First of all, you will probably want to familiarize yourself with 2D fluid dynamics (from the side) so you can get that splashiness. I've done 3D fluid dynamics and I think the same algorithm could be modified to work just from the side. If the liquid were always on one edge, that would completely work. To make the liquid pour from edge to edge is a difficult problem but maybe if it's addressed as a separate feature (like the app goes into a pouring state) you could use the 2d fluid + a pouring trick and just change the edge it sits on after it's out of the pouring state. Another option would be to maybe even use a 2D physics engine for that and hack a chain to be a water surface, letting it flop around on the screen. To get the texture right, I'd make a frothy edge texture and a main regular soda texture. Fizzing and blobs of liquid splashing are achievable with particle effects. Bubbles are easy, they are just little white stroke circles. The water blobs could be one of several different shaped textures. Getting it tuned right will be hard and making it look like real soda is even harder using that approach. It may always look synthesized unless you nail the textures and movements. I don't know if this would work because these are just things I'd think about doing to get started. You'll know more once you dig into it. On Apr 27, 4:45 am, APK <[email protected]> wrote: > Hi, > I am new to Open GL ES. i am trying to write a program, which > displays a Glass on the screen, and the coke will be filled slowly. > when anybody touches the screen, ice cubes will be falling from top > into the glass. > > Can anybody please share your views on this. > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group > athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

