WorldViz User Forum

WorldViz User Forum (https://forum.worldviz.com/index.php)
-   Vizard (https://forum.worldviz.com/forumdisplay.php?f=17)
-   -   TexQuad Visibility (https://forum.worldviz.com/showthread.php?t=6111)

miss 02-20-2018 05:56 PM

TexQuad Visibility
 
I have set up a screen with multiple textures in a single quad using a for loop. I have used the viz.addTexture command to add textures from a list I have specified before.

However, I want to remove the visibility of these textures on viztask.waitKeyDown. I am unable to do so. Can anyone please help me out with that?

Jeff 02-21-2018 09:18 PM

Here's an example that removes a texture from a texture quad:

Code:

import viz
import viztask
viz.go()

piazza = viz.addChild('piazza.osgb')
texture = viz.addTexture('lake3.jpg')
quad = viz.addTexQuad(pos=[0,1.8,3])
quad.texture(texture)

def textureTask():
        yield viztask.waitKeyDown(' ')
        quad.texture(None)
        yield viztask.waitKeyDown(' ')
        quad.texture(texture)
        yield viztask.waitKeyDown(' ')
        quad.remove()
       
viztask.schedule( textureTask() )



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

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