마법적 구슬형태 제작



마법적 구슬형태 제작

금별 0 4,223 2019.08.30 06:32

 

I guess this is the first entry to this category, since I never had such a demand for a write-up before. So here goes!

The different between this format and regular “My take on shaders” post is that this is a more direct format, just going through a particular effect that I find too specific to write a complete tutorial about. Also, in some cases, like this one, I won’t be providing the completed code but I will be writing about the general idea and the process behind the specific effect.

In my tweet I mentioned it being a form of “raymarching” though I might be using the term loosely here. While I use a loop to move towards a certain direction, the technique doesn’t really resemble traditional raymarching. So keep that in mind.

 

The core idea

 

I’ve been constantly thinking about how to take advantage of past effects, and in this case I had an idea concerning the “layered parallax” effect that I demonstrated in an older post.

With that technique, you could sample a texture using coordinates that had been offset “inwards” of the object, by using the camera’s view direction in tangent space. The effect is super useful for adding some depth to materials like ice, or tiles or basically anything you want to make it look like “there’s something underneath the surface”. The result looked something like this:

 

 

My thoughts going from this effect were these:

  • Let’s ditch the main texture, don’t need it for now
  • What if in every “layer” of this effect, I performed a “step” function on a 2D noise texture, where the cutoff value ranges from 0 to 1 based on the “index” of the layer?

The “stepping” (that’s what I’ll call “using the “step” function” from now on) was inspired by the concept of using grayscale textures as heightmaps, with their value representing depth. Adjusting the cutoff value of a simple texture with a radial gradient looks like this:

 

As if the texture actually represents a cone and when I’m using “step” I’m cutting slices into it which decrease in size as I get to the top. Basically I’m super-over-explaining SDFs here, but that representation really helped clear things in my head.

So, if I were to assign 1 to the cutoff value of the out-most layer, 0 to the value of the deepest layer and the inbetween values to the inbetween layers, each parallax layer would have a differently sized “slice” of the texture.

If we add that “stepping” to each layer, with the same radial gradient texture, we end up with something like this (the texture is tiled 5 times so just pay attention to the middle one):

 

This uses 10 iterations on the grayscale texture

Turn up the iterations/number of layers (here it’s something 128) and you have smoothness:

 

Add a somewhat more complex texture, like a simple cloud texture and you have this:

 

 

Trying out random textures and noises is super fun with this one btw.

Add the material on a sphere and you have the ORB:

 

 

Add 2 HDR colors, and lerp between them based on the layer “index” instead of just lerping the intensity from 0 to 1 (also some Post-processing for the looks):

 

 

Add some waving displacement when sampling the texture in each layer for some extra variation and *magic*:

 

 

And that’s it! I hope that was helpful and I hope there will be many more write-ups in the future, especially as I’m easing into VFX stuff at the moment of writing. So, I’ll see you in the next one! ????



 

These posts will never go behind a paywall. But if you really really super enjoyed this post, consider buying me a coffee, or becoming my patron to get exciting benefits!

 

Comments


번호 포토 분류 제목 글쓴이 날짜 조회
1331 언리얼4 Head Burst FX in Unreal Engine 5 Niagara ashif 15:01 10
1330 언리얼4 Glitch Aura in Unreal Engine 5 Niagara ashif 14:25 13
1329 언리얼4 언리얼 - 유성우 효과 제작과정(한글자막) part3 금별 13:27 15
1328 언리얼4 언리얼 - 유성우 효과 제작과정(한글자막) part2 금별 13:27 13
1327 언리얼4 언리얼 - 유성우 효과 제작과정(한글자막) part1 금별 13:26 14
1326 언리얼4 언리얼 - 나이아가라 파티클 패스 애니메이션 제작팁 금별 04.29 78
1325 언리얼4 【UE5+Houdini】리듬 댄스 이페트 제작과정 파트 2 금별 04.29 61
1324 언리얼4 【UE5+Houdini】리듬 댄스 이페트 제작과정 파트 1 금별 04.29 59
1323 언리얼4 Gilded Aura FX in Unreal Engine 5 Niagara ashif 04.28 59
1322 언리얼4 Floating Rocks FX in Unreal Engine 5 Niagara ashif 04.26 81
1321 언리얼4 【UE5】거품 재질 만드는 법 금별 04.25 172
1320 언리얼4 【UE5】래디얼 블러를 구현하자! -Niagara 편- 금별 04.25 152
1319 언리얼4 【UE5】래디얼 블러를 적용해 보자! -Sequencer 편- 금별 04.25 133
1318 언리얼4 【UE5】래디얼 블러를 만들어 보자! -준비 편- 금별 04.25 149
1317 언리얼4 언리얼 - Stylized 검기 효과 구현 방법/범용쉐이더 구조 분석(한글자막) 금별 04.19 181
1316 언리얼4 언리얼 - UI 테두리 흐름 쉐이더 제작과정(한글자막) 금별 04.19 153
1315 언리얼4 【UE5+후디니】UV 커스텀 무기 디졸브 기반 빠른 모델 제작_파트 2 금별 04.09 238
1314 언리얼4 【UE5+후디니】UV 커스텀 무기 디졸브 기반 빠른 모델 제작_파트 1 금별 04.09 194
1313 언리얼4 【UE5+후디니】루빅 큐브형태 애니메이션 연출 생성과정(한글자막) 금별 04.09 189
1312 언리얼4 【UE5+후디니】Stylized형태 검기을 생성 제작과정(한글자막) 금별 04.09 197
1311 언리얼4 【UE5+후디니】 동적 디졸브 구쉴드 생성 과정(한글자막) 금별 04.09 186
1310 언리얼4 Arcane Magic Lightning Eruption FX in Unreal Engine 5 Niagara ashif 04.05 190

 

Banner
 
Facebook Twitter GooglePlus KakaoStory NaverBand