Class (GI Class)

Clutter-18ClutterPaintNodeAbstract

Paint objects

Clutter.PaintNode is an element in the render graph.

The render graph contains all the elements that need to be painted by Clutter when submitting a frame to the graphics system.

The render graph is distinct from the scene graph: the scene graph is composed by actors, which can be visible or invisible; the scene graph elements also respond to events. The render graph, instead, is only composed by nodes that will be painted.

Each Clutter.Actor can submit multiple Clutter.PaintNodes to the render graph.

Hierarchy (View Summary)

Index

Constructors

Properties

Methods

  • Adds a rectangle region to the node, with multitexture coordinates.

    Parameters

    • rect: ActorBox
    • text_coords: number

      array of multitexture values

    • text_coords_len: number

      number of items of text_coords

    Returns void

  • Adds a series of rectangles to node.

    As a general rule for better performance its recommended to use this API instead of calling clutter_paint_node_add_rectangle() separately for multiple rectangles if all of the rectangles will be drawn together.

    See cogl_framebuffer_draw_rectangles().

    Parameters

    • coords: number[]

      array of coordinates containing groups of 4 float values: [x_1, y_1, x_2, y_2] that are interpreted as two position coordinates; one for the top left of the rectangle (x1, y1), and one for the bottom right of the rectangle (x2, y2).

    Returns void

  • Adds a rectangle region to the node, with texture coordinates.

    Parameters

    • rect: ActorBox
    • x_1: number

      the left X coordinate of the texture

    • y_1: number

      the top Y coordinate of the texture

    • x_2: number

      the right X coordinate of the texture

    • y_2: number

      the bottom Y coordinate of the texture

    Returns void

  • Adds a series of rectangles to node.

    The given texture coordinates should always be normalized such that (0, 0) corresponds to the top left and (1, 1) corresponds to the bottom right. To map an entire texture across the rectangle pass in s_1=0, t_1=0, s_2=1, t_2=1.

    See cogl_framebuffer_draw_textured_rectangles().

    Parameters

    • coords: number[]

      array containing groups of 8 float values: [x_1, y_1, x_2, y_2, s_1, t_1, s_2, t_2] that have the same meaning as the arguments for cogl_framebuffer_draw_textured_rectangle().

    Returns void

  • Sets a user-readable name for node.

    The name will be used for debugging purposes.

    The node will intern name using g_intern_string(). If you have access to a static string, use clutter_paint_node_set_static_name() instead.

    Parameters

    • name: string

      a string annotating the node

    Returns void

Interfaces

SignalSignatures