Text absent from canvas

Hi to all,

Whenever I parent text from a text node onto a canvas, upon manipulating the scale of the window, the text within the canvas at times either:

  • Begins to flicker rapidly

  • Disappears completely.

I am using panda3d version 1.10.0. Here are screenshots demonstrating what I mean:



The canvases in question are the small light grey rectangles that have numbers within them.

Here is the code I use to parent a textnodepath to a canvas:

     self.myframe5 = DirectScrolledFrame(canvasSize = (0,1.0,0,0.06), frameSize = (-.25,.25,0,0.08),scrollBarWidth=0.01) 

     np2=self.myframe5o.getCanvas()
     self.text5o = TextNode('node name5o')
     self.text5o.setText(str(self.max_snsi))
     self.text5o.setTextColor(0,0,0,1)
     self.textNodePath5o = np2.attachNewNode(self.text5o)
     self.textNodePath5o.setScale(0.05)
     #self.textNodePath5o.reparentTo(np2)  
     self.textNodePath5o.setPos(0,0,0)

Any help is appreciated.

I suppose using display regions instead of DirectScrolledFrame would get rid of this problem, as re-sizing the window doesn’t affect the text within the display region, like it appears to affect the text within the canvas.

Hmm, I wonder if it is a z-fighting issue? If so, try changing the Y parameter in setPos of the textnode to see if moving it into or out of the screen has an effect.

Or try setDepthOffset(1) on the text.

Neither manipulating the Y parameter, nor trying setDepthOffset(1) on the text has any effect, and the problem persists.