Search Unity

Ceto (Scrawks Ocean)

Discussion in 'Assets and Asset Store' started by scrawk, May 4, 2015.

  1. alexzzzz

    alexzzzz

    Joined:
    Nov 20, 2010
    Posts:
    1,447
    R9 290X, 1920x1080, i5-2500K @4GHz

    ~30 fps - fantastic
    ~35 fps - fastest
     
  2. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,502
    AMD HD7970 with latest demos:

    DX9 version works.
    DX11 version has same problem as documented in screenshots earlier, no surprise.
    DX11 extreme has same problems, looks like an additional issue on top of the problem with AMD and the non-extreme DX11 version.

    Some videos might indicate the nature and the detail of the problems better, I will see what I can do after I have taken a break to eat. edit - no I'm far too tired right now, will sort something tomorrow.
     
    Last edited: Aug 25, 2015
  3. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Thanks. Dont worry to much about the video. It probably wont help much. Heading to the store now to see if the ATI260 cards are still for sale.
     
  4. spraycanmansam

    spraycanmansam

    Joined:
    Nov 22, 2012
    Posts:
    254
    Looking good :)
    Extreme averages around 23 fps at 1080p on an 970M.
     
    scrawk likes this.
  5. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Couldnt find a ATI 260 but got a 360 and can replicate the issue so hopefully will have this fixed this week.

    Ocean45.jpg
     
  6. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    AMD card bug should now be fixed. Turned out to be a simple fix. Just changed some textures from half to float. Also fixed the bug causing a hole in the mesh. Just a NAN in the shader.

    It looks like the AMD card (and maybe others) dont have the precision to handle a fourier size 512 used for the extreme build. Im not to worried about this as those setting are unlikely to be used by many people. I have changed the extreme build to a fourier size of 256 however just to prevent people consonantly reporting the issue.

    If you have had these issues please try again and hopefully its fixed for everyone.
     
    hopeful, Rycons, elbows and 3 others like this.
  7. John-G

    John-G

    Joined:
    Mar 21, 2013
    Posts:
    1,122
    @scrawk Small observation with the boat trails in large waves. When the rear of the boat rises out of the water (addFoamTrail) it abruptly stops generating foam trails until rear of boat goes back into water.
    Would it be possible to have a small fade out of the texture after the script detects that its no longer underwater.
    It would create a much nicer look to the transition of the foam trails from on/off/on states in rough seas.
    And if possible to have it user definable as to amount of seconds to fade out, so different objects could have independent fade times that the foam trail dissolves at on object no longer in contact with surface. :)
     
    Karearea likes this.
  8. Luckymouse

    Luckymouse

    Joined:
    Jan 31, 2010
    Posts:
    484
    Interesting, I remember when I fixed the ATI issue while i was working on my fog image effect, that because I put the "camera depth check" on Start function, it was working completely fine on nVidia, but not ATI card. After I put the "camera depth check" on update (OnRenderImage()). It fixed the ATI card issue.
     
    SAOTA likes this.
  9. DenisLemos

    DenisLemos

    Joined:
    May 1, 2015
    Posts:
    787
    Windowns 7 | i7-4790 CPU @ 3.60GHz | RAM 8 GB | Nvidia GTX 760

    1920x1080 | Fantastic

    Dx9 60 fps
    Dx11 60 fps

    Dx11 Extreme 35 ~ 40 fps
     
  10. InfiniteDice

    InfiniteDice

    Joined:
    Jun 30, 2015
    Posts:
    44
    Works with my card now! A few questions.

    1) the smoothed out area around the buildings, how is that area defined? a) is that for making protected areas like inlets or bays? b) can that area have a proportionate setting, where it could be scaled % to reflect the settings from the main part of water.

    2) can we have different grids, where each grid might overlap but be given a draw priority? - maybe a feature idea for later...

    3) can the leeward side of a static object..... say a large rock outcropping, nullify the the wave deformation from the dominant wind direction? - just an idea for making areas of the water naturally sheltered by geography...

    4) are there any ideas for the inverse water plane. I assume this will need to mimic the above plane, or have something fancy like if the active camera goes below the water level then invert and apply different effects... not sure - don't want to rain on the parade jic you do have a plan.

    5) lastly above below transition effect... I know that a few other water packages come with some form of solution for this, again might not be something you'll have right out of the gate - but just wondering if it's in the feature set of the finished product.

    Thanks! lookin good at this point.
     
  11. ZJP

    ZJP

    Joined:
    Jan 22, 2010
    Posts:
    2,649
    Yes.
    AMD FX8350, Radeon HD7850 DX11 and DX9. No troubles here.
    DX9 60Fps (Fastest or Fantastic) @1920x1080. :cool:
    DX11 30Fps Fantastic, 60Fps Fastest.
     
  12. elias_t

    elias_t

    Joined:
    Sep 17, 2010
    Posts:
    1,367
    Yes I can confirm that the amd card issue is fixed here also.

    Well done!
     
  13. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Thanks :)

    1 - The smoothed out area is done using the wave overlay system. You can define the area, position and rotation and then the waves are masked out using a texture you provide. Its just a script and you just drag on your mask texture.This means the mask can be any shape. Yes this is designed for inlets, bays, shorelines etc. There will be scripts later that can calculate the shore mask for you.

    2- By grids do you mean the overlays? If so yes they can overlap. There is no setting for draw order but they are designed in a way were the draw order does not effect the end result so it not something you would need to worry about. If that ends up being a problem its something that can be added easily.

    3 - You could do this but you would have to manually put the overlay on the leeward side of the rock. You can then use the overlay to mask the wave height and normal strength by some value. You could even add new waves going a different direction here.

    4 - Yes there is a mesh that gets render for the under side of the ocean. Its currently disabled as the under water effects are not complete.

    5 - There is a system already in place that means the area above and below the water will always be rendered correctly no matter what the camera position. This mean there is no need for a transition effect but you could still have one if you wish. I posted a little about this a long time ago on page 1 or 2. Again this feature is currently disabled until the underwater effect is done.
     
  14. elias_t

    elias_t

    Joined:
    Sep 17, 2010
    Posts:
    1,367
    Konst likes this.
  15. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Thanks! They could be useful.

    @John G. : Im sure I can add that to the foam trails. They will get a bit of a overhaul in a future update. Still need to add the boat wakes
     
    Konst and John-G like this.
  16. John-G

    John-G

    Joined:
    Mar 21, 2013
    Posts:
    1,122
    @scrawk I created these textures to swap out your foam for testing, but they are appearing very blue in use compared to the ones you have supplied.
    Are you using an additive blend in the overlay, not sure where the blue is deriving from? png files have no colour information within them.
    Would it be taken the colour information from the Normals?

    Likewise if these are use-able for you in the system, Please do as my thanks.

    Tile-able Foam Bubbles




    Tile-able Sea Foam




    Bubbles Spot
     
  17. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804

    Thanks!

    They are appearing more blue because the shader fades them with the ocean. Only the red channel is sampled as the foam strength and this is also the value used to blend. Just make them lighter in color to fade them less. Maybe this need some work in future versions.

    Ive also removed the foam normal from the latest version on the wave spectrum script and replaced it with two foam textures that are then averaged. I found the normals was not really adding much and with two textures it is easier to reduce the tiling.

    Make sure you have a texture on both other wise the empty one will be black and when average you will end up with a darker color.
     
    John-G likes this.
  18. John-G

    John-G

    Joined:
    Mar 21, 2013
    Posts:
    1,122
    Thanks will try that out. Would it be better to blend using alpha channel, don't have much knowledge of shaders with regards to blending channels.
     
  19. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Probably should be the alpha channel. Im use to working with render textures where its common to use the red channel for single channeled textures. Will look into changing it in next update.
     
    John-G likes this.
  20. CaptainMurphy

    CaptainMurphy

    Joined:
    Jul 15, 2014
    Posts:
    746
    Anyone else trying to network Ceto yet? I am using Forge and have just started building my first networked scene and seem to be getting an error at random. Can't nail down what it triggering it yet. The scene just loads Ceto, it doesn't actually try to network it, so it shouldn't be anything networking related that is causing this. When this occurs it seems that Ceto just freezes at that point. Not other errors are thrown in the log or debug as far as I can tell.

    Debug log from build:
    VS2013 Debug entry while in IDE:
    It isn't picky on which one it happens on either. Though it generally only happens on one at a time. I am wondering if it might have anything to do with running two of them side by side on the same machine and possibly a thread issue?
     
  21. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    That's a issue with the multi threading that generates the waves. Ive never had that come up before and Im not sure why it happens when your trying to network. I know the section of code its coming from. I will have a close look at it this week.
     
  22. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Can you go into the Ceto/Script/Spectrum/Buffers/WaveSpectrumCPU.cs file and change the DISABLE_INIT_MULTITHREADING at the top to true and see if it still happens.
     
  23. sadicus

    sadicus

    Joined:
    Jan 28, 2012
    Posts:
    272
    Ceto DX11 EXTREME (same results) Looks superior!
    • intel Graphics HD 4000 = 3 fps
    • nvidia GeForce GTX 680M = 19 fps
    How did you get the waves around the buildings to 'not wave'?
    A:
     
    Last edited: Aug 28, 2015
  24. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,502
    See the first point in this post from yesterday:

    #463
     
  25. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    There's a fair amount of garbage pumped out each frame, but this is beta so I guess it will clear up in the final version (unless I'm doing something wrong)

    Also, truesky injects itself before transparent and after opaque correctly (5.2 feature) so I was thinking isn't this what ceto wants to do? I also cannot get them to play nice along the horizon - any thoughts anyone?
     
  26. CaptainMurphy

    CaptainMurphy

    Joined:
    Jul 15, 2014
    Posts:
    746
    I don't know that networking is technically the culprit, moreso that when I have 4-5 clients running locally it is having issues. My real concern is it happening on a dedicated server that has 20-30 scenes running with ocean in them and causing the oceans to stop on those scenes.
     
  27. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    I don't know if this is possible but wouldn't it be better for each client to simulate ocean themselves but get authoritative buoyancy from a single server instance?

    30*threaded seems like something would break.
     
  28. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    @hippocoder: Garbage as in memory allocations? GC?

    If truesky renders after opaque and writes to depth buffer yes thats what I want. Its not a big issue though.

    Not sure about the horizon issue with true sky. I know there was a issue with true sky and latest version should fix it. @John G. might know. Also just to let everyone know there is currently a bug were moving the ocean level from 0 causes issues with the reflections. The reflections still try and render at 0.


    @hippocoder: Have you tried the disable init multitreading mentioned about. I think that may solve it. May add 1-2ms to frame time though.
     
  29. CaptainMurphy

    CaptainMurphy

    Joined:
    Jul 15, 2014
    Posts:
    746
    The way we are doing it is the server sends the base ocean info then sends the frame at intervals to make sure they are in sync visually. Our buoyancy, wind reaction, and other physics are all done server side and the client just gets the position/rotation from server side with some client side prediction. Our issue has only lately come up with the ocean freezing due to some threading.

    @scrawk can that threading constant be done with a variable or property from somewhere else? I could see it being beneficial for clients but being an option to disable it for servers or multi rendering on a single machine. I have been testing this morning with 6 clients connected to a server and so far no issues with that flag changed. I'll test some more today and see if it can be reproduced still.

    I do have a questions, before the spectrum could be modified on the instance for choppyness, age, etc and now it is telling me those variables are no longer editable for some reason. The code shows the variable is still there, and still public but is unreachable from the ceto.ocean.instance.spectrum space. Not sure if I missed something in a previous update that changed how those worked or not, so it could just be me not keeping up here.
     
  30. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    Yep that's right, in various places:

    2015-08-28_14h50_30.png
    and
    2015-08-28_14h51_17.png

    I imagine this would impact servers quite badly if running several instances as they will be collecting garbage often and this causes a pause depending - which for networking might be a bit of a disaster overall.
     
  31. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Thats great changing that flags seems to help. Im pretty sure that is the cause and will look into it. The flag cant be changed from else where. Never thought it would be needed. I can add a check box in the editor if needed.

    Sorry, yes the spectrum has been changed a bit. All the components attach to the ocean via a abstract base class now. I want to provide support for adding custom components to change the behavior of the default components if needed.

    You just need to get the component like this now

    Code (CSharp):
    1.  
    2. WaveSpectrum spectum = Ocean.Instance.GetComponent<WaveSpectrum>();
    3.  
    4. spectum.windSpeed = 10.0f;
    5.  
    6. //or like this
    7.  
    8. WaveSpectrum spectum = Ocean.Instance.Spectrum as WaveSpectrum;
    9.  
    10. spectum.windSpeed = 10.0f;
    11.  
    12.  

    @hippocoder: Ok, thanks. Will look into it. I dont think that will be to hard to fix.
     
  32. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    So I know I said open beta will start soon but looks like there are still to many issues with the current beta and I am extremely busy with work at the moment.

    This means the open beta is on hold for at lest two weeks until the issues are sorted out.

    Sorry if you've waiting for it but I need some more time.
     
    bartm4n and veddycent like this.
  33. DizzyTornado

    DizzyTornado

    Joined:
    Nov 17, 2013
    Posts:
    134
    Just wondering if we can use the beta version of the asset for ftp or paid games? Sorry, I'm not sure because I haven't checked this thread in about a month, so I'm not really up-to-date on this.
     
  34. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Yes you can use the beta for free or paid games.
     
  35. CaptainMurphy

    CaptainMurphy

    Joined:
    Jul 15, 2014
    Posts:
    746
    Almost drove myself nuts this weekend trying to get networking going but finally succeeded. Gotta say that the easiest part was getting Ceto synced up! Left is the server/client and right is a client.

     
  36. DizzyTornado

    DizzyTornado

    Joined:
    Nov 17, 2013
    Posts:
    134
    This might sound oddly specific, but can you add a feature like a checkbox or something at the bottom of the Ocean gameobject's settings that says something along the lines of "mountainous waves" and creates waves something like this scene in Interstellar:
     
  37. DizzyTornado

    DizzyTornado

    Joined:
    Nov 17, 2013
    Posts:
    134
    Btw, have you chosen the Beta testers yet?
     
  38. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    In the demo scenes if you turn the wind sped and grid scale to max this is the largest possible waves size. The waves end up being +/- 50m. The large waves cause all sorts of problems with the projected grid however so this is the max.

    For the open beta anyone can be part of it. Depending on how much I get done in the next two weeks it's possible I may go straight to the asset store.
     
  39. Rycons

    Rycons

    Joined:
    Nov 23, 2013
    Posts:
    31
    Good to hear scrawks, Looking forward to it!
     
  40. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    I would definitely buy ASAP. I prefer asset store because it's all in one place :)
     
    DizzyTornado and spraycanmansam like this.
  41. verenion

    verenion

    Joined:
    Mar 25, 2013
    Posts:
    10
    I've been following this project from the beginning after writing my own ocean shader - forked from the water4 assets. I'm working on a game with working buoyancy, but it would be amazing to get it working with ceto. Looks gorgeous. Keep up the good work! I'd be happy to do some beta testing too.

    I ran the demo scene on a gtx970, worked very well. 60fps.
     
  42. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    Are there any indications regarding an underwater shader?
     
  43. InfiniteDice

    InfiniteDice

    Joined:
    Jun 30, 2015
    Posts:
    44
    He said there is one. Though it's not in the demos yet...
     
  44. CaptainMurphy

    CaptainMurphy

    Joined:
    Jul 15, 2014
    Posts:
    746
    I, honestly, think it can skip the open beta stage at this point if the last couple of weeks are spent doing code cleanup and documentation. It is already usable as is in every build I have done.
     
  45. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    Going to be working on that today.
     
    John-G likes this.
  46. DizzyTornado

    DizzyTornado

    Joined:
    Nov 17, 2013
    Posts:
    134
    Okay, BTW just wondering if you could make a simplified version of the script that is just a shader, that I can apply to a flat plane. I was thinking of using a scrolling height map to make waves similar to those found in Interstellar.
     
  47. scrawk

    scrawk

    Joined:
    Nov 22, 2012
    Posts:
    804
    So basic under water without any fancy effects will look something like this...

    Ocean47.jpg

    Ocean46.jpg
     
    sashahush, elias_t, hopeful and 10 others like this.
  48. John-G

    John-G

    Joined:
    Mar 21, 2013
    Posts:
    1,122
    I like it :)
     
  49. longroadhwy

    longroadhwy

    Joined:
    May 4, 2014
    Posts:
    1,551
  50. Iguanapl

    Iguanapl

    Joined:
    Mar 11, 2014
    Posts:
    23
    LOL... You should sell this underwater effect as a separate asset :D