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 04: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 08: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:51 AM.

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