Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 05 May 2011
Offline Last Active Today, 02:17 AM

Posts I've Made

In Topic: Diffuse IBL - Importance Sampling vs Spherical Harmonics

Yesterday, 02:03 PM

So I'm correct in assuming that you're using the same approach as your specular where you're sampling off of a fairly high resolution HDR cubemaps for your diffuse results?

If so, don't bother, because as you've figured out for yourself that will require a massive amount of samples to get working nicely as you're sampling the entire hemisphere rather than a focused area as you would with glossy specular materials.


What you could do here is filter and downsample a seperate HDR cubemap offline just like how you would approach filtering your specular mip levels for high roughness values, but just for your diffuse term. You can use a similar importance sampling approach to do this. This gives you a fairly tiny texture which should give very acceptable results with only a minimal amount of samples required. At this point you should consider just doing an SH representation though as that will give pretty much the exact same results (as you're dealing with very low frequency data anyway) with a lower memory footprint, but if you're not familiar with that just yet you can experiment with just the separate diffuse texture.


Whether you use an SH approach or a texture-based one will not make a huge change in the end result as we're dealing with very low frequency data here anyway. Spherical harmonics are just another way to represent your data, they're not a different way of generating that data. You'll still need to sample your diffuse data somehow before you can store it.


Additionally you won't need any type of LUT as your diffuse term is usually solely dependent on your normal vector, unless you're doing some expensive fancy diffuse model which is view-dependent or which takes surface roughness into account. Even if that would be the case, this usually results down to taking your fresnel factor into account somewhere which can be accounted for after sampling your diffuse IBL.


(PS: Dag Kevin, lang geleden!)

In Topic: BRDFs in shaders

05 February 2016 - 12:19 PM


All I care about is shader code, really..

I take that back, I was really mad.

I did, however, give up on the explanations from Real-Time Rendering. They are really hard for me to understand.

Also, it seems like the author was explaining PBR without saying it was PBR..?


I'm looking for better (easier) explanations about this topic, rather than the book yoshi_t mentioned. Any idea?



As a piece of advice, it might be better to work through the hard stuff if you want to understand BRDFs and PBR. You're going to hit a point where there's no way around the math and radiometry theory, and you're going to hit it fast.


You're entering a realm of graphics where there's no more training wheels, better get used to it sooner rather than later.

In Topic: Footware at work

04 February 2016 - 08:57 PM


Yeah, just get some slippers/loafers/sandals -- something with a rubber sole though; I don't think I'd like using communal bathroom facilities with a foam or cloth foot-bottom, not to mention subsequently tracking it all over the office. Something comfy, easy on/off, and suitable for indoor/outdoor use is probably a good place to start.




Yeah got some of those slippers that look like big fluffy bunny rabbits.  If the rules change to stop fluffy slippers then you know somebody is out to get you.



It's unicorns for me. Seems like taking off shoes and walking around on socks is very common at our office, but I guess it really does depend on the company.

In Topic: transition barrier strictness

24 January 2016 - 02:43 AM

You're right, the debug layer does not notify you of all transition issues yet, so the fact that it doesn't complain about things doesn't mean that your code is correct. Expect these issues to turn into errors at some point in time.


There's not a lot of hand holding in D3D12, make sure to do your research and cover all cases.

In Topic: Developing an Ocean Shader for Unreal Engine 4

14 January 2016 - 12:52 PM

The surface in yours looks like a large ocean of jello. The primary reason for this is you stretch and compress the whole mesh even the finest details. From watching videos of oceans waves the high noise and slow moving froth stay in place and move much less than the low frequency waves and crests. When watching videos it's like you start with a large taunt blanket then you have high frequency noise that moves very little in relation to the lower frequency waves. As you add lower frequencies of waves the movements go up and they affect each other more. Also low frequency waves crest. The lower the frequency (larger) the wave the more foam. You lose a lot of detail without this.


Also for more realistic rendering (which adds a lot to the overall effect) you might want to render your objects first to a texture and extract a depth map. Then use that when rendering the water and take the difference between the depth values. Using something like beer-lambert for the depth based transparency would add a lot. (I'm sure there's a paper with a more accurate volumetric transparency though for the water).


Absolutely this. Your water surface looks like a thin piece of highly specular elastic fabric constantly being stretched and then relaxed. As Sirisian said this absolutely works for creating the illusion of low frequency movement, but it breaks down quite badly for your high frequency details. Introducing independent movement for your high frequency details should help quite a bit.