BumpMapGenerator avaible!?

2 views
Skip to first unread message

martin

unread,
Nov 25, 2009, 7:09:50 AM11/25/09
to away3d.dev
hello,
is in away3d a bumpmpgenerator avaible? i want to create a normalmap
with appling a bump on runtime.
generating a normalmap from my source image is no problem, but i want
to use the applybump-method from the normalmapgenerator class and the
bumpsource should come from the original image with an generator or
other function.
thx
martin

Fabrice3D

unread,
Nov 25, 2009, 8:32:41 AM11/25/09
to away3...@googlegroups.com
Hi Martin,
I'm not sure I do understand your question...

but may be you mean this?

var nmg:NormalMapGenerator = new NormalMapGenerator();

bm:BitmapData --> bumpmap
nm:BitmapData --> normalmap

nm = nmg.applyBump(bm, nm);

Note that the volumetric bump available in Prefab with variable height
is not available in the trunk yet.

Fabrice

martin

unread,
Nov 25, 2009, 4:42:36 PM11/25/09
to away3d.dev
this is clear
+ var nmg:NormalMapGenerator = new NormalMapGenerator();
+ bm:BitmapData --> bumpmap
+ nm:BitmapData --> normalmap
+ nm = nmg.applyBump(bm, nm);
but this line "+ bm:BitmapData --> bumpmap" - i want does't use a
library source, i want to creat at runtime a bumpmap from my texture.
is this possible in away with the api, like this "var
bitBump:BitmapData = bumpmapgenerator(source);"
thx

Fabrice3D

unread,
Nov 26, 2009, 4:04:48 AM11/26/09
to away3...@googlegroups.com
this was pseudo code,
I assume here you do know how to generate/load/access a bitmapdata
object.
If not reffer to AS3 general documentation.

> is this possible in away with the api, like this "var
> bitBump:BitmapData = bumpmapgenerator(source);"
no. use the code provided in previous mail
just change these line with non-pseudo code

> bm:BitmapData --> bumpmap
var bm:BitmapData = someFunctionthatReturnMeTheSourceBitmapData or
BitmapDataObject.

b & m stands for this example as Bump Map
n & m stands for this example as Normal Map

Fabrice

martin

unread,
Nov 26, 2009, 4:25:39 AM11/26/09
to away3d.dev
ok thx, i try it...
martin
Reply all
Reply to author
Forward
0 new messages