samples/07_advanced_rendering/03_render_target_viewports/app/main.rb
# Shows output of different kinds of labels on the screen
Shows output of different kinds of labels on the screen
Shows output of different kinds of labels on the screen
def labels_tech_demo
    outputs.labels << [grid.left.shift_right(5), grid.top.shift_down(5), "This is a label located at the top left."]
    outputs.labels << [grid.left.shift_right(5), grid.bottom.shift_up(30), "This is a label located at the bottom left."]
    outputs.labels << [ 5, 690, "Labels (x, y, text, size, align, r, g, b, a)"]
    outputs.labels << [ 5, 660, "Smaller label.",  -2]
    outputs.labels << [ 5, 630, "Small label.",    -1]
    outputs.labels << [ 5, 600, "Medium label.",    0]
    outputs.labels << [ 5, 570, "Large label.",     1]
    outputs.labels << [ 5, 540, "Larger label.",    2]
    outputs.labels << [300, 660, "Left aligned.",    0, 2]
    outputs.labels << [300, 640, "Center aligned.",  0, 1]
    outputs.labels << [300, 620, "Right aligned.",   0, 0]
    outputs.labels << [175, 595, "Red Label.",       0, 0, 255,   0,   0]
    outputs.labels << [175, 575, "Green Label.",     0, 0,   0, 255,   0]
    outputs.labels << [175, 555, "Blue Label.",      0, 0,   0,   0, 255]
    outputs.labels << [175, 535, "Faded Label.",     0, 0,   0,   0,   0, 128]
  end
def labels_tech_demo outputs . labels << [ grid . left . shift_right ( 5 ) , grid . top . shift_down ( 5 ) , "This is a label located at the top left." ] outputs . labels << [ grid . left . shift_right ( 5 ) , grid . bottom . shift_up ( 30 ) , "This is a label located at the bottom left." ] outputs . labels << [ 5 , 690 , "Labels (x, y, text, size, align, r, g, b, a)" ] outputs . labels << [ 5 , 660 , "Smaller label." , - 2 ] outputs . labels << [ 5 , 630 , "Small label." , - 1 ] outputs . labels << [ 5 , 600 , "Medium label." , 0 ] outputs . labels << [ 5 , 570 , "Large label." , 1 ] outputs . labels << [ 5 , 540 , "Larger label." , 2 ] outputs . labels << [ 300 , 660 , "Left aligned." , 0 , 2 ] outputs . labels << [ 300 , 640 , "Center aligned." , 0 , 1 ] outputs . labels << [ 300 , 620 , "Right aligned." , 0 , 0 ] outputs . labels << [ 175 , 595 , "Red Label." , 0 , 0 , 255 , 0 , 0 ] outputs . labels << [ 175 , 575 , "Green Label." , 0 , 0 , 0 , 255 , 0 ] outputs . labels << [ 175 , 555 , "Blue Label." , 0 , 0 , 0 , 0 , 255 ] outputs . labels << [ 175 , 535 , "Faded Label." , 0 , 0 , 0 , 0 , 0 , 128 ] end
Shows output of different kinds of labels on the screen
Shows output of different kinds of labels on the screen