-
Posts
2,533 -
Joined
-
Last visited
Content Type
Profiles
Forums
Developer Articles
KSP2 Release Notes
Everything posted by blackrack
-
WIP - Environmental Visual Enhancements Development
blackrack replied to rbray89's topic in KSP1 Mod Development
So I guess I'm not the only one having trouble with scaled space then... -
Actually that was exactly what happened, I was monkeying around with the debug settings in the KSC view then caused it to glitch and get stuck somehow and cover up the whole KSC, I couldn't see anything, I tried to pan the camera and I accidentally pressed the VAB (which was now invisible and covered by the stuck effect covering the whole screen), next thing I know the VAB comes up and the view from inside it is glorious! So I decided "hmm, this seems like a great idea to implement later". It doesn't "work" yet, as in, it was completely accidental and didn't follow the camera movement but I should be able to make it work later.
-
So I'm trying to get the shaders working in scaledSpace (still stuck there). I set the mesh to render in layer 10 and change it's parameters accordingly, however, I think it might be rendering behind the skybox or not rendering at all. I'll try playing with the renderqueue later, but for now, what's a quick way to disable the skybox? Edited: Nevermind, I got it to draw on top of everything by using Ztest off or Ztest always. At least now I know it's a render order issue. Good to know.
-
The default config already works on these, but the problem is, they make the terrain pretty flat so it looks very bland. In addition, and this is some weird behavior on the part of the mod, but a bigger planet sort of "stretches" and "dilutes" the atmosphere (if it makes sense) and it needs an adjusted config. I haven't played much with 6.4x kerbin but here's a random screen http://i.imgur.com/rak45U0.jpg So wait, the config tool isn't working for anybody but me right now? Hold on, let me check on another machine. Edited: Works perfectly well here, both directly and while adding the -force-d3d11 command. Is anybody else unable to run it?
-
Thanks a lot, it works.
-
If anyone has successfully compiled loadOnDemand for 0.90 can I please have a copy? I don't feel like compiling from source and setting up dependecies.
-
WIP - Environmental Visual Enhancements Development
blackrack replied to rbray89's topic in KSP1 Mod Development
I'll try some old-fashioned debugging first, by adding a gigantic UI that changes every parameter to every single possiblity until it works, funny enough, this is how I got the sky shader to work when I got stuck on it and it was rendering gibberish to the screen. Then if it doesn't work I'll clean up the code a little so it's understandable and update github. -
WIP - Environmental Visual Enhancements Development
blackrack replied to rbray89's topic in KSP1 Mod Development
Rejoice brethren, our hero is back! Btw I got stuck on that scaledspace thing today and decided to get a break and come back to it when I'm thinking clearly. -
Hi rbray, not sure I understand how to do that, my shader doesn't necessarily need to be a post-processing shader, but I need some information about the terrain position and distance, either by applying the shader straight to terrain objects or by using the depth buffer to get said information. Could you elaborate more on your cube method? Is it just a cube that I render the same shader to, instead of rendering to the camera or what?
-
Is there anything other than shaders not supported in the little debug box? With directX11 and shader model 5 it should work. If you're on a laptop maybe it's starting on the IGP? I remember Optimus being buggy as hell, if I'm not mistaken, there's a setting somewhere that allows an application to start on the GPU instead of the iGPU. If all else fails I think plugging in a hdmi monitor or TV forces everything to run off the main GPU.
-
It's alright, i'm guessing if you try downsampling (not sure if it works with KSP) the dark pixels would go away, It's just a guess though so it may or may not work. The dark pixels are also definitely more pronounced in dx11 and opengl (both buggy as hell with the postprocessing shader). No idea about the timewarp but it never happened to me using scatterer and a heavily modded install.
-
I have problems getting scaledspace to work correctly, I know how you scale things up or down and the coordinate system changes, but the problem is my shaders have to be fed the cameraToWorld matrix and the camera's transform.forward as well as other stuff. The problem is, I can't find a way to translate these things to scaledSpace coordinates so the shaders are working wrong because they think the camera is in a completely different position and orientation. The red thing is fixed and will be released in the next update. The line of dark pixels is inevitable for now because the depth buffer the game writes is always aliased. I'll do the menu thing.
-
I will give it a read, thanks. I have to mention though, the postprocessing runs fine (I did set it up with a camera's script using OnRenderImage since it's the only way it'd work). It's the sky that lags behind, I will try setting up the sky so that it runs this way, but, should the shader parameters be also updated inside OnRenderImage? I'm guessing they should. Edited: Wow, such a simple fix, and it worked so well. You're awesome Starwaster!
-
It seems I might need help with this one, I've been trying to fix the bug where the sun and the atmosphere effect seem to not to keep up with the camera. The effect is always running one frame behind no matter what, it is especially jarring if you're getting low framerates. I tried to move the drawmesh() call thingy up to the start of the update function, before the shader is updated with the new frame parameters to see if it will start running behind by two frames. I boot up KSP, limit framerate to 5 fps and... it still runs behind by one single frame, so no matter where I put it, it still gets called before it's parameters are updated. I tried making a specific lateUpdate() function that would only have the drawmesh() call in it, I tried using a classic meshrenderer, I tried using drawMeshNow() in a script attached to the camera but nothing helps. If anyone have any ideas I'd really appreciate it. You could try just changing the settings at random, or as a last resort installing a different driver, I really have no idea what it could be.
-
I have some issues using a camera's worldToCameraMatrix in KSP, the result I get seems to be always delayed by one frame, or acts in weird ways. Either these work weird in KSP or KSP does something weird where it moves objects but doesn't update their transforms where you rotate the camera (this is unlikely). Anyway, my question is, how do I recreate that amtrix by myself using the camera's transform? I know you need the camera's transform but this is where math fails me (a snippet of code instead of an analytical explanation would be highly appreciated). Edited: Ignore this thread, I found the problem and it's somehting so much simpler.