TextTexture_v6 Op

TextTexture

Generates a texture of Text using one of the font ops


<p>Render text into a texture.</p> <h3>Size parameter</h3> <p>AUTO - Texture Size will be calculated from fontsize and the amount of text. You may want to use another op to add linebreaks to the text.</p> <p>MANUAL - texture height will be calculated automatically. Line breaks will be added when text overflows the given width in pixels.</p> <h3>Padding</h3> <p>Padding will add Pixels to the left,right,up and bottom sides of the texture. This will be added on top of the size parameter settings.</p>


Full Name
  • Ops.Gl.Textures.TextTexture_v6
Visibility
  • Core Op - Official cables op
License
  • MIT
AuthorgithubTest Patches


INPUT PORTS


Render (Trigger)

<p>trigger input</p>

text (String)

<p>text to be put in the texture</p>

Rendering

Draw Mesh (Number:

<i>boolean</i>

)

<p>check if rectangle with the texture should be drawn</p>

Scale Mesh (Number)

<p>size of the mesh</p>

Size index (Number:

<i>integer</i>

)
 Auto  Manual 
Width (Number:

<i>integer</i>

)

Height (Number:

<i>integer</i>

)

Auto Height (Number:

<i>boolean</i>

)

Auto Line Breaks (Number:

<i>boolean</i>

)

Font

font (String)

<p>the font to be used</p>

weight (String)
fontSize (Number)

<p>font size</p>

align index (Number:

<i>integer</i>

)
 left  center  right 
Vertical align index (Number:

<i>integer</i>

)
 Top  Middle  Bottom 
Letter Spacing (Number)
Line Height Add (Number)
Padding Y Top (Number:

<i>integer</i>

)

Padding Y Bottom (Number:

<i>integer</i>

)

Padding X (Number:

<i>integer</i>

)

Texture

filter index (Number:

<i>integer</i>

)
 nearest  linear  mipmap 
Wrap index (Number:

<i>integer</i>

)

Anisotropic index (Number:

<i>integer</i>

)
 0  1  2  4  8  16 
Reuse Texture (Number:

<i>boolean</i>

)

<p>check if texture should be reused</p>

Show Debug (Number:

<i>boolean</i>

)

<p>show outlines for debugging</p>

Redraw On Font Load (Number:

<i>boolean</i>

)

Text Color

r (Number)

<p>r color of text</p>

g (Number)

<p>g color of text</p>

b (Number)

<p>b color of text</p>

Opacity (Number)

<p>alpha value of texture</p>

Background

background R (Number)
background G (Number)
background B (Number)
background A (Number)
Force Redraw (Trigger)

OUTPUT PORTS


Next (Trigger)

<p>trigger output</p>

Ratio (Number)

<p>width / height ratio of texture</p>

texture (Object)

<p>texture output</p>

Canvas (Object)
Aspect (Number)

<p>aspect ratio of texture canvas</p>

Num Lines (Number)

<p>amount of lines in text</p>


Patches using TextTexture_v6

  • Examples
  • Public
  • My Patches

Changelog


cloned op from Ops.Gl.Textures.TextTexture_v4user avatarpandur - 2023-05-17 19:19
featureforce redraw when a font was loaded, to make sure we are using the correct fontuser avatarpandur - 2024-01-11 13:58
cloned op from Ops.Gl.Textures.TextTexture_v5user avatarpandur - 2024-01-15 15:21
bugfixmany small fixed with alignment, padding and text sizeuser avatarpandur - 2024-01-15 18:41
featureadded fixes for positioning with different paddings, alignments, negative lineheight add etc.user avatarpandur - 2024-01-22 17:56
bugfixFix bug with text not rendered on first frameuser avatarpandur - 2024-05-23 12:54