마법적 구슬형태 제작



마법적 구슬형태 제작

금별 0 3,579 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


번호 포토 분류 제목 글쓴이 날짜 조회
1167 3D 3DS Max - 직각 Sword Slash 메쉬 제작방법 금별 05.23 1138
1166 언리얼4 언리얼/후디니 - 코페르니쿠스 시뮬레이션 데칼을 언리얼에서 활용하는법(한글자막) 금별 05.21 1347
1165 언리얼4 언리얼5 - 죽음 디졸브 이펙트 Niagara SkeletalMesh Location 사용 금별 05.21 1215
1164 언리얼4 후디니/언리얼 - 유체 및 불규칙한 동적 오브젝트를 UE로 내보내는 두 가지 방법 – ABC와 버텍스 애니메이션 금별 05.20 1210
1163 유니티 유니티 - 음률 리듬 VFX 제작 가이드(한글자막) 금별 05.20 1186
1162 유니티 유니티 - 별빛 VFX: 단계별 제작 가이드(한글자막) 금별 05.20 1264
1161 유니티 유니티 - Ice Cone과 Spike 제작 가이드(한글자막) 금별 05.20 1176
1160 유니티 유니티 - 입체 오각형/육각형 텍스처와 모델 제작 가이드(자막) 금별 05.20 1256
1159 언리얼4 언리얼5 - Burn Transition Material 예제 및 노드 금별 05.18 1161
1158 언리얼4 언리얼5 - 커스텀 노드를 활용한 줌블러 예제 및 코드 금별 05.18 1141
1157 언리얼4 언리얼5 - 버텍스 색상과 결합한 마스크 활용한 버텍스 오프셋 제어간단제작과정 금별 05.18 1154
1156 유니티 유니티 - URP로 구현하는 후처리 VFX: 흑백 플래시와 화면 왜곡 제작팁 금별 05.18 1413
1155 언리얼4 언리얼5 - Cold Smoke 효과와 Ice Debris 제작과정(한글자막) 금별 05.18 1161
1154 언리얼4 MAGIC of Material in UE5 ashif 05.14 1110
1153 언리얼4 Step-by-Step: Design Stunning Level Up FX in Unreal Engine 5 ashif 05.13 1144
1152 언리얼4 언리얼 - 나이아가라 캐쉬 간단 사용방법 금별 05.12 1137
1151 언리얼4 Unleash the Magic: Crafting Material Spells in UE5 Niagara ashif 05.10 1126
1150 언리얼4 Create Stunning Ghost Trails in Unreal Engine 5 with Niagara ashif 05.09 1324
1149 언리얼4 언리얼5 - UV 조작으로 만드는 동적 그래픽(더빙) 금별 04.29 1297
1148 언리얼4 언리얼 - 페이지 넘긴 효과 머트리얼 구현과정 금별 04.29 1201
1147 언리얼4 언리얼 - 간단한 Procedural Dissolve제작노드 금별 04.25 1203
1146 언리얼4 에픽 라이브 - 스타일라이즈드 번개 이펙트 만들기(린반) 금별 04.25 1102

 

Banner
 
Facebook Twitter GooglePlus KakaoStory NaverBand