00:00
00:00
Newgrounds Background Image Theme

Unknownfornow just joined the crew!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

(NOT RUFFLE COMPATIBLE) Away3D 4.1.6 Flash Player 11 | Advanced Shallow Water Demo

Share Collapse

Author Comments

Abstract:

Away3D was another open-source 3D framework forked from Papervision3D developed and used for Flash in 2007 until it was discontinued in 2014. The history surrounding this framework is absolutely impressive. They have their own model format, their own builder software, and Adobe incorporated the framework into the Adobe Gaming SDK in 2013.

Unlike Papervision3D, Away3D 4.x fully supports 3D rending via Stage3D. Meaning most of the 3D graphics on screen is rendered using the GPU. This frees up a lot of CPU compared to Away3D 3.x and especially 2.x and Papervision3D.


This example demos the Shallow Water Equation (SWE). A method of creating ripples across flat water given splash points or other water disturbances. The example then takes this equations and rasterizes the points onto the screen creating a 3d water example for still water.


11.29.2023

For whatever reason there are some opt codes that Ruffle isn't either recognizing or misinterpreting, leaving the screen blank and not rendering anything. I'm going to have to go though each step in all of the classes and trace all the objects to see what could possibly be undefined. It could be another event issue, though I hope its not.


Controls:

  • Click and drag to move the world to see objects.
  • Use the SimpleGUI to change the scene settings such as water thickness, enable rain, draw images in the water, etc.


Bugs:

  1. 11/29/2023 FATAL It entire scene doesn't render at all in Ruffle.
  2. Away3D Statistics seem to now show the graph properly, as well as show `Dummy` for the GPU driver. May come in use to detecting Ruffle or Flash.
  3. Away3D Statistics also seem to not display the ram usage


Performance:

Platform: Intel(R) Core(TM) i7-10875H CPU 2.30 GHz (Intel64 Family 6 Model 165 Stepping 2) with NVIDIA GeForce RTX 2080 Super with Max-Q Design

NOTE: These results are after one generation of the tree with default settings.


Newgrounds Player:

  • 44.8 ~ 49.6 CPU%
  • 0 GPU% (Note: the Newgrounds Player does not use any GPU, instead opting all 3d graphics to be drawn via software rasterization hence the high CPU percent.)
  • 67.9 MB Ram Usage
  • FPS: 14~ 20

Flash 11.8 r800 (32-bit):

  • 47.9 ~ 50.2 CPU%
  • 5.3 ~ 6.2 GPU% (GPU-1)
  • 322.6 MB Ram Usage
  • FPS: 50 (frame locked despite the set frameRate being 300)

Flash 32:

  • 46.2 ~ 48.0 CPU%
  • 4.8 ~ 5.2 GPU% (GPU-1)
  • 47.9 MB Ram Usage
  • FPS: 50 (frame locked despite the set frameRate being 300)

Ruffle (Windows Port) BROKEN:

  • 0.9 ~ 2.1 CPU%
  • 1.9 ~ 3.9 GPU% (GPU 1)
  • 161.4 MB Ram Usage
  • FPS: 45 (frame locked despite the set frameRate being 300)

Ruffle (Web port) BROKEN:

  • 3.7 ~ 4.1 CPU%
  • 10.7 ~ 11.2 GPU% (GPU-0, Based off of the graphics card of the browser)
  • 565.3 MB Ram Usage (Loaded with the Newgrounds Portal, this is not accurate for Ruffle but IRL Webpages)
  • FPS: 45 (frame locked despite the set frameRate being 300)


Note:

If you want to run the example and see for yourself what it does, download the Binaries (.swf release) and run the application with any standalone Flash Player or the Newgrounds Player.


Todo:

  • Double check compatibility with Away3D 3.x and 2.x, it seems as if 4.x works better on Ruffle due to the dependence on Stage3D instead of AS3.
  • Go though and trace(Object) to figure out where the scene failed.


Credits:

  1. Away3D - Website
  2. Away3D Example Files - Found Here (Internet Archive via Wayback)


Source Code: http://www.mediafire.com/file/wc15vah7qnf6ild/Advanced_ShallowWaterDemo.zip

Binaries (.swf release): https://www.mediafire.com/file/jr3ami8rqt7v229/Advanced_ShallowWaterDemo.swf/file

Log in / sign up to vote & review!

Credits & Info

Views
294
Votes
71
Score
2.98 / 5.00

Uploaded
Nov 29, 2023
9:09 PM EST
Genre
Spam
Misc. Kit
  • Flash Builder 4.7