WorldViz User Forum

WorldViz User Forum (https://forum.worldviz.com/index.php)
-   Vizard (https://forum.worldviz.com/forumdisplay.php?f=17)
-   -   Adding BumpMaps (https://forum.worldviz.com/showthread.php?t=3089)

sleiN13 11-19-2010 04:17 AM

Adding BumpMaps
 
I'm trying to add bumpmaps to a simple cube and ran into a few weird problems.
The vizard help file doesn't give a lot of results on 'bumpmap' so I wondered if I was doing it wrong.

Code:

cube = viz.add('Export//BumbmapCube.osg')
bumbmap = viz.add('Export//images//bumpmap_normalmap.jpg')
text = cube.getTexture()
cube.bumpmap(bumbmap,'',0)
cube.texture(text,'',1)
cube.appearance(viz.DECAL)

This code works but it is strange that i need to get the texture and re-set it after applying the bumpmap else it is not shown in the world.

1. Is there a way to apply the bumpmap with out overwriting/removing the existing texture
2. Is there a more elegant way to add a bumpmap
3. Is there a file format that exports the bumpmaps added in 3DS max and/or Maya so that it does not have to be added later on in the Vizard code.


All times are GMT -7. The time now is 10:56 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC