从数学的角度来看,是否可以从高度贴图纹理生成法线贴图? [英] Is it possible generate normal map from heightmap texture from math point of view?

查看:306
本文介绍了从数学的角度来看,是否可以从高度贴图纹理生成法线贴图?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的观点是,你只能从高度贴图纹理生成法线贴图吗?
我是否正确?

数学参数:

假设表面从



S = [0,1]

T = [0,1] p>

让我们称SxT为图像空间。

从差分几何可以证明,该参数曲面的法线是





如果假设从SxT图像空间到几何欧几里得空间的映射非常简单,那么我们可以回顾一下:



然后你可以计算这种偏导数具有一些差异性。
我们来到了这个简单的公式,只有粗体建议,这个建议绝对是不正确的。




图形问题示例。假设我们有三个顶点的几何eclidian空间中的三角形。
术语是:

normalmap -
对于(u,v,1-uv)点是正常的)从合适的二维纹理(u,v)中提取的重心坐标,它位于局部坐标系中。系统相对于三角形。

heihtmap -
它是(u,v,1-uv)点的几何偏移量,在正常方向上的重心坐标相对于从合适的2d纹理中从(u,v)中获取的三角形局部空间。

在构建法线贴图的过程中,我们完全忽略了高度贴图如何在(u, v,1-uv)eculidian点。我们只回顾一下法线贴图的一些近似值。

解决方案

对我来说,我自己的第一个问题是无效的,它有一个错误! !


I - 域为笛卡尔积[0,1]的原始参数曲面,它的范围为欧氏空间



II - 原始表面的正常值

III - 使用高度图修改原始表面



IV - 我们希望接收的法线贴图,即使忽略了III对曲面的几何修改



最后一步IV包括很多东西来区分:H(s,t)和函数的原始定义...我不进行进一步分析该方程...但对于我,你不能从(高度图)只生成法线贴图...

PS若要执行进一步分析,请从该位置收回* .docx文件 https:// yadi。 sk / d / Qqx-jO1Ugo3uL 据我所知,不可能把公式中的单词转换成乳胶,但无论如何,请用它作为草稿。


My view is that you can not generate normal map only from height map texture? Am I right or not?

Math Arguments:

Assume that surface is given a continuous bijection from

S = [0,1]

T = [0,1]

Let's call SxT as image space.

It can be proved from differentional geometry that normal to that parametric surface is

If assume that mapping from SxT image space to geometric euclidian space is very simple then we can retrive:

Then you can calculate such partial derivatives with some difference scheme. We came to that simple formula, only with bold suggestion and this suggestion is absolutely not true.


Sample of the problem from graphics.

Let assume we have triangle in geometric eclidian space with 3 vertices. Terms are:

normalmap -- it is normal for point with (u,v,1-u-v) barycentric coordinates fetched from (u,v) from suitable 2d texture, and it is in local coord. system relative to triangle.

heihtmap -- it is geometric offset for point with (u,v,1-u-v) barycentric coordinates in normal direction relative to triangle localspace fetched from (u,v) from suitable 2d texture.

During building normalmap we absolutely ignore how heightmap is distributed near (u,v,1-u-v) eculidian point. And we retrive only some approximation of normal map.

解决方案

For me my own initial question is invalid and it has a bug!!!

I – original parametric surface with domain as cartesian product of [0,1] and range of it as euclidean space

II - normal to original surface

III - modified original surface with heightmap

IV - normal map which we want to receive with even ignoring geometric modification of the surface by "III"

Final step IV includes a lot of stuff to differentiate: H(s,t) and original definition of the function...I don't perform futher analytic of that equations...But as for me you can't generate normalmap only from (heightmap)...

P.S. To perform futher analytics if you want to do it retrive *.docx file from that place https://yadi.sk/d/Qqx-jO1Ugo3uL As I know it impossible to convert formulas in ms word to latex, but in any case please use it asa draft.

这篇关于从数学的角度来看,是否可以从高度贴图纹理生成法线贴图?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆