[App] Liquid Physics Live Wallpaper

Search This thread

jgittins

Senior Member
Nov 1, 2010
127
36
Carlisle
I made a quick port of Grant Kot's liquid simulator java applet and turned it into a live wallpaper.

It uses a ton of cpu so it will probably drain the battery pretty fast but it's fun to play with.

http://grantkot.com/MPM/Liquid.html

zip file contains the eclipse project with all the source code if anyone wants to do something with it

edit: - ignore the apk in this post and download quinbd's version a few posts down, it's much better
 

Attachments

  • LiquidLiveWallpaper.apk
    10.7 KB · Views: 7,345
  • LiquidWallpaper.zip
    43.6 KB · Views: 1,930
Last edited:

ZekeWolf

Senior Member
Dec 3, 2008
405
9
Nice! Would be nice if it reacted to phone movement.

Sent from my HTC HD2 using XDA App
 

quinbd

Member
Jul 3, 2010
12
17
West Lafayette, IN
Update

Hey, I took the liberty of adding some features

Updates: 1.0
  • Fit to screen size
  • Gravity follows phone
  • Changed particle color :p
Update: 1.1
  • Added options for number of particles and color
Update: 1.2
  • Added a lot more options
  • New "Blur" effect
  • Gravity Sensitivity - (including zero gravity)
  • Horizontal and vertical gravity inverts - (needed for some phones)
  • Animation delay setting
Update: 1.3
  • UI Improvements
  • FPS Counter
  • True support for horizontal and vertical screen views
  • Particle Size Setting (Anything but 0 leads to very poor results)
Update: 1.5
  • Put on Market for easy updating and sharing
  • UI / Simulate Tweaks

Features in the works:
  • Use OpenGL to render
  • Use native code to calculate the physics
  • More Fun Stuff :)

If you have any comments, bugs, or suggestions, please post them here!


*** Download ***
As this app is now on the Android Market, you can either find it by following the link or using the QR code.

WQ2NS.png


http://www.quinndamerell.com/LiquidPhysics/

https://market.android.com/details?id=com.quinndamerell.liquidphysics

All credit goes to the original poster and the creator of the water algorithm!

Enjoy :D
 
Last edited:

jgittins

Senior Member
Nov 1, 2010
127
36
Carlisle
Hey, I took the liberty of adding some features

Updates:
  • Fit to screen size
  • Gravity follows phone
  • Changed particle color :p

Here is the apk for now, I will repost the source later.

All credit goes to the original poster!

Enjoy :D

Thanks! I like your version better. I wish there was more particles but my phone just isn't fast enough.
 

/rant/

Senior Member
Aug 1, 2010
164
5
Well, I hate Java and I love C/C++, so I might end up porting this to use JNI. This would probably be one of those areas where using C++ for particle movement could really make a big difference. Thank you.
 

dan56965

Member
Jul 16, 2010
15
1
Very cool.

I noticed you said it's "as fast as I could get it", but you're using postDelayed with 50ms intervals, which limits the refresh rate to 20Hz.
I changed that to 17ms, and added a simple fps display to test - it seems to max out around 30fps on my phone.
 

Attachments

  • LiquidWallpaper.zip
    45.3 KB · Views: 911
  • Like
Reactions: gilaxone

ogdobber

Inactive Recognized Developer
Nov 4, 2008
3,256
1,827
I made a quick port of Grant Kot's liquid simulator java applet and turned it into a live wallpaper.

It uses a ton of cpu so it will probably drain the battery pretty fast but it's fun to play with.

http://grantkot.com/MPM/Liquid.html

zip file contains the eclipse project with all the source code if anyone wants to do something with it

Hey, I took the liberty of adding some features

Updates:
  • Fit to screen size
  • Gravity follows phone
  • Changed particle color :p

Here is the apk for now, I will repost the source later.

All credit goes to the original poster!

Enjoy :D


awesome work guys. love both versions:D
 

jgittins

Senior Member
Nov 1, 2010
127
36
Carlisle
Very cool.

I noticed you said it's "as fast as I could get it", but you're using postDelayed with 50ms intervals, which limits the refresh rate to 20Hz.
I changed that to 17ms, and added a simple fps display to test - it seems to max out around 30fps on my phone.

Yeah I found 20hz seemed to be the best compromise between animation speed and not using so much cpu time that the phone slows down to a crawl. Different phones might be able to run it faster though.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 18
    I made a quick port of Grant Kot's liquid simulator java applet and turned it into a live wallpaper.

    It uses a ton of cpu so it will probably drain the battery pretty fast but it's fun to play with.

    http://grantkot.com/MPM/Liquid.html

    zip file contains the eclipse project with all the source code if anyone wants to do something with it

    edit: - ignore the apk in this post and download quinbd's version a few posts down, it's much better
    13
    Update

    Hey, I took the liberty of adding some features

    Updates: 1.0
    • Fit to screen size
    • Gravity follows phone
    • Changed particle color :p
    Update: 1.1
    • Added options for number of particles and color
    Update: 1.2
    • Added a lot more options
    • New "Blur" effect
    • Gravity Sensitivity - (including zero gravity)
    • Horizontal and vertical gravity inverts - (needed for some phones)
    • Animation delay setting
    Update: 1.3
    • UI Improvements
    • FPS Counter
    • True support for horizontal and vertical screen views
    • Particle Size Setting (Anything but 0 leads to very poor results)
    Update: 1.5
    • Put on Market for easy updating and sharing
    • UI / Simulate Tweaks

    Features in the works:
    • Use OpenGL to render
    • Use native code to calculate the physics
    • More Fun Stuff :)

    If you have any comments, bugs, or suggestions, please post them here!


    *** Download ***
    As this app is now on the Android Market, you can either find it by following the link or using the QR code.

    WQ2NS.png


    http://www.quinndamerell.com/LiquidPhysics/

    https://market.android.com/details?id=com.quinndamerell.liquidphysics

    All credit goes to the original poster and the creator of the water algorithm!

    Enjoy :D
    1
    Nice! Would be nice if it reacted to phone movement.

    Sent from my HTC HD2 using XDA App

    I'm not really going to do anything further with this app so I've attached the source code to the first post if you want to do it :p
    1
    Very cool.

    I noticed you said it's "as fast as I could get it", but you're using postDelayed with 50ms intervals, which limits the refresh rate to 20Hz.
    I changed that to 17ms, and added a simple fps display to test - it seems to max out around 30fps on my phone.
    1
    Nice app guys. Thanks.