Hi, it’s been a week.
It’s been a week.

This time, I’ll be working on a water surface shader…or rather, a boundary surface shader.

After some twists and turns, the in-game image is

It looks like this.

And now

This is how it looks like now.

As for the difference, the artist’s intention was that the boundary surface should not be curved, or rather, it should be jagged.

Furthermore, he asked us to add a movement like a sound waveform, as if it were an echo of sound.

The purpose of this is to solve the problem that the waves are moving but the boundary line is stopped, which looks uncomfortable.
As for the sound waveforms, we originally had the idea to incorporate a visualization of the reverberating image of sound in water in our worldview.

So, here is an image of the waveform in motion.

It is subtle.

It seems that the effect is not so good even if we jaggle them in random directions.

Then, let’s look at the stopped picture using only rectangles.

Surprisingly, it is not bad.
I guess you could call it a deformed representation of the water surface.
The setting is left as it is, but the game space is a deformed expression, a bit like the NES or Pac-Man.

This is what I saw when I filled in the edges.

It’s a bit noisy now, isn’t it? It looks better than last time.
I have the impression that a certain amount of black is necessary between the border and the border.

I tried to deform the edges.

This is the state where the normal direction is taken out and the vector that vibrates the sound waveform is calculated out.
I feel that detail was added in a good way and also somehow added a sense of jaggedness to the borders of the ingame image.

The sound waveforms are then added.
The sound waveforms were first randomly wobbling, but I rejected it because it was totally subtle and made the picture look like an insect crawling around.
I tried to use a temporary BGM from Rainbow Dora and put the waveform into it.

Then, surprisingly, it was not so bad.
Maybe random numbers with some regularity are more comfortable for humans than completely random numbers.

In addition, I tried to dynamically generate a bubble-like membrane with polygons to represent the place where recovery is possible (null field).

This is only tentative because the material has not been created yet, but I think it gives a sense of the atmosphere of the place. I think.

The color adjustment, texture, shader parameters, etc. are all tentative, so I’m going to make a debugging editor so that I can adjust these things.
See you soon!

【Irisy Aqua】ランダムSEED、その名は音波!

どうも一週間ぶりです。
Otorakoboです。

今回は水面シェーダ…というか境界面シェーダを作り込んでいきます。

紆余曲折あって、インゲームイメージは
{画像}
こんな感じ。

で、現在は
{画像}
こんな感じ。

差分としては、境界面が曲線じゃなくても良いというか、ギザらせた方が良いというのがアーティストさんの意向。

さらに、音の反響をイメージしたようなサウンドの波形のような動きを付けてくださいとのこと。

なんでも、波は動いているのに境界線が停止しているのが違和感に見えることを解消するのが目的らしいです。
音の波形に関しては、水の中に音を入れた時の反響イメージというのがもともと世界観にあり、そのビジュアル化を取り入れてはというところからアイディアを頂きました。

だもんで、一回そのままジャギらせて動かした画像がこれ
{画像}
微妙です。

やはりランダム方向にジャギらせても効果は薄いみたいです。

じゃぁ、一回四角形だけで表現して停止絵を見ようかなと作ったのがこれ
{画像}
意外と悪くないです。
水面をデフォルメした表現とでも言うんですかね?
設定はそのままにしつつ、ゲーム空間はデフォルメ表現というちょっとファミコンというかパックマン感が出てきました。

そのままエッジを埋めて見たのがこれ
{画像}
ちょっとうるさくなったような?前回の方が良い感じ
どうも境界線と境界線の間に一定の黒は必要な印象です。

エッジを変形させてみました。
{画像}
法線方向を取り出し、音の波形を振動するベクトルを計算で出した状態です。
良い感じでディティールが付与されて、しかもどことなくインゲームイメージの境界線のジャギ感がプラスされた気がします。

これに音の波形を載せて見ます。
音の波形は最初ランダムでゆらゆらさせてたんですが、まったくもって微妙な感じで、虫が這ってるような絵になったので却下。
試にBGMを仮で虹ドラからちょっぱってきて、その波形をぶち込んでみました。
{動画}
そしたら、意外と悪くないというか、良かったです。
完全なランダムよりもある程度規則性がある乱数の方が人間は心地いいのかもしれませんね。

ついでに回復できる場所(Nullのフィールド)表現も泡っぽい膜をポリゴンで動的生成してみました。
こっちは、まだマテリアルが出来てないんで仮仮の仮ですが、雰囲気だけは見えるようになったのかな?と、思います。

色味の調整やらテクスチャ、シェーダのパラメータなどは全部仮なんで、今度はこの辺りを調整できるようにデバッグエディタを作っていこうと思います。
それでは!