Minarkhaios Posted June 2, 2015 Share Posted June 2, 2015 (edited) Fair enough, I understand now why this is not so simple. Thanks to the three of you for your answers.Just a random though about the up and down for the sea. Is it possible to create an invisible object that will collide with the current ship ? Something small enough used only to push up a bit the current vessel ? And link it's coordinate with the higher wave below ? (Or the coordinate of what we see as a wave and is just an equation's representation without physical existence)I think I will start to investigate on my own and try some stuff with unity (long road but, well, at least I won't bother anyone with stupid question like this one )Edit : It seems that I'm again totally off subject : This seems to be a cleaner solution, just moving the object Edited June 2, 2015 by Minarkhaios Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 2, 2015 Author Share Posted June 2, 2015 (edited) Fair enough, I understand now why this is not so simple. Thanks to the three of you for your answers.Just a random though about the up and down for the sea. Is it possible to create an invisible object that will collide with the current ship ? Something small enough used only to push up a bit the current vessel ? And link it's coordinate with the higher wave below ? (Or the coordinate of what we see as a wave and is just an equation's representation without physical existence)I think I will start to investigate on my own and try some stuff with unity (long road but, well, at least I won't bother anyone with stupid question like this one )Edit : It seems that I'm again totally off subject : This seems to be a cleaner solution, just moving the objectKeep in mind that that object is contained entirely in the shader, to do something similar in KSP you'd have to either get the wave height and position information out of the shader (I think this isn't feasible or really tricky, maybe rbray could shine some light on this), or do all of the wave calculations outside of the shader so you have all the required data in your program to move the object up or down.This could be feasible with the proland water shaders, I haven't looked much into it but the guy who ported proland to unity did something similar in one of his projects but it was dx11-only.You can read about it here if you want http://scrawkblog.com/2013/06/04/ocean-with-brdf-lighting-in-unity/ scroll to the end for the waves thing. Edited June 2, 2015 by blackrack Quote Link to comment Share on other sites More sharing options...
rbray89 Posted June 2, 2015 Share Posted June 2, 2015 Keep in mind that that object is contained entirely in the shader, to do something similar in KSP you'd have to either get the wave height and position information out of the shader (I think this isn't feasible or really tricky, maybe rbray could shine some light on this), or do all of the wave calculations outside of the shader so you have all the required data in your program to move the object up or down.This could be feasible with the proland water shaders, I haven't looked much into it but the guy who ported proland to unity did something similar in one of his projects but it was dx11-only.You could use compute shaders (or do something to a render/texture, and read from that). Those are the only real way to get stuff out of a shader. Might be easier to use the same computational method used in the shader for a single point (ship origin) to do the moving. Hehe, you might even be able to replace the shaders for the craft pards with one that relocates the vertices when within 'X' distance of the ocean Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 2, 2015 Author Share Posted June 2, 2015 Hehe, you might even be able to replace the shaders for the craft pards with one that relocates the vertices when within 'X' distance of the ocean .This sounds really clever, but could this really work? Quote Link to comment Share on other sites More sharing options...
rbray89 Posted June 2, 2015 Share Posted June 2, 2015 This sounds really clever, but could this really work?I see why not... You would want to pass in a vector to the shader every cycle, though all parts would get the same movement, regardless if attached to the same craft or not, so debris might look odd. You'd also want to do this to Kerbal shaders. Note that I mean to fully replace the shader, not use replacement shaders It would just be REALLY annoying to do this, as the shaders are all closed-source. Quote Link to comment Share on other sites More sharing options...
HafCoJoe Posted June 3, 2015 Share Posted June 3, 2015 Hehe, you might even be able to replace the shaders for the craft pards with one that relocates the vertices when within 'X' distance of the ocean Would that alleviate extra lag too? I'm concerned about my FPS when looking at those waves. I'd install regardless of an impact haha. Too beautiful...EDIT: Say you wouldn't have a need for a 'tester' would you Blackrack? Quote Link to comment Share on other sites More sharing options...
Minarkhaios Posted June 3, 2015 Share Posted June 3, 2015 I see why not... You would want to pass in a vector to the shader every cycle, though all parts would get the same movement, regardless if attached to the same craft or not, so debris might look odd. You'd also want to do this to Kerbal shaders. Note that I mean to fully replace the shader, not use replacement shaders It would just be REALLY annoying to do this, as the shaders are all closed-source.Wouldn't it be easier to apply a small force to each part based on the same data ? something similar to the lifting bodies found in ferram mod ? (Or am I again understanding something wrong ?) Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 3, 2015 Author Share Posted June 3, 2015 (edited) Would that alleviate extra lag too? I'm concerned about my FPS when looking at those waves. I'd install regardless of an impact haha. Too beautiful...EDIT: Say you wouldn't have a need for a 'tester' would you Blackrack?What kind of GPU do you have? From my testing I'd say as long as you have a gtx 460 or better you shouldn't be getting any slowdowns from the water. Also, keep in mind the water is still broken in a really bad way and I'll just post it for everyone to test as soon as it works better. I've also started working on full EVE compatibility yesterday. Edited June 3, 2015 by blackrack Quote Link to comment Share on other sites More sharing options...
bgeery Posted June 3, 2015 Share Posted June 3, 2015 Update: 20-05-2015 - v0.0151 Pink objects quickfix (Please stop reporting this bug)Could you please clarify the above statement in post #1? Does this mean this update fixes the bug, so stop reporting issues with older versions? Or, this fixes what you can right now and they have to live with the pink objects, if they still have them with this version? Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 3, 2015 Author Share Posted June 3, 2015 Could you please clarify the above statement in post #1? Does this mean this update fixes the bug, so stop reporting issues with older versions? Or, this fixes what you can right now and they have to live with the pink objects, if they still have them with this version?This update fixes the bug, except for the pink box in the loading screen but that doesn't hurt the game. Quote Link to comment Share on other sites More sharing options...
bgeery Posted June 3, 2015 Share Posted June 3, 2015 This update fixes the bug, except for the pink box in the loading screen but that doesn't hurt the game.Huh, 'cause I still have 'em. I'm special like that. OpenGL, GTX970 Quote Link to comment Share on other sites More sharing options...
BudgetHedgehog Posted June 3, 2015 Share Posted June 3, 2015 I've had that appear when I revert to launch only. OpenGL too. Quote Link to comment Share on other sites More sharing options...
bgeery Posted June 3, 2015 Share Posted June 3, 2015 (edited) I've had that appear when I revert to launch only. OpenGL too.Yup, that's how I produced them for the screenshot. Didn't notice if that's the only way, but you are probably correct, as I'm always doing simulated launches and revert. Edited June 3, 2015 by bgeery Quote Link to comment Share on other sites More sharing options...
sarbian Posted June 3, 2015 Share Posted June 3, 2015 You could use compute shaders (or do something to a render/texture, and read from that).With Unity 5.1 moving to unify the use of compute shader for DX11 and OpenGL that could be a solution at long term. Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 3, 2015 Author Share Posted June 3, 2015 Huh, 'cause I still have 'em. I'm special like that. OpenGL, GTX970http://i.imgur.com/xLfQgn0.jpgYeah sorry, It removes the pink textures on gameobjects but some people do report a messed-up UI on OpenGL. What you could try is download the 0.014 version (go to the kerbalstuff link in the OP, click changelog and download 0.014) and copy the replacement shaders folder from 0.014 and drop it in your current version. Quote Link to comment Share on other sites More sharing options...
rbray89 Posted June 3, 2015 Share Posted June 3, 2015 With Unity 5.1 moving to unify the use of compute shader for DX11 and OpenGL that could be a solution at long term.I was actually thinking about that. It would be neat to see. Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 3, 2015 Author Share Posted June 3, 2015 Just wanted to post these Quote Link to comment Share on other sites More sharing options...
Grach Posted June 3, 2015 Share Posted June 3, 2015 Just wanted to post thesehttp://i.imgur.com/vibvIo3.jpghttp://i.imgur.com/WUfZcVi.jpgAbsolutely stunning Quote Link to comment Share on other sites More sharing options...
Proot Posted June 3, 2015 Share Posted June 3, 2015 Just wanted to post thesehttp://i.imgur.com/vibvIo3.jpghttp://i.imgur.com/WUfZcVi.jpg That reflection works at high distances/map view? It's configurable?The effect is close to perfection, but IMHO the reflection should be a bit wider.One detail, Blackrack: would be possible to add a bit of blur at the horizon line to avoid that tiny line that cuts terrain and sky? Would be the perfect touch.And one more thing... what you want before?:to add the water shader or the multiplanet support? Would be perfect have an intermediate version, to experiment a bit more with the atmos before add oceans to the equation. I've created my first set of atmos in a friend's computer, but I still have some round patch artifacts at certain points (much, much less than before, anyway). But once you modify the altitude/density of the stock atmo, seems a bit hard to get a completely smooth result. Is there any tip/trick to get the perfect smooth? Quote Link to comment Share on other sites More sharing options...
V8jester Posted June 3, 2015 Share Posted June 3, 2015 Just wanted to post thesehttp://i.imgur.com/vibvIo3.jpghttp://i.imgur.com/WUfZcVi.jpgDon't bother applauding just throw money at this man! Blackrack every time I come back to your thread I'm amazed. What SEUS did for Minecraft you are doing for KSP. I can't wait to see the next release. Quote Link to comment Share on other sites More sharing options...
blackrack Posted June 3, 2015 Author Share Posted June 3, 2015 (edited) That reflection works at high distances/map view? It's configurable?The effect is close to perfection, but IMHO the reflection should be a bit wider.One detail, Blackrack: would be possible to add a bit of blur at the horizon line to avoid that tiny line that cuts terrain and sky? Would be the perfect touch.And one more thing... what you want before?:to add the water shader or the multiplanet support? Would be perfect have an intermediate version, to experiment a bit more with the atmos before add oceans to the equation. I've created my first set of atmos in a friend's computer, but I still have some round patch artifacts at certain points (much, much less than before, anyway). But once you modify the altitude/density of the stock atmo, seems a bit hard to get a completely smooth result. Is there any tip/trick to get the perfect smooth?Once you get past a certain distance the effect is just this water color and reflection http://i.imgur.com/U7oD7Uh.jpg, no more waves are generated, this could be easily made to work at a high distance or in scaled space, in fact, this is what proland does to improve performance, once past a certain distance the water is disabled and the water color and sun reflection are rendered directly in the terrain shader.I did some progress on the water shader but there is still a huge issue I haven't figured out and so I might take another break from it and do something else first. I've already started working on full EVE compatibility but haven't had that much free time to put into it yet. I've actually been putting off multiple planets because it's a bit of a "chore" to do and I wanted to do the fun stuff first, there's also that reflectedlight thing that should get rid of soupiness from orbit. To summarize I'll probably have full EVE compatibility ready this week-end or somewhere in the middle of next week and after that it's either fixing the water or adding multiple planets.You're right about the blur at the horizon, I always see it happening in real-life and can never tell where the sea ends and the sky begins, especially if I'm looking at it from a mountain. I can see this being feasible in the postprocessing shader.To get smooth results I always make sure to multiply the default Rt and RL values by the same coefficient, I basically don't change their ratios, and then I play with HR until it looks right, HM is more forgiving but generally gives a really cloudy/heavy atmosphere feel. Because the atmospheric model used in proland requires physical correctness, artistic control can be really limited but keeping the default ratios of Rt and RL generally results in good results, this is how I do it anyway.Also, if you're getting the round patches past 200km, ignore these, these are caused by my "experimental" idea of changing the camera's clipping planes once they reach their limit and the way I do it right now is really messy, it doesn't mean your atmosphere isn't right and it'll probably work fine in future versions. Edited June 3, 2015 by blackrack Quote Link to comment Share on other sites More sharing options...
V8jester Posted June 3, 2015 Share Posted June 3, 2015 Hey I had a question. Will the waves in the water you are working on, affect a floating craft? Or will the craft settle into a static position same as it does in vanilla? Quote Link to comment Share on other sites More sharing options...
BudgetHedgehog Posted June 3, 2015 Share Posted June 3, 2015 will the craft settle into a static position same as it does in vanilla?That one.Anyway, yer a wizard, blackrack. It's looking gorgeous! Quote Link to comment Share on other sites More sharing options...
SmallFatFetus Posted June 3, 2015 Share Posted June 3, 2015 (edited) Could a script be set up to gently rock the capsule/boat/whatever when smashed down?Could you add better splashes?Cloud you add better sounds, and get rid of the loud-and-ugly-sounding "WHUMP" when you hit the water?Could you add some nice noises of water lapping against the side of the craft?Wonderful job on the water. It's coming along nice.SmallFatFetus Edited June 3, 2015 by SmallFatFetus Quote Link to comment Share on other sites More sharing options...
RyanRising Posted June 4, 2015 Share Posted June 4, 2015 (edited) Could a script be set up to gently rock the capsule/boat/whatever when smashed down?Could you add better splashes?Cloud you add better sounds, and get rid of the loud-and-ugly-sounding "WHUMP" when you hit the water?Could you add some nice noises of water lapping against the side of the craft?Wonderful job on the water. It's coming along nice.SmallFatFetusPizzaoverhead (Your go-to sound guy) has a mod for that last one, but I think that the scope of this mod is just visual effects.It doesn't actually sound too hard to make a small torque in the water that rocks your vessel back and forth when it's "Splashed Down", but I have no coding experience. I don't think it would add too much to your experience, though, and it does sound near-impossible to make it sync up with the waves. The water sounds mod is here. Edited June 5, 2015 by RyanRising More specific. DISCLAIMER: It doesn't sound too hard, but it might be very, very difficult. I can't tell. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.