WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rating: Thread Rating: 12 votes, 5.00 average. Display Modes
  #1  
Old 04-18-2013, 11:05 AM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Which examples did you have trouble running? Vizard should be able to load the .jpgx files included with Teacher in a Book. Those files can be referenced without the 'x' added to the extension in the script.
Reply With Quote
  #2  
Old 04-21-2013, 10:34 PM
cgsong58 cgsong58 is offline
Member
 
Join Date: Apr 2013
Posts: 7
I think I have refer to files in correctly.

Quote:
Originally Posted by Jeff View Post
Which examples did you have trouble running? Vizard should be able to load the .jpgx files included with Teacher in a Book. Those files can be referenced without the 'x' added to the extension in the script.
Balloon example (p19)
Even though I hace used 'art/balloon.IVEx'
I have the following error message:

Traceback (most recent call last):
File "<string>", line 11, in <module>
File "C:\WorldViz\Vizard1.py", line 10, in <module>
balloon = viz.add( 'art/balloon.IVEx' )
File "C:\Program Files (x86)\WorldViz\Vizard4\python\viz.py", line 9407, in add
raise ValueError, 'Unrecognized file extension: '+fileType
ValueError: Unrecognized file extension: IVEX
** Load Time: 0.08 seconds
Reply With Quote
  #3  
Old 04-22-2013, 07:57 PM
cgsong58 cgsong58 is offline
Member
 
Join Date: Apr 2013
Posts: 7
Problem in loading *.jpgx file in art folder

Quote:
Originally Posted by Jeff View Post
Which examples did you have trouble running? Vizard should be able to load the .jpgx files included with Teacher in a Book. Those files can be referenced without the 'x' added to the extension in the script.
Jeff,

I have run the texture example demo ("texture coordinates demo.py) but I couldn't have correct images, foliage.jpg, and pine needles.jpg.
My code is as follows:

import viz
viz.go()
viz.clearcolor([.3,.3,.3])
viz.mouse( viz.OFF )
viz.MainView.setPosition(0,0,-1.5)

#Add the texture quad and the texture to put on it.
quad = viz.addTexQuad()
textures = []
files = ['foliage.jpg','pine needles.jpg' ]
for i in range(len(files)):
texture = viz.addTexture( 'art/' + files[i] )
texture.wrap( viz.WRAP_S, viz.CLAMP_TO_EDGE )
texture.wrap( viz.WRAP_T, viz.CLAMP_TO_EDGE )
quad.texture( texture, '', i )
textures.append( texture )

#.... I have cut at this point
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
Help with File Reading/Writing Lynnifer Vizard 2 03-12-2012 07:51 AM
Closing of an imported .py file Uttama_vizard Vizard 2 05-04-2010 07:18 AM
IVEx file extenstion unrecognised. sindi Vizard 2 12-10-2009 02:20 AM
Read file....many issues Uttama_vizard Vizard 9 07-08-2008 03:16 PM
File Management Uttama_vizard Vizard 2 07-01-2008 10:44 AM


All times are GMT -7. The time now is 05:32 AM.


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