WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 04-29-2010, 05:34 AM
guof6570969 guof6570969 is offline
Member
 
Join Date: Apr 2010
Posts: 6
Cool how to add texture to an object

Hi all,sorry to trouble you
this is my problem:
the code is :
myTex = viz.addTexture('lake3.jpg')
myScreen = viz.add('screen3.IVE' )#my model,contains a suface named "Plane01"
myScreen.setPosition(0,0, 60)
Plane = myScreen.getChild('Plane01')
Plane.rotate(1,0,0, 45)
import vizmat
matrix = vizmat.Transform()
matrix.setScale([1.5,1.5,1])
Plane.texture(myTex)
Plane.texmat(matrix)

but the result is :

the color of the model is only green

i think may be this is due to the Texture Coordinates
but what should i do now ?

I am a newer!
Reply With Quote
  #2  
Old 04-30-2010, 02:25 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Make sure the object is exported with a texture applied. If no texture is applied, then the object does not have UVW coordinates.

In the future please use code tags when posting code. That will preserve any indentation and is easier to read.
Reply With Quote
  #3  
Old 05-06-2010, 10:18 PM
guof6570969 guof6570969 is offline
Member
 
Join Date: Apr 2010
Posts: 6
thank you
Jeff
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to apply shader and render texture to an object whj Vizard 0 04-23-2010 12:23 PM
adding texture to each sub object dwaik Vizard 2 02-09-2010 01:05 AM
retrieve Object names Geoffrey Vizard 11 12-11-2009 04:26 AM
Applying texture or colour to an on-the-fly object tomo_the_third Vizard 1 06-22-2009 11:12 AM
Move texture from one object to another Johannes Vizard 2 02-09-2005 03:55 PM


All times are GMT -7. The time now is 06:41 PM.


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