docs/reference/gsk/0000775000175000017500000000000013766440701014370 5ustar mclasenmclasendocs/reference/gsk/version.xml0000664000175000017500000000000613766440532016575 0ustar mclasenmclasen4.0.0 docs/reference/gsk/gsk4-docs.xml0000664000175000017500000000233713766440673016725 0ustar mclasenmclasen ]> GSK 4 Reference Manual This document is for the GSK 4 library, version &version; The latest versions can be found online at https://developer.gnome.org/gsk4/. API Reference Index of all symbols docs/reference/gsk/gsk4-sections.txt0000664000175000017500000002172613766440673017646 0ustar mclasenmclasen
GskRenderer GskRenderer gsk_renderer_get_surface gsk_renderer_realize gsk_renderer_unrealize gsk_renderer_is_realized gsk_renderer_render gsk_renderer_render_texture gsk_renderer_new_for_surface gsk_gl_renderer_new gsk_cairo_renderer_new gsk_vulkan_renderer_new gsk_broadway_renderer_new GSK_IS_RENDERER GSK_RENDERER GSK_TYPE_RENDERER GskRendererClass gsk_renderer_get_type GSK_TYPE_SCALING_FILTER GSK_BROADWAY_RENDERER GSK_BROADWAY_RENDERER_CLASS GSK_BROADWAY_RENDERER_GET_CLASS GSK_IS_BROADWAY_RENDERER GSK_IS_BROADWAY_RENDERER_CLASS GSK_TYPE_BROADWAY_RENDERER GskBroadwayRenderer GskBroadwayRendererClass GSK_CAIRO_RENDERER GSK_CAIRO_RENDERER_CLASS GSK_CAIRO_RENDERER_GET_CLASS GSK_IS_CAIRO_RENDERER GSK_IS_CAIRO_RENDERER_CLASS GSK_TYPE_CAIRO_RENDERER GskCairoRenderer GskCairoRendererClass GSK_GL_RENDERER GSK_GL_RENDERER_CLASS GSK_GL_RENDERER_GET_CLASS GSK_IS_GL_RENDERER GSK_IS_GL_RENDERER_CLASS GSK_TYPE_GL_RENDERER GskGLRenderer GskGLRendererClass gsk_gl_renderer_get_type GSK_VULKAN_RENDERER GSK_VULKAN_RENDERER_CLASS GSK_VULKAN_RENDERER_GET_CLASS GSK_IS_VULKAN_RENDERER GSK_IS_VULKAN_RENDERER_CLASS GSK_TYPE_VULKAN_RENDERER GskVulkanRenderer GskVulkanRendererClass gsk_vulkan_renderer_get_type
GskRenderNode GskRenderNode GskBlendNode GskBlurNode GskBorderNode GskCairoNode GskClipNode GskColorMatrixNode GskColorNode GskConicGradientNode GskContainerNode GskCrossFadeNode GskDebugNode GskInsetShadowNode GskLinearGradientNode GskRadialGradientNode GskOpacityNode GskOutsetShadowNode GskRepeatingLinearGradientNode GskRepeatingRadialGradientNode GskRepeatNode GskRoundedClipNode GskShadowNode GskTextNode GskTextureNode GskTransformNode GskGLShaderNode gsk_render_node_ref gsk_render_node_unref GskRenderNodeType gsk_render_node_get_node_type gsk_render_node_draw GskSerializationError GskParseErrorFunc GskParseLocation gsk_render_node_serialize gsk_render_node_deserialize gsk_render_node_write_to_file GskScalingFilter gsk_render_node_get_bounds gsk_color_node_new gsk_color_node_get_color gsk_texture_node_new gsk_texture_node_get_texture GskColorStop gsk_linear_gradient_node_new gsk_linear_gradient_node_get_start gsk_linear_gradient_node_get_end gsk_linear_gradient_node_get_n_color_stops gsk_linear_gradient_node_get_color_stops gsk_repeating_linear_gradient_node_new gsk_radial_gradient_node_new gsk_radial_gradient_node_get_n_color_stops gsk_radial_gradient_node_get_color_stops gsk_radial_gradient_node_get_start gsk_radial_gradient_node_get_end gsk_radial_gradient_node_get_hradius gsk_radial_gradient_node_get_vradius gsk_radial_gradient_node_get_center gsk_repeating_radial_gradient_node_new gsk_conic_gradient_node_new gsk_conic_gradient_node_get_n_color_stops gsk_conic_gradient_node_get_color_stops gsk_conic_gradient_node_get_center gsk_conic_gradient_node_get_rotation gsk_border_node_new gsk_border_node_get_outline gsk_border_node_get_widths gsk_border_node_get_colors gsk_inset_shadow_node_new gsk_inset_shadow_node_get_outline gsk_inset_shadow_node_get_color gsk_inset_shadow_node_get_dx gsk_inset_shadow_node_get_dy gsk_inset_shadow_node_get_spread gsk_inset_shadow_node_get_blur_radius gsk_outset_shadow_node_new gsk_outset_shadow_node_get_outline gsk_outset_shadow_node_get_color gsk_outset_shadow_node_get_dx gsk_outset_shadow_node_get_dy gsk_outset_shadow_node_get_spread gsk_outset_shadow_node_get_blur_radius gsk_cairo_node_new gsk_cairo_node_get_draw_context gsk_cairo_node_get_surface gsk_container_node_new gsk_container_node_get_n_children gsk_container_node_get_child gsk_transform_node_new gsk_transform_node_get_child gsk_transform_node_get_transform gsk_opacity_node_new gsk_opacity_node_get_child gsk_opacity_node_get_opacity gsk_color_matrix_node_new gsk_color_matrix_node_get_child gsk_color_matrix_node_get_color_matrix gsk_color_matrix_node_get_color_offset gsk_repeat_node_new gsk_repeat_node_get_child gsk_repeat_node_get_child_bounds gsk_clip_node_new gsk_clip_node_get_child gsk_clip_node_get_clip gsk_rounded_clip_node_new gsk_rounded_clip_node_get_child gsk_rounded_clip_node_get_clip GskShadow gsk_shadow_node_new gsk_shadow_node_get_shadow gsk_shadow_node_get_n_shadows gsk_shadow_node_get_child GskBlendMode gsk_blend_node_new gsk_blend_node_get_bottom_child gsk_blend_node_get_top_child gsk_blend_node_get_blend_mode gsk_cross_fade_node_new gsk_cross_fade_node_get_start_child gsk_cross_fade_node_get_end_child gsk_cross_fade_node_get_progress gsk_text_node_new gsk_text_node_get_font gsk_text_node_get_glyphs gsk_text_node_get_color gsk_text_node_has_color_glyphs gsk_text_node_get_num_glyphs gsk_text_node_get_offset gsk_blur_node_new gsk_blur_node_get_child gsk_blur_node_get_radius gsk_debug_node_new gsk_debug_node_get_child gsk_debug_node_get_message gsk_gl_shader_node_new gsk_gl_shader_node_get_n_children gsk_gl_shader_node_get_child gsk_gl_shader_node_get_args gsk_gl_shader_node_get_shader GSK_IS_RENDER_NODE GSK_RENDER_NODE GSK_TYPE_RENDER_NODE GSK_TYPE_BLEND_NODE GSK_TYPE_BLUR_NODE GSK_TYPE_BORDER_NODE GSK_TYPE_CAIRO_NODE GSK_TYPE_CLIP_NODE GSK_TYPE_COLOR_MATRIX_NODE GSK_TYPE_COLOR_NODE GSK_TYPE_CONTAINER_NODE GSK_TYPE_CONIC_GRADIENT_NODE GSK_TYPE_CROSS_FADE_NODE GSK_TYPE_DEBUG_NODE GSK_TYPE_GL_SHADER_NODE GSK_TYPE_INSET_SHADOW_NODE GSK_TYPE_LINEAR_GRADIENT_NODE GSK_TYPE_OPACITY_NODE GSK_TYPE_OUTSET_SHADOW_NODE GSK_TYPE_RADIAL_GRADIENT_NODE GSK_TYPE_REPEATING_LINEAR_GRADIENT_NODE GSK_TYPE_REPEATING_RADIAL_GRADIENT_NODE GSK_TYPE_REPEAT_NODE GSK_TYPE_ROUNDED_CLIP_NODE GSK_TYPE_SHADOW_NODE GSK_TYPE_TEXT_NODE GSK_TYPE_TEXTURE_NODE GSK_TYPE_TRANSFORM_NODE GSK_TYPE_GLSHADER_NODE GSK_TYPE_RENDER_NODE_TYPE GskRenderNodeClass gsk_blend_node_get_type gsk_blur_node_get_type gsk_border_node_get_type gsk_broadway_renderer_get_type gsk_cairo_node_get_type gsk_cairo_renderer_get_type gsk_clip_node_get_type gsk_color_matrix_node_get_type gsk_color_node_get_type gsk_conic_gradient_node_get_type gsk_container_node_get_type gsk_cross_fade_node_get_type gsk_debug_node_get_type gsk_gl_shader_node_get_type gsk_inset_shadow_node_get_type gsk_linear_gradient_node_get_type gsk_opacity_node_get_type gsk_outset_shadow_node_get_type gsk_radial_gradient_node_get_type gsk_render_node_get_type gsk_repeating_linear_gradient_node_get_type gsk_repeating_radial_gradient_node_get_type gsk_repeat_node_get_type gsk_rounded_clip_node_get_type gsk_shadow_node_get_type gsk_text_node_get_type gsk_texture_node_get_type gsk_transform_node_get_type GSK_TYPE_BLEND_MODE gsk_serialization_error_quark GSK_SERIALIZATION_ERROR GSK_TYPE_SERIALIZATION_ERROR
GskRoundedRect GskCorner GskRoundedRect GSK_ROUNDED_RECT_INIT gsk_rounded_rect_init gsk_rounded_rect_init_copy gsk_rounded_rect_init_from_rect gsk_rounded_rect_normalize gsk_rounded_rect_offset gsk_rounded_rect_shrink gsk_rounded_rect_is_rectilinear gsk_rounded_rect_contains_point gsk_rounded_rect_contains_rect gsk_rounded_rect_intersects_rect GSK_TYPE_CORNER
GskTransform GskTransform gsk_transform_ref gsk_transform_unref GskTransformCategory gsk_transform_get_category gsk_transform_print gsk_transform_to_string gsk_transform_parse gsk_transform_to_matrix gsk_transform_to_2d gsk_transform_to_affine gsk_transform_to_translate gsk_transform_transform gsk_transform_invert gsk_transform_matrix gsk_transform_translate gsk_transform_translate_3d gsk_transform_rotate gsk_transform_rotate_3d gsk_transform_scale gsk_transform_scale_3d gsk_transform_perspective gsk_transform_equal gsk_transform_transform_bounds gsk_transform_transform_point GSK_TYPE_TRANSFORM GSK_TYPE_TRANSFORM_CATEGORY gsk_transform_get_type gsk_transform_new
GskGLShader GskGLShader gsk_gl_shader_new_from_bytes gsk_gl_shader_new_from_resource gsk_gl_shader_compile gsk_gl_shader_get_source gsk_gl_shader_get_resource gsk_gl_shader_get_n_textures gsk_gl_shader_get_n_uniforms gsk_gl_shader_get_uniform_name gsk_gl_shader_find_uniform_by_name GskGLUniformType gsk_gl_shader_get_uniform_type gsk_gl_shader_get_uniform_offset gsk_gl_shader_get_args_size gsk_gl_shader_get_arg_float gsk_gl_shader_get_arg_int gsk_gl_shader_get_arg_uint gsk_gl_shader_get_arg_bool gsk_gl_shader_get_arg_vec2 gsk_gl_shader_get_arg_vec3 gsk_gl_shader_get_arg_vec4 gsk_gl_shader_format_args_va gsk_gl_shader_format_args GskShaderArgsBuilder gsk_shader_args_builder_new gsk_shader_args_builder_to_args gsk_shader_args_builder_free_to_args gsk_shader_args_builder_unref gsk_shader_args_builder_ref gsk_shader_args_builder_set_float gsk_shader_args_builder_set_int gsk_shader_args_builder_set_uint gsk_shader_args_builder_set_bool gsk_shader_args_builder_set_vec2 gsk_shader_args_builder_set_vec3 gsk_shader_args_builder_set_vec4 GSK_TYPE_GL_SHADER GSK_TYPE_GL_UNIFORM_TYPE GSK_TYPE_SHADER_ARGS_BUILDER gsk_shader_args_builder_get_type
docs/reference/gsk/html/0000775000175000017500000000000013766440701015334 5ustar mclasenmclasendocs/reference/gsk/html/gsk4.devhelp20000664000175000017500000011074213766440701017644 0ustar mclasenmclasen docs/reference/gsk/html/up-insensitive.png0000644000175000017500000000056613766440701021031 0ustar mclasenmclasenPNG  IHDRabKGD pHYs B(xtIMEwIIDAT8?/Qϙ?[u$VHTDۈBM+![/]_i03IENDB`docs/reference/gsk/html/left-insensitive.png0000644000175000017500000000061313766440701021330 0ustar mclasenmclasenPNG  IHDRabKGD pHYs B(xtIMEƫqIDAT8͒NQ@pds`*4@W@ A!Ԇ@6^ 5hxIH R`sQp̙339B|sKEQTK@۝΁i^~Wʆ`0TJ6TcYn6A ƀ~߱>}ǭs; lYkwr 5U= /" "uU=ɲlArDzp5I4^E+P3Ɯq_p ̥iUYp=#IENDB`docs/reference/gsk/html/up.png0000644000175000017500000000040413766440701016462 0ustar mclasenmclasenPNG  IHDRabKGD pHYs B(xtIME IDAT81 @D{xa;$]r =JR1, Sd-}0̟oL:m-QO[ k TzMޠL,:ךu!tK; Pp Ot@l/̵*l}IENDB`docs/reference/gsk/html/home.png0000644000175000017500000000040013766440701016762 0ustar mclasenmclasenPNG  IHDRabKGD pHYs B(xtIME &IDAT8ҽ Aߞf`n v`6`/`Yܡ`f&k$,} 0b+ԸaQW~b O e{y N[L}.piBzmm o.I]7^[;%:VIENDB`docs/reference/gsk/html/right-insensitive.png0000644000175000017500000000056513766440701021521 0ustar mclasenmclasenPNG  IHDRabKGD pHYs B(xtIME ^IDAT8͒J` /S_$AqrW(>m"]\(49.Nd39{eM#MSIιEiHz|3{̲l3,KkV'@EEQlwyiq]Kh4:mĦ,;ts\aR5/7'Wps׭I,K1=0j0Wg> PU𻤝0 ]?qCҫιg~kA_IENDB`docs/reference/gsk/html/right.png0000644000175000017500000000040513766440701017154 0ustar mclasenmclasenPNG  IHDRabKGD pHYs B(xtIME!GIDAT8үa?MIdEr,-hAIl ry}sX6 !9#D r$-Br$G"$;WZ&!cq \`軀O=QoufIENDB`docs/reference/gsk/html/style.css0000644000175000017500000002645513766440701017220 0ustar mclasenmclasenbody { font-family: cantarell, sans-serif; } .synopsis, .classsynopsis { /* tango:aluminium 1/2 */ background: #eeeeec; background: rgba(238, 238, 236, 0.5); border: solid 1px rgb(238, 238, 236); padding: 0.5em; } .programlisting { /* tango:sky blue 0/1 */ /* fallback for no rgba support */ background: #e6f3ff; border: solid 1px #729fcf; background: rgba(114, 159, 207, 0.1); border: solid 1px rgba(114, 159, 207, 0.2); padding: 0.5em; } .variablelist { padding: 4px; margin-left: 3em; } .variablelist td:first-child { vertical-align: top; } span.nowrap { white-space: nowrap; } div.gallery-float { float: left; padding: 10px; } div.gallery-float img { border-style: none; } div.gallery-spacer { clear: both; } a, a:visited { text-decoration: none; /* tango:sky blue 2 */ color: #3465a4; } a:hover { text-decoration: underline; /* tango:sky blue 1 */ color: #729fcf; } .function_type, .variable_type, .property_type, .signal_type, .parameter_name, .struct_member_name, .union_member_name, .define_keyword, .datatype_keyword, .typedef_keyword { text-align: right; } /* dim non-primary columns */ .c_punctuation, .function_type, .variable_type, .property_type, .signal_type, .define_keyword, .datatype_keyword, .typedef_keyword, .property_flags, .signal_flags, .parameter_annotations, .enum_member_annotations, .struct_member_annotations, .union_member_annotations { color: #888a85; } .function_type a, .function_type a:visited, .function_type a:hover, .property_type a, .property_type a:visited, .property_type a:hover, .signal_type a, .signal_type a:visited, .signal_type a:hover, .signal_flags a, .signal_flags a:visited, .signal_flags a:hover { color: #729fcf; } td p { margin: 0.25em; } div.informaltable table[border="1"], div.table table { border-collapse: collapse; border-spacing: 0px; /* tango:aluminium 3 */ border: solid 1px #babdb6; } div.informaltable table[border="1"] td, div.informaltable table th, div.table table td, div.table table th { /* tango:aluminium 3 */ border: solid 1px #babdb6; padding: 3px; vertical-align: top; } div.informaltable table[border="1"] th, div.table table th { /* tango:aluminium 2 */ background-color: #d3d7cf; } h4 { color: #555753; margin-top: 1em; margin-bottom: 1em; } hr { /* tango:aluminium 1 */ color: #d3d7cf; background: #d3d7cf; border: none 0px; height: 1px; clear: both; margin: 2.0em 0em 2.0em 0em; } dl.toc dt { padding-bottom: 0.25em; } dl.toc > dt { padding-top: 0.25em; padding-bottom: 0.25em; font-weight: bold; } dl.toc > dl { padding-bottom: 0.5em; } .parameter { font-style: normal; } .footer { padding-top: 3.5em; /* tango:aluminium 3 */ color: #babdb6; text-align: center; font-size: 80%; } .informalfigure, .figure { margin: 1em; } .informalexample, .example { margin-top: 1em; margin-bottom: 1em; } .warning { /* tango:orange 0/1 */ background: #ffeed9; background: rgba(252, 175, 62, 0.1); border-color: #ffb04f; border-color: rgba(252, 175, 62, 0.2); } .note { /* tango:chameleon 0/0.5 */ background: #d8ffb2; background: rgba(138, 226, 52, 0.1); border-color: #abf562; border-color: rgba(138, 226, 52, 0.2); } div.blockquote { border-color: #eeeeec; } .note, .warning, div.blockquote { padding: 0.5em; border-width: 1px; border-style: solid; margin: 2em; } .note p, .warning p { margin: 0; } div.warning h3.title, div.note h3.title { display: none; } p + div.section { margin-top: 1em; } div.refnamediv, div.refsynopsisdiv, div.refsect1, div.refsect2, div.toc, div.section { margin-bottom: 1em; } /* blob links */ h2 .extralinks, h3 .extralinks { float: right; /* tango:aluminium 3 */ color: #babdb6; font-size: 80%; font-weight: normal; } .lineart { color: #d3d7cf; font-weight: normal; } .annotation { /* tango:aluminium 5 */ color: #555753; font-weight: normal; } .structfield { font-style: normal; font-weight: normal; } acronym,abbr { border-bottom: 1px dotted gray; } .listing_frame { /* tango:sky blue 1 */ border: solid 1px #729fcf; border: solid 1px rgba(114, 159, 207, 0.2); padding: 0px; } .listing_lines, .listing_code { margin-top: 0px; margin-bottom: 0px; padding: 0.5em; } .listing_lines { /* tango:sky blue 0.5 */ background: #a6c5e3; background: rgba(114, 159, 207, 0.2); /* tango:aluminium 6 */ color: #2e3436; } .listing_code { /* tango:sky blue 0 */ background: #e6f3ff; background: rgba(114, 159, 207, 0.1); } .listing_code .programlisting { /* override from previous */ border: none 0px; padding: 0px; background: none; } .listing_lines pre, .listing_code pre { margin: 0px; } @media screen { /* these have a as a first child, but since there are no parent selectors * we can't use that. */ a.footnote { position: relative; top: 0em ! important; } /* this is needed so that the local anchors are displayed below the naviagtion */ div.footnote a[name], div.refnamediv a[name], div.refsect1 a[name], div.refsect2 a[name], div.index a[name], div.glossary a[name], div.sect1 a[name] { display: inline-block; position: relative; top:-5em; } /* this seems to be a bug in the xsl style sheets when generating indexes */ div.index div.index { top: 0em; } /* make space for the fixed navigation bar and add space at the bottom so that * link targets appear somewhat close to top */ body { padding-top: 2.5em; padding-bottom: 500px; max-width: 60em; } p { max-width: 60em; } /* style and size the navigation bar */ table.navigation#top { position: fixed; background: #e2e2e2; border-bottom: solid 1px #babdb6; border-spacing: 5px; margin-top: 0; margin-bottom: 0; top: 0; left: 0; z-index: 10; } table.navigation#top td { padding-left: 6px; padding-right: 6px; } .navigation a, .navigation a:visited { /* tango:sky blue 3 */ color: #204a87; } .navigation a:hover { /* tango:sky blue 2 */ color: #3465a4; } td.shortcuts { /* tango:sky blue 2 */ color: #3465a4; font-size: 80%; white-space: nowrap; } td.shortcuts .dim { color: #babdb6; } .navigation .title { font-size: 80%; max-width: none; margin: 0px; font-weight: normal; } } @media screen and (min-width: 60em) { /* screen larger than 60em */ body { margin: auto; } } @media screen and (max-width: 60em) { /* screen less than 60em */ #nav_hierarchy { display: none; } #nav_interfaces { display: none; } #nav_prerequisites { display: none; } #nav_derived_interfaces { display: none; } #nav_implementations { display: none; } #nav_child_properties { display: none; } #nav_style_properties { display: none; } #nav_index { display: none; } #nav_glossary { display: none; } .gallery_image { display: none; } .property_flags { display: none; } .signal_flags { display: none; } .parameter_annotations { display: none; } .enum_member_annotations { display: none; } .struct_member_annotations { display: none; } .union_member_annotations { display: none; } /* now that a column is hidden, optimize space */ col.parameters_name { width: auto; } col.parameters_description { width: auto; } col.struct_members_name { width: auto; } col.struct_members_description { width: auto; } col.enum_members_name { width: auto; } col.enum_members_description { width: auto; } col.union_members_name { width: auto; } col.union_members_description { width: auto; } .listing_lines { display: none; } } @media print { table.navigation { visibility: collapse; display: none; } div.titlepage table.navigation { visibility: visible; display: table; background: #e2e2e2; border: solid 1px #babdb6; margin-top: 0; margin-bottom: 0; top: 0; left: 0; height: 3em; } } .hll { background-color: #ffffcc } .c { color: #408080; font-style: italic } /* Comment */ .err { border: 1px solid #FF0000 } /* Error */ .k { color: #008000; font-weight: bold } /* Keyword */ .o { color: #666666 } /* Operator */ .ch { color: #408080; font-style: italic } /* Comment.Hashbang */ .cm { color: #408080; font-style: italic } /* Comment.Multiline */ .cp { color: #BC7A00 } /* Comment.Preproc */ .cpf { color: #408080; font-style: italic } /* Comment.PreprocFile */ .c1 { color: #408080; font-style: italic } /* Comment.Single */ .cs { color: #408080; font-style: italic } /* Comment.Special */ .gd { color: #A00000 } /* Generic.Deleted */ .ge { font-style: italic } /* Generic.Emph */ .gr { color: #FF0000 } /* Generic.Error */ .gh { color: #000080; font-weight: bold } /* Generic.Heading */ .gi { color: #00A000 } /* Generic.Inserted */ .go { color: #888888 } /* Generic.Output */ .gp { color: #000080; font-weight: bold } /* Generic.Prompt */ .gs { font-weight: bold } /* Generic.Strong */ .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ .gt { color: #0044DD } /* Generic.Traceback */ .kc { color: #008000; font-weight: bold } /* Keyword.Constant */ .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */ .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */ .kp { color: #008000 } /* Keyword.Pseudo */ .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */ .kt { color: #B00040 } /* Keyword.Type */ .m { color: #666666 } /* Literal.Number */ .s { color: #BA2121 } /* Literal.String */ .na { color: #7D9029 } /* Name.Attribute */ .nb { color: #008000 } /* Name.Builtin */ .nc { color: #0000FF; font-weight: bold } /* Name.Class */ .no { color: #880000 } /* Name.Constant */ .nd { color: #AA22FF } /* Name.Decorator */ .ni { color: #999999; font-weight: bold } /* Name.Entity */ .ne { color: #D2413A; font-weight: bold } /* Name.Exception */ .nf { color: #0000FF } /* Name.Function */ .nl { color: #A0A000 } /* Name.Label */ .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */ .nt { color: #008000; font-weight: bold } /* Name.Tag */ .nv { color: #19177C } /* Name.Variable */ .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */ .w { color: #bbbbbb } /* Text.Whitespace */ .mb { color: #666666 } /* Literal.Number.Bin */ .mf { color: #666666 } /* Literal.Number.Float */ .mh { color: #666666 } /* Literal.Number.Hex */ .mi { color: #666666 } /* Literal.Number.Integer */ .mo { color: #666666 } /* Literal.Number.Oct */ .sa { color: #BA2121 } /* Literal.String.Affix */ .sb { color: #BA2121 } /* Literal.String.Backtick */ .sc { color: #BA2121 } /* Literal.String.Char */ .dl { color: #BA2121 } /* Literal.String.Delimiter */ .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */ .s2 { color: #BA2121 } /* Literal.String.Double */ .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */ .sh { color: #BA2121 } /* Literal.String.Heredoc */ .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */ .sx { color: #008000 } /* Literal.String.Other */ .sr { color: #BB6688 } /* Literal.String.Regex */ .s1 { color: #BA2121 } /* Literal.String.Single */ .ss { color: #19177C } /* Literal.String.Symbol */ .bp { color: #008000 } /* Name.Builtin.Pseudo */ .fm { color: #0000FF } /* Name.Function.Magic */ .vc { color: #19177C } /* Name.Variable.Class */ .vg { color: #19177C } /* Name.Variable.Global */ .vi { color: #19177C } /* Name.Variable.Instance */ .vm { color: #19177C } /* Name.Variable.Magic */ .il { color: #666666 } /* Literal.Number.Integer.Long */docs/reference/gsk/html/GskGLShader.html0000664000175000017500000025266013766440701020333 0ustar mclasenmclasen GskGLShader: GSK 4 Reference Manual

GskGLShader

GskGLShader — Fragment shaders for GSK

Properties

char * resource Read / Write / Construct Only
GBytes * source Read / Write / Construct Only

Types and Values

Object Hierarchy

    GObject
    ╰── GskGLShader

Description

A GskGLShader is a snippet of GLSL that is meant to run in the fragment shader of the rendering pipeline. A fragment shader gets the coordinates being rendered as input and produces the pixel values for that particular pixel. Additionally, the shader can declare a set of other input arguments, called uniforms (as they are uniform over all the calls to your shader in each instance of use). A shader can also receive up to 4 textures that it can use as input when producing the pixel data.

GskGLShader is usually used with gtk_snapshot_push_gl_shader() to produce a GskGLShaderNode in the rendering hierarchy, and then its input textures are constructed by rendering the child nodes to textures before rendering the shader node itself. (You can pass texture nodes as children if you want to directly use a texture as input).

The actual shader code is GLSL code that gets combined with some other code into the fragment shader. Since the exact capabilities of the GPU driver differs between different OpenGL drivers and hardware, GTK adds some defines that you can use to ensure your GLSL code runs on as many drivers as it can.

If the OpenGL driver is GLES, then the shader language version is set to 100, and GSK_GLES will be defined in the shader.

Otherwise, if the OpenGL driver does not support the 3.2 core profile, then the shader will run with language version 110 for GL2 and 130 for GL3, and GSK_LEGACY will be defined in the shader.

If the OpenGL driver supports the 3.2 code profile, it will be used, the shader language version is set to 150, and GSK_GL3 will be defined in the shader.

The main function the shader must implement is:

1
2
3
4
void mainImage(out vec4 fragColor,
               in vec2 fragCoord,
               in vec2 resolution,
               in vec2 uv)

Where the input fragCoord is the coordinate of the pixel we're currently rendering, relative to the boundary rectangle that was specified in the GskGLShaderNode, and resolution is the width and height of that rectangle. This is in the typical GTK coordinate system with the origin in the top left. uv contains the u and v coordinates that can be used to index a texture at the corresponding point. These coordinates are in the [0..1]x[0..1] region, with 0, 0 being in the lower left corder (which is typical for OpenGL).

The output fragColor should be a RGBA color (with premultiplied alpha) that will be used as the output for the specified pixel location. Note that this output will be automatically clipped to the clip region of the glshader node.

In addition to the function arguments the shader can define up to 4 uniforms for textures which must be called u_textureN (i.e. u_texture1 to u_texture4) as well as any custom uniforms you want of types int, uint, bool, float, vec2, vec3 or vec4.

All textures sources contain premultiplied alpha colors, but if some there are outer sources of colors there is a gsk_premultiply() helper to compute premultiplication when needed.

Note that GTK parses the uniform declarations, so each uniform has to be on a line by itself with no other code, like so:

1
2
3
4
uniform float u_time;
uniform vec3 u_color;
uniform sampler2D u_texture1;
uniform sampler2D u_texture2;

GTK uses the the "gsk" namespace in the symbols it uses in the shader, so your code should not use any symbols with the prefix gsk or GSK. There are some helper functions declared that you can use:

1
vec4 GskTexture(sampler2D sampler, vec2 texCoords);

This samples a texture (e.g. u_texture1) at the specified coordinates, and containes some helper ifdefs to ensure that it works on all OpenGL versions.

You can compile the shader yourself using gsk_gl_shader_compile(), otherwise the GSK renderer will do it when it handling the glshader node. If errors occurs, the returned error will include the glsl sources, so you can see what GSK was passing to the compiler. You can also set GSK_DEBUG=shaders in the environment to see the sources and other relevant information about all shaders that GSK is handling.

An example shader

1
2
3
4
5
6
7
8
9
10
11
12
13
uniform float position;
uniform sampler2D u_texture1;
uniform sampler2D u_texture2;

void mainImage(out vec4 fragColor,
               in vec2 fragCoord,
               in vec2 resolution,
               in vec2 uv) {
  vec4 source1 = GskTexture(u_texture1, uv);
  vec4 source2 = GskTexture(u_texture2, uv);

  fragColor = position * source1 + (1.0 - position) * source2;
}

Functions

gsk_gl_shader_new_from_bytes ()

GskGLShader *
gsk_gl_shader_new_from_bytes (GBytes *sourcecode);

Creates a GskGLShader that will render pixels using the specified code.

Parameters

sourcecode

GLSL sourcecode for the shader, as a GBytes

 

Returns

A new GskGLShader.

[transfer full]


gsk_gl_shader_new_from_resource ()

GskGLShader *
gsk_gl_shader_new_from_resource (const char *resource_path);

Creates a GskGLShader that will render pixels using the specified code.

Parameters

resource_path

path to a resource that contains the GLSL sourcecode for the shader

 

Returns

A new GskGLShader.

[transfer full]


gsk_gl_shader_compile ()

gboolean
gsk_gl_shader_compile (GskGLShader *shader,
                       GskRenderer *renderer,
                       GError **error);

Tries to compile the shader for the given renderer , and reports FALSE with an error if there is a problem. You should use this function before relying on the shader for rendering and use a fallback with a simpler shader or without shaders if it fails.

Note that this will modify the rendering state (for example change the current GL context) and requires the renderer to be set up. This means that the widget has to be realized. Commonly you want to call this from the realize signal of a widget, or during widget snapshot.

Parameters

shader

a GskGLShader

 

renderer

a GskRenderer

 

error

location to store error in

 

Returns

TRUE on success, FALSE if an error occurred


gsk_gl_shader_get_source ()

GBytes *
gsk_gl_shader_get_source (GskGLShader *shader);

Gets the GLSL sourcecode being used to render this shader.

Parameters

shader

a GskGLShader

 

Returns

The source code for the shader.

[transfer none]


gsk_gl_shader_get_resource ()

const char *
gsk_gl_shader_get_resource (GskGLShader *shader);

Gets the resource path for the GLSL sourcecode being used to render this shader.

Parameters

shader

a GskGLShader

 

Returns

The resource path for the shader, or NULL if none.

[transfer none]


gsk_gl_shader_get_n_textures ()

int
gsk_gl_shader_get_n_textures (GskGLShader *shader);

Returns the number of textures that the shader requires.

This can be used to check that the a passed shader works in your usecase. It is determined by looking at the highest u_textureN value that the shader defines.

Parameters

shader

a GskGLShader

 

Returns

The number of texture inputs required by shader


gsk_gl_shader_get_n_uniforms ()

int
gsk_gl_shader_get_n_uniforms (GskGLShader *shader);

Get the number of declared uniforms for this shader.

Parameters

shader

a GskGLShader

 

Returns

The number of declared uniforms


gsk_gl_shader_get_uniform_name ()

const char *
gsk_gl_shader_get_uniform_name (GskGLShader *shader,
                                int idx);

Get the name of the declared uniform for this shader at index idx .

Parameters

shader

a GskGLShader

 

idx

index of the uniform

 

Returns

The name of the declared uniform.

[transfer none]


gsk_gl_shader_find_uniform_by_name ()

int
gsk_gl_shader_find_uniform_by_name (GskGLShader *shader,
                                    const char *name);

Looks for a uniform by the name name , and returns the index of the uniform, or -1 if it was not found.

Parameters

shader

a GskGLShader

 

name

uniform name

 

Returns

The index of the uniform, or -1


gsk_gl_shader_get_uniform_type ()

GskGLUniformType
gsk_gl_shader_get_uniform_type (GskGLShader *shader,
                                int idx);

Get the type of the declared uniform for this shader at index idx .

Parameters

shader

a GskGLShader

 

idx

index of the uniform

 

Returns

The type of the declared uniform


gsk_gl_shader_get_uniform_offset ()

int
gsk_gl_shader_get_uniform_offset (GskGLShader *shader,
                                  int idx);

Get the offset into the data block where data for this uniforms is stored.

Parameters

shader

a GskGLShader

 

idx

index of the uniform

 

Returns

The data offset


gsk_gl_shader_get_args_size ()

gsize
gsk_gl_shader_get_args_size (GskGLShader *shader);

Get the size of the data block used to specify arguments for this shader.

Parameters

shader

a GskGLShader

 

Returns

The size of the data block


gsk_gl_shader_get_arg_float ()

float
gsk_gl_shader_get_arg_float (GskGLShader *shader,
                             GBytes *args,
                             int idx);

Gets the value of the uniform idx in the args block. The uniform must be of float type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

Returns

The value


gsk_gl_shader_get_arg_int ()

gint32
gsk_gl_shader_get_arg_int (GskGLShader *shader,
                           GBytes *args,
                           int idx);

Gets the value of the uniform idx in the args block. The uniform must be of int type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

Returns

The value


gsk_gl_shader_get_arg_uint ()

guint32
gsk_gl_shader_get_arg_uint (GskGLShader *shader,
                            GBytes *args,
                            int idx);

Gets the value of the uniform idx in the args block. The uniform must be of uint type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

Returns

The value


gsk_gl_shader_get_arg_bool ()

gboolean
gsk_gl_shader_get_arg_bool (GskGLShader *shader,
                            GBytes *args,
                            int idx);

Gets the value of the uniform idx in the args block. The uniform must be of bool type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

Returns

The value


gsk_gl_shader_get_arg_vec2 ()

void
gsk_gl_shader_get_arg_vec2 (GskGLShader *shader,
                            GBytes *args,
                            int idx,
                            graphene_vec2_t *out_value);

Gets the value of the uniform idx in the args block. The uniform must be of vec2 type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

out_value

location to store the uniform value in

 

gsk_gl_shader_get_arg_vec3 ()

void
gsk_gl_shader_get_arg_vec3 (GskGLShader *shader,
                            GBytes *args,
                            int idx,
                            graphene_vec3_t *out_value);

Gets the value of the uniform idx in the args block. The uniform must be of vec3 type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

out_value

location to store the uniform value in

 

gsk_gl_shader_get_arg_vec4 ()

void
gsk_gl_shader_get_arg_vec4 (GskGLShader *shader,
                            GBytes *args,
                            int idx,
                            graphene_vec4_t *out_value);

Gets the value of the uniform idx in the args block. The uniform must be of vec4 type.

Parameters

shader

a GskGLShader

 

args

uniform arguments

 

idx

index of the uniform

 

out_value

location to store set the uniform value in

 

gsk_gl_shader_format_args_va ()

GBytes *
gsk_gl_shader_format_args_va (GskGLShader *shader,
                              va_list uniforms);

Formats the uniform data as needed for feeding the named uniforms values into the shader. The argument list is a list of pairs of names, and values for the types that match the declared uniforms (i.e. double/int/guint/gboolean for primitive values and graphene_vecN_t * for vecN uniforms).

It is an error to pass a uniform name that is not declared by the shader.

Any uniforms of the shader that are not included in the argument list are zero-initialized.

Parameters

shader

a GskGLShader

 

uniforms

name-Value pairs for the uniforms of shader , ending with a NULL name

 

Returns

A newly allocated block of data which can be passed to gsk_gl_shader_node_new().

[transfer full]


gsk_gl_shader_format_args ()

GBytes *
gsk_gl_shader_format_args (GskGLShader *shader,
                           ...);

Formats the uniform data as needed for feeding the named uniforms values into the shader. The argument list is a list of pairs of names, and values for the types that match the declared uniforms (i.e. double/int/guint/gboolean for primitive values and graphene_vecN_t * for vecN uniforms).

Any uniforms of the shader that are not included in the argument list are zero-initialized.

Parameters

shader

a GskGLShader

 

...

name-Value pairs for the uniforms of shader , ending with a NULL name

 

Returns

A newly allocated block of data which can be passed to gsk_gl_shader_node_new().

[transfer full]


gsk_shader_args_builder_new ()

GskShaderArgsBuilder *
gsk_shader_args_builder_new (GskGLShader *shader,
                             GBytes *initial_values);

Allocates a builder that can be used to construct a new uniform data chunk.

Parameters

shader

a GskGLShader

 

initial_values

optional Bytes with initial values.

[nullable]

Returns

The newly allocated builder, free with gsk_shader_args_builder_unref().

[transfer full]


gsk_shader_args_builder_to_args ()

GBytes *
gsk_shader_args_builder_to_args (GskShaderArgsBuilder *builder);

Creates a new GBytes args from the current state of the given builder . Any uniforms of the shader that have not been explicitly set on the builder are zero-initialized.

The given GskShaderArgsBuilder is reset once this function returns; you cannot call this function multiple times on the same builder instance.

This function is intended primarily for bindings. C code should use gsk_shader_args_builder_free_to_args().

Parameters

builder

a GskShaderArgsBuilder

 

Returns

the newly allocated builder, free with gsk_shader_args_builder_free().

[transfer full]


gsk_shader_args_builder_free_to_args ()

GBytes *
gsk_shader_args_builder_free_to_args (GskShaderArgsBuilder *builder);

Creates a new GBytes args from the current state of the given builder , and frees the builder instance. Any uniforms of the shader that have not been explicitly set on the builder are zero-initialized.

[skip]

Parameters

builder

a GskShaderArgsBuilder

 

Returns

the newly created GBytes with all the args added to builder .

[transfer full]


gsk_shader_args_builder_unref ()

void
gsk_shader_args_builder_unref (GskShaderArgsBuilder *builder);

Decreases the reference count of a GskShaderArgBuilder by one. If the resulting reference count is zero, frees the builder.

Parameters

builder

a GskShaderArgsBuilder

 

gsk_shader_args_builder_ref ()

GskShaderArgsBuilder *
gsk_shader_args_builder_ref (GskShaderArgsBuilder *builder);

Increases the reference count of a GskShaderArgsBuilder by one.

Parameters

builder

a GskShaderArgsBuilder

 

Returns

the passed in GskShaderArgsBuilder


gsk_shader_args_builder_set_float ()

void
gsk_shader_args_builder_set_float (GskShaderArgsBuilder *builder,
                                   int idx,
                                   float value);

Sets the value of the uniform idx . The uniform must be of float type.

Parameters

builder

a GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform to

 

gsk_shader_args_builder_set_int ()

void
gsk_shader_args_builder_set_int (GskShaderArgsBuilder *builder,
                                 int idx,
                                 gint32 value);

Sets the value of the uniform idx . The uniform must be of int type.

Parameters

builder

a GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform to

 

gsk_shader_args_builder_set_uint ()

void
gsk_shader_args_builder_set_uint (GskShaderArgsBuilder *builder,
                                  int idx,
                                  guint32 value);

Sets the value of the uniform idx . The uniform must be of uint type.

Parameters

builder

a GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform to

 

gsk_shader_args_builder_set_bool ()

void
gsk_shader_args_builder_set_bool (GskShaderArgsBuilder *builder,
                                  int idx,
                                  gboolean value);

Sets the value of the uniform idx . The uniform must be of bool type.

Parameters

builder

a GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform to

 

gsk_shader_args_builder_set_vec2 ()

void
gsk_shader_args_builder_set_vec2 (GskShaderArgsBuilder *builder,
                                  int idx,
                                  const graphene_vec2_t *value);

Sets the value of the uniform idx . The uniform must be of vec2 type.

Parameters

builder

A GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform too

 

gsk_shader_args_builder_set_vec3 ()

void
gsk_shader_args_builder_set_vec3 (GskShaderArgsBuilder *builder,
                                  int idx,
                                  const graphene_vec3_t *value);

Sets the value of the uniform idx . The uniform must be of vec3 type.

Parameters

builder

a GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform too

 

gsk_shader_args_builder_set_vec4 ()

void
gsk_shader_args_builder_set_vec4 (GskShaderArgsBuilder *builder,
                                  int idx,
                                  const graphene_vec4_t *value);

Sets the value of the uniform idx . The uniform must be of vec4 type.

Parameters

builder

a GskShaderArgsBuilder

 

idx

index of the uniform

 

value

value to set the uniform too

 

Types and Values

GskGLShader

typedef struct _GskGLShader GskGLShader;

An object representing a GL shader program.


enum GskGLUniformType

This defines the types of the uniforms that GskGLShaders declare. It defines both what the type is called in the GLSL shader code, and what the corresponding C type is on the Gtk side.

Members

GSK_GL_UNIFORM_TYPE_NONE

No type, used for uninitialized or unspecified values.

 

GSK_GL_UNIFORM_TYPE_FLOAT

A float uniform

 

GSK_GL_UNIFORM_TYPE_INT

A GLSL int / gint32 uniform

 

GSK_GL_UNIFORM_TYPE_UINT

A GLSL uint / guint32 uniform

 

GSK_GL_UNIFORM_TYPE_BOOL

A GLSL bool / gboolean uniform

 

GSK_GL_UNIFORM_TYPE_VEC2

A GLSL vec2 / graphene_vec2_t uniform

 

GSK_GL_UNIFORM_TYPE_VEC3

A GLSL vec3 / graphene_vec3_t uniform

 

GSK_GL_UNIFORM_TYPE_VEC4

A GLSL vec4 / graphene_vec4_t uniform

 

GskShaderArgsBuilder

typedef struct _GskShaderArgsBuilder GskShaderArgsBuilder;

An object to build the uniforms data for a GskGLShader.

Property Details

The “resource” property

  “resource”                 char *

Resource containing the source code for the shader.

If the shader source is not coming from a resource, this will be NULL.

Owner: GskGLShader

Flags: Read / Write / Construct Only

Default value: NULL


The “source” property

  “source”                   GBytes *

The sourcecode for the shader.

Owner: GskGLShader

Flags: Read / Write / Construct Only

docs/reference/gsk/html/GskRenderNode.html0000664000175000017500000104666013766440701020731 0ustar mclasenmclasen GskRenderNode: GSK 4 Reference Manual

GskRenderNode

GskRenderNode — Simple scene graph element

Functions

GskRenderNode * gsk_render_node_ref ()
void gsk_render_node_unref ()
GskRenderNodeType gsk_render_node_get_node_type ()
void gsk_render_node_draw ()
void (*GskParseErrorFunc) ()
GBytes * gsk_render_node_serialize ()
GskRenderNode * gsk_render_node_deserialize ()
gboolean gsk_render_node_write_to_file ()
void gsk_render_node_get_bounds ()
GskRenderNode * gsk_color_node_new ()
const GdkRGBA * gsk_color_node_get_color ()
GskRenderNode * gsk_texture_node_new ()
GdkTexture * gsk_texture_node_get_texture ()
GskRenderNode * gsk_linear_gradient_node_new ()
const graphene_point_t * gsk_linear_gradient_node_get_start ()
const graphene_point_t * gsk_linear_gradient_node_get_end ()
gsize gsk_linear_gradient_node_get_n_color_stops ()
const GskColorStop * gsk_linear_gradient_node_get_color_stops ()
GskRenderNode * gsk_repeating_linear_gradient_node_new ()
GskRenderNode * gsk_radial_gradient_node_new ()
gsize gsk_radial_gradient_node_get_n_color_stops ()
const GskColorStop * gsk_radial_gradient_node_get_color_stops ()
float gsk_radial_gradient_node_get_start ()
float gsk_radial_gradient_node_get_end ()
float gsk_radial_gradient_node_get_hradius ()
float gsk_radial_gradient_node_get_vradius ()
const graphene_point_t * gsk_radial_gradient_node_get_center ()
GskRenderNode * gsk_repeating_radial_gradient_node_new ()
GskRenderNode * gsk_conic_gradient_node_new ()
gsize gsk_conic_gradient_node_get_n_color_stops ()
const GskColorStop * gsk_conic_gradient_node_get_color_stops ()
const graphene_point_t * gsk_conic_gradient_node_get_center ()
float gsk_conic_gradient_node_get_rotation ()
GskRenderNode * gsk_border_node_new ()
const GskRoundedRect * gsk_border_node_get_outline ()
const float * gsk_border_node_get_widths ()
const GdkRGBA * gsk_border_node_get_colors ()
GskRenderNode * gsk_inset_shadow_node_new ()
const GskRoundedRect * gsk_inset_shadow_node_get_outline ()
const GdkRGBA * gsk_inset_shadow_node_get_color ()
float gsk_inset_shadow_node_get_dx ()
float gsk_inset_shadow_node_get_dy ()
float gsk_inset_shadow_node_get_spread ()
float gsk_inset_shadow_node_get_blur_radius ()
GskRenderNode * gsk_outset_shadow_node_new ()
const GskRoundedRect * gsk_outset_shadow_node_get_outline ()
const GdkRGBA * gsk_outset_shadow_node_get_color ()
float gsk_outset_shadow_node_get_dx ()
float gsk_outset_shadow_node_get_dy ()
float gsk_outset_shadow_node_get_spread ()
float gsk_outset_shadow_node_get_blur_radius ()
GskRenderNode * gsk_cairo_node_new ()
cairo_t * gsk_cairo_node_get_draw_context ()
cairo_surface_t * gsk_cairo_node_get_surface ()
GskRenderNode * gsk_container_node_new ()
guint gsk_container_node_get_n_children ()
GskRenderNode * gsk_container_node_get_child ()
GskRenderNode * gsk_transform_node_new ()
GskRenderNode * gsk_transform_node_get_child ()
GskTransform * gsk_transform_node_get_transform ()
GskRenderNode * gsk_opacity_node_new ()
GskRenderNode * gsk_opacity_node_get_child ()
float gsk_opacity_node_get_opacity ()
GskRenderNode * gsk_color_matrix_node_new ()
GskRenderNode * gsk_color_matrix_node_get_child ()
const graphene_matrix_t * gsk_color_matrix_node_get_color_matrix ()
const graphene_vec4_t * gsk_color_matrix_node_get_color_offset ()
GskRenderNode * gsk_repeat_node_new ()
GskRenderNode * gsk_repeat_node_get_child ()
const graphene_rect_t * gsk_repeat_node_get_child_bounds ()
GskRenderNode * gsk_clip_node_new ()
GskRenderNode * gsk_clip_node_get_child ()
const graphene_rect_t * gsk_clip_node_get_clip ()
GskRenderNode * gsk_rounded_clip_node_new ()
GskRenderNode * gsk_rounded_clip_node_get_child ()
const GskRoundedRect * gsk_rounded_clip_node_get_clip ()
GskRenderNode * gsk_shadow_node_new ()
const GskShadow * gsk_shadow_node_get_shadow ()
gsize gsk_shadow_node_get_n_shadows ()
GskRenderNode * gsk_shadow_node_get_child ()
GskRenderNode * gsk_blend_node_new ()
GskRenderNode * gsk_blend_node_get_bottom_child ()
GskRenderNode * gsk_blend_node_get_top_child ()
GskBlendMode gsk_blend_node_get_blend_mode ()
GskRenderNode * gsk_cross_fade_node_new ()
GskRenderNode * gsk_cross_fade_node_get_start_child ()
GskRenderNode * gsk_cross_fade_node_get_end_child ()
float gsk_cross_fade_node_get_progress ()
GskRenderNode * gsk_text_node_new ()
PangoFont * gsk_text_node_get_font ()
const PangoGlyphInfo * gsk_text_node_get_glyphs ()
const GdkRGBA * gsk_text_node_get_color ()
gboolean gsk_text_node_has_color_glyphs ()
guint gsk_text_node_get_num_glyphs ()
const graphene_point_t * gsk_text_node_get_offset ()
GskRenderNode * gsk_blur_node_new ()
GskRenderNode * gsk_blur_node_get_child ()
float gsk_blur_node_get_radius ()
GskRenderNode * gsk_debug_node_new ()
GskRenderNode * gsk_debug_node_get_child ()
const char * gsk_debug_node_get_message ()
GskRenderNode * gsk_gl_shader_node_new ()
guint gsk_gl_shader_node_get_n_children ()
GskRenderNode * gsk_gl_shader_node_get_child ()
GBytes * gsk_gl_shader_node_get_args ()
GskGLShader * gsk_gl_shader_node_get_shader ()

Object Hierarchy

    GskRenderNode

Description

GskRenderNode is the basic block in a scene graph to be rendered using GskRenderer.

Each node has a parent, except the top-level node; each node may have children nodes.

Each node has an associated drawing surface, which has the size of the rectangle set using gsk_render_node_set_bounds().

Render nodes are meant to be transient; once they have been associated to a GskRenderer it's safe to release any reference you have on them. All GskRenderNodes are immutable, you can only specify their properties during construction.

Functions

gsk_render_node_ref ()

GskRenderNode *
gsk_render_node_ref (GskRenderNode *node);

Acquires a reference on the given GskRenderNode.

Parameters

node

a GskRenderNode

 

Returns

the GskRenderNode with an additional reference.

[transfer full]


gsk_render_node_unref ()

void
gsk_render_node_unref (GskRenderNode *node);

Releases a reference on the given GskRenderNode.

If the reference was the last, the resources associated to the node are freed.

Parameters

node

a GskRenderNode.

[transfer full]

gsk_render_node_get_node_type ()

GskRenderNodeType
gsk_render_node_get_node_type (GskRenderNode *node);

Returns the type of the node .

Parameters

node

a GskRenderNode

 

Returns

the type of the GskRenderNode


gsk_render_node_draw ()

void
gsk_render_node_draw (GskRenderNode *node,
                      cairo_t *cr);

Draw the contents of node to the given cairo context.

Typically, you'll use this function to implement fallback rendering of GskRenderNodes on an intermediate Cairo context, instead of using the drawing context associated to a GdkSurface's rendering buffer.

For advanced nodes that cannot be supported using Cairo, in particular for nodes doing 3D operations, this function may fail.

Parameters

node

a GskRenderNode

 

cr

cairo context to draw to

 

GskParseErrorFunc ()

void
(*GskParseErrorFunc) (const GskParseLocation *start,
                      const GskParseLocation *end,
                      const GError *error,
                      gpointer user_data);

The type of callback that is called when a parse error occurs during deserialization of node data.

Parameters

start

start of the error location

 

end

end of the error location

 

error

the error

 

user_data

user data

 

gsk_render_node_serialize ()

GBytes *
gsk_render_node_serialize (GskRenderNode *node);

Serializes the node for later deserialization via gsk_render_node_deserialize(). No guarantees are made about the format used other than that the same version of GTK will be able to deserialize the result of a call to gsk_render_node_serialize() and gsk_render_node_deserialize() will correctly reject files it cannot open that were created with previous versions of GTK.

The intended use of this functions is testing, benchmarking and debugging. The format is not meant as a permanent storage format.

Parameters

node

a GskRenderNode

 

Returns

a GBytes representing the node.


gsk_render_node_deserialize ()

GskRenderNode *
gsk_render_node_deserialize (GBytes *bytes,
                             GskParseErrorFunc error_func,
                             gpointer user_data);

Loads data previously created via gsk_render_node_serialize(). For a discussion of the supported format, see that function.

Parameters

bytes

the bytes containing the data

 

error_func

Callback on parsing errors or NULL.

[nullable][scope call]

user_data

user_data for error_func .

[closure error_func]

Returns

a new GskRenderNode or NULL on error.

[nullable][transfer full]


gsk_render_node_write_to_file ()

gboolean
gsk_render_node_write_to_file (GskRenderNode *node,
                               const char *filename,
                               GError **error);

This function is equivalent to calling gsk_render_node_serialize() followed by g_file_set_contents(). See those two functions for details on the arguments.

It is mostly intended for use inside a debugger to quickly dump a render node to a file for later inspection.

Parameters

node

a GskRenderNode

 

filename

the file to save it to.

 

error

Return location for a potential error

 

Returns

TRUE if saving was successful


gsk_render_node_get_bounds ()

void
gsk_render_node_get_bounds (GskRenderNode *node,
                            graphene_rect_t *bounds);

Retrieves the boundaries of the node . The node will not draw outside of its boundaries.

Parameters

node

a GskRenderNode

 

bounds

return location for the boundaries.

[out caller-allocates]

gsk_color_node_new ()

GskRenderNode *
gsk_color_node_new (const GdkRGBA *rgba,
                    const graphene_rect_t *bounds);

Creates a GskRenderNode that will render the color specified by rgba into the area given by bounds .

Parameters

rgba

a GdkRGBA specifying a color

 

bounds

the rectangle to render the color into

 

Returns

A new GskRenderNode.

[transfer full][type GskColorNode]


gsk_color_node_get_color ()

const GdkRGBA *
gsk_color_node_get_color (GskRenderNode *node);

Retrieves the color of the given node .

Parameters

node

a GskColorNode.

[type GskColorNode]

Returns

the color of the node.

[transfer none]


gsk_texture_node_new ()

GskRenderNode *
gsk_texture_node_new (GdkTexture *texture,
                      const graphene_rect_t *bounds);

Creates a GskRenderNode that will render the given texture into the area given by bounds .

Parameters

texture

the GdkTexture

 

bounds

the rectangle to render the texture into

 

Returns

A new GskRenderNode.

[transfer full][type GskTextureNode]


gsk_texture_node_get_texture ()

GdkTexture *
gsk_texture_node_get_texture (GskRenderNode *node);

Retrieves the GdkTexture used when creating this GskRenderNode.

Parameters

node

a GskRenderNode of type GSK_TEXTURE_NODE.

[type GskTextureNode]

Returns

the GdkTexture.

[transfer none]


gsk_linear_gradient_node_new ()

GskRenderNode *
gsk_linear_gradient_node_new (const graphene_rect_t *bounds,
                              const graphene_point_t *start,
                              const graphene_point_t *end,
                              const GskColorStop *color_stops,
                              gsize n_color_stops);

Creates a GskRenderNode that will create a linear gradient from the given points and color stops, and render that into the area given by bounds .

Parameters

bounds

the rectangle to render the linear gradient into

 

start

the point at which the linear gradient will begin

 

end

the point at which the linear gradient will finish

 

color_stops

a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1.

[array length=n_color_stops]

n_color_stops

the number of elements in color_stops

 

Returns

A new GskRenderNode.

[transfer full][type GskLinearGradientNode]


gsk_linear_gradient_node_get_start ()

const graphene_point_t *
gsk_linear_gradient_node_get_start (GskRenderNode *node);

Retrieves the initial point of the linear gradient.

Parameters

node

a GskRenderNode for a linear gradient.

[type GskLinearGradientNode]

Returns

the initial point.

[transfer none]


gsk_linear_gradient_node_get_end ()

const graphene_point_t *
gsk_linear_gradient_node_get_end (GskRenderNode *node);

Retrieves the final point of the linear gradient.

Parameters

node

a GskRenderNode for a linear gradient.

[type GskLinearGradientNode]

Returns

the final point.

[transfer none]


gsk_linear_gradient_node_get_n_color_stops ()

gsize
gsk_linear_gradient_node_get_n_color_stops
                               (GskRenderNode *node);

Retrieves the number of color stops in the gradient.

Parameters

node

a GskRenderNode for a linear gradient.

[type GskLinearGradientNode]

Returns

the number of color stops


gsk_linear_gradient_node_get_color_stops ()

const GskColorStop *
gsk_linear_gradient_node_get_color_stops
                               (GskRenderNode *node,
                                gsize *n_stops);

Retrieves the color stops in the gradient.

Parameters

node

a GskRenderNode for a linear gradient.

[type GskLinearGradientNode]

n_stops

the number of color stops in the returned array.

[out][optional]

Returns

the color stops in the gradient.

[array length=n_stops]


gsk_repeating_linear_gradient_node_new ()

GskRenderNode *
gsk_repeating_linear_gradient_node_new
                               (const graphene_rect_t *bounds,
                                const graphene_point_t *start,
                                const graphene_point_t *end,
                                const GskColorStop *color_stops,
                                gsize n_color_stops);

Creates a GskRenderNode that will create a repeating linear gradient from the given points and color stops, and render that into the area given by bounds .

Parameters

bounds

the rectangle to render the linear gradient into

 

start

the point at which the linear gradient will begin

 

end

the point at which the linear gradient will finish

 

color_stops

a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1.

[array length=n_color_stops]

n_color_stops

the number of elements in color_stops

 

Returns

A new GskRenderNode.

[transfer full][type GskRepeatingLinearGradientNode]


gsk_radial_gradient_node_new ()

GskRenderNode *
gsk_radial_gradient_node_new (const graphene_rect_t *bounds,
                              const graphene_point_t *center,
                              float hradius,
                              float vradius,
                              float start,
                              float end,
                              const GskColorStop *color_stops,
                              gsize n_color_stops);

Creates a GskRenderNode that draws a radial gradient. The radial gradient starts around center . The size of the gradient is dictated by hradius in horizontal orientation and by vradius in vertial orientation.

Parameters

bounds

the bounds of the node

 

center

the center of the gradient

 

hradius

the horizontal radius

 

vradius

the vertical radius

 

start

a percentage >= 0 that defines the start of the gradient around center

 

end

a percentage >= 0 that defines the end of the gradient around center

 

color_stops

a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1.

[array length=n_color_stops]

n_color_stops

the number of elements in color_stops

 

Returns

A new GskRenderNode.

[transfer full][type GskRadialGradientNode]


gsk_radial_gradient_node_get_n_color_stops ()

gsize
gsk_radial_gradient_node_get_n_color_stops
                               (GskRenderNode *node);

Retrieves the number of color stops in the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

Returns

the number of color stops


gsk_radial_gradient_node_get_color_stops ()

const GskColorStop *
gsk_radial_gradient_node_get_color_stops
                               (GskRenderNode *node,
                                gsize *n_stops);

Retrieves the color stops in the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

n_stops

the number of color stops in the returned array.

[out][optional]

Returns

the color stops in the gradient.

[array length=n_stops]


gsk_radial_gradient_node_get_start ()

float
gsk_radial_gradient_node_get_start (GskRenderNode *node);

Retrieves the start value for the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

Returns

the start value for the gradient


gsk_radial_gradient_node_get_end ()

float
gsk_radial_gradient_node_get_end (GskRenderNode *node);

Retrieves the end value for the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

Returns

the end value for the gradient


gsk_radial_gradient_node_get_hradius ()

float
gsk_radial_gradient_node_get_hradius (GskRenderNode *node);

Retrieves the horizonal radius for the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

Returns

the horizontal radius for the gradient


gsk_radial_gradient_node_get_vradius ()

float
gsk_radial_gradient_node_get_vradius (GskRenderNode *node);

Retrieves the vertical radius for the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

Returns

the vertical radius for the gradient


gsk_radial_gradient_node_get_center ()

const graphene_point_t *
gsk_radial_gradient_node_get_center (GskRenderNode *node);

Retrieves the center pointer for the gradient.

Parameters

node

a GskRenderNode for a radial gradient.

[type GskRadialGradientNode]

Returns

the center point for the gradient


gsk_repeating_radial_gradient_node_new ()

GskRenderNode *
gsk_repeating_radial_gradient_node_new
                               (const graphene_rect_t *bounds,
                                const graphene_point_t *center,
                                float hradius,
                                float vradius,
                                float start,
                                float end,
                                const GskColorStop *color_stops,
                                gsize n_color_stops);

Creates a GskRenderNode that draws a repeating radial gradient. The radial gradient starts around center . The size of the gradient is dictated by hradius in horizontal orientation and by vradius in vertial orientation.

Parameters

bounds

the bounds of the node

 

center

the center of the gradient

 

hradius

the horizontal radius

 

vradius

the vertical radius

 

start

a percentage >= 0 that defines the start of the gradient around center

 

end

a percentage >= 0 that defines the end of the gradient around center

 

color_stops

a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1.

[array length=n_color_stops]

n_color_stops

the number of elements in color_stops

 

Returns

A new GskRenderNode.

[transfer full][type GskRepeatingRadialGradientNode]


gsk_conic_gradient_node_new ()

GskRenderNode *
gsk_conic_gradient_node_new (const graphene_rect_t *bounds,
                             const graphene_point_t *center,
                             float rotation,
                             const GskColorStop *color_stops,
                             gsize n_color_stops);

Creates a GskRenderNode that draws a conic gradient. The conic gradient starts around center in the direction of rotation . A rotation of 0 means that the gradient points up. Color stops are then added clockwise.

Parameters

bounds

the bounds of the node

 

center

the center of the gradient

 

rotation

the rotation of the gradient in degrees

 

color_stops

a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1.

[array length=n_color_stops]

n_color_stops

the number of elements in color_stops

 

Returns

A new GskRenderNode.

[transfer full][type GskConicGradientNode]


gsk_conic_gradient_node_get_n_color_stops ()

gsize
gsk_conic_gradient_node_get_n_color_stops
                               (GskRenderNode *node);

Retrieves the number of color stops in the gradient.

Parameters

node

a GskRenderNode for a conic gradient.

[type GskConicGradientNode]

Returns

the number of color stops


gsk_conic_gradient_node_get_color_stops ()

const GskColorStop *
gsk_conic_gradient_node_get_color_stops
                               (GskRenderNode *node,
                                gsize *n_stops);

Retrieves the color stops in the gradient.

Parameters

node

a GskRenderNode for a conic gradient.

[type GskConicGradientNode]

n_stops

the number of color stops in the returned array.

[out][optional]

Returns

the color stops in the gradient.

[array length=n_stops]


gsk_conic_gradient_node_get_center ()

const graphene_point_t *
gsk_conic_gradient_node_get_center (GskRenderNode *node);

Retrieves the center pointer for the gradient.

Parameters

node

a GskRenderNode for a conic gradient.

[type GskConicGradientNode]

Returns

the center point for the gradient


gsk_conic_gradient_node_get_rotation ()

float
gsk_conic_gradient_node_get_rotation (GskRenderNode *node);

Retrieves the rotation for the gradient in degrees.

Parameters

node

a GskRenderNode for a conic gradient.

[type GskConicGradientNode]

Returns

the rotation for the gradient


gsk_border_node_new ()

GskRenderNode *
gsk_border_node_new (const GskRoundedRect *outline,
                     const float border_width[4],
                     const GdkRGBA border_color[4]);

Creates a GskRenderNode that will stroke a border rectangle inside the given outline . The 4 sides of the border can have different widths and colors.

Parameters

outline

a GskRoundedRect describing the outline of the border

 

border_width

the stroke width of the border on the top, right, bottom and left side respectively.

[array fixed-size=4]

border_color

the color used on the top, right, bottom and left side.

[array fixed-size=4]

Returns

A new GskRenderNode.

[transfer full][type GskBorderNode]


gsk_border_node_get_outline ()

const GskRoundedRect *
gsk_border_node_get_outline (GskRenderNode *node);

Retrieves the outline of the border.

Parameters

node

a GskRenderNode for a border.

[type GskBorderNode]

Returns

the outline of the border


gsk_border_node_get_widths ()

const float *
gsk_border_node_get_widths (GskRenderNode *node);

Retrieves the stroke widths of the border.

Parameters

node

a GskRenderNode for a border.

[type GskBorderNode]

Returns

an array of 4 floats for the top, right, bottom and left stroke width of the border, respectively.

[transfer none][array fixed-size=4]


gsk_border_node_get_colors ()

const GdkRGBA *
gsk_border_node_get_colors (GskRenderNode *node);

Retrieves the colors of the border.

Parameters

node

a GskRenderNode for a border.

[type GskBorderNode]

Returns

an array of 4 GdkRGBA structs for the top, right, bottom and left color of the border.

[transfer none]


gsk_inset_shadow_node_new ()

GskRenderNode *
gsk_inset_shadow_node_new (const GskRoundedRect *outline,
                           const GdkRGBA *color,
                           float dx,
                           float dy,
                           float spread,
                           float blur_radius);

Creates a GskRenderNode that will render an inset shadow into the box given by outline .

Parameters

outline

outline of the region containing the shadow

 

color

color of the shadow

 

dx

horizontal offset of shadow

 

dy

vertical offset of shadow

 

spread

how far the shadow spreads towards the inside

 

blur_radius

how much blur to apply to the shadow

 

Returns

A new GskRenderNode.

[transfer full][type GskInsetShadowNode]


gsk_inset_shadow_node_get_outline ()

const GskRoundedRect *
gsk_inset_shadow_node_get_outline (GskRenderNode *node);

Retrieves the outline rectangle of the inset shadow.

Parameters

node

a GskRenderNode for an inset shadow.

[type GskInsetShadowNode]

Returns

a rounded rectangle.

[transfer none]


gsk_inset_shadow_node_get_color ()

const GdkRGBA *
gsk_inset_shadow_node_get_color (GskRenderNode *node);

Retrieves the color of the inset shadow.

Parameters

node

a GskRenderNode for an inset shadow.

[type GskInsetShadowNode]

Returns

the color of the shadow.

[transfer none]


gsk_inset_shadow_node_get_dx ()

float
gsk_inset_shadow_node_get_dx (GskRenderNode *node);

Retrieves the horizontal offset of the inset shadow.

Parameters

node

a GskRenderNode for an inset shadow.

[type GskInsetShadowNode]

Returns

an offset, in pixels


gsk_inset_shadow_node_get_dy ()

float
gsk_inset_shadow_node_get_dy (GskRenderNode *node);

Retrieves the vertical offset of the inset shadow.

Parameters

node

a GskRenderNode for an inset shadow.

[type GskInsetShadowNode]

Returns

an offset, in pixels


gsk_inset_shadow_node_get_spread ()

float
gsk_inset_shadow_node_get_spread (GskRenderNode *node);

Retrieves how much the shadow spreads inwards.

Parameters

node

a GskRenderNode for an inset shadow.

[type GskInsetShadowNode]

Returns

the size of the shadow, in pixels


gsk_inset_shadow_node_get_blur_radius ()

float
gsk_inset_shadow_node_get_blur_radius (GskRenderNode *node);

Retrieves the blur radius to apply to the shadow.

Parameters

node

a GskRenderNode for an inset shadow.

[type GskInsetShadowNode]

Returns

the blur radius, in pixels


gsk_outset_shadow_node_new ()

GskRenderNode *
gsk_outset_shadow_node_new (const GskRoundedRect *outline,
                            const GdkRGBA *color,
                            float dx,
                            float dy,
                            float spread,
                            float blur_radius);

Creates a GskRenderNode that will render an outset shadow around the box given by outline .

Parameters

outline

outline of the region surrounded by shadow

 

color

color of the shadow

 

dx

horizontal offset of shadow

 

dy

vertical offset of shadow

 

spread

how far the shadow spreads towards the inside

 

blur_radius

how much blur to apply to the shadow

 

Returns

A new GskRenderNode.

[transfer full][type GskOutsetShadowNode]


gsk_outset_shadow_node_get_outline ()

const GskRoundedRect *
gsk_outset_shadow_node_get_outline (GskRenderNode *node);

Retrieves the outline rectangle of the outset shadow.

Parameters

node

a GskRenderNode for an outset shadow.

[type GskOutsetShadowNode]

Returns

a rounded rectangle.

[transfer none]


gsk_outset_shadow_node_get_color ()

const GdkRGBA *
gsk_outset_shadow_node_get_color (GskRenderNode *node);

Retrieves the color of the outset shadow.

Parameters

node

a GskRenderNode for an outset shadow.

[type GskOutsetShadowNode]

Returns

a color.

[transfer none]


gsk_outset_shadow_node_get_dx ()

float
gsk_outset_shadow_node_get_dx (GskRenderNode *node);

Retrieves the horizontal offset of the outset shadow.

Parameters

node

a GskRenderNode for an outset shadow.

[type GskOutsetShadowNode]

Returns

an offset, in pixels


gsk_outset_shadow_node_get_dy ()

float
gsk_outset_shadow_node_get_dy (GskRenderNode *node);

Retrieves the vertical offset of the outset shadow.

Parameters

node

a GskRenderNode for an outset shadow.

[type GskOutsetShadowNode]

Returns

an offset, in pixels


gsk_outset_shadow_node_get_spread ()

float
gsk_outset_shadow_node_get_spread (GskRenderNode *node);

Retrieves how much the shadow spreads outwards.

Parameters

node

a GskRenderNode for an outset shadow.

[type GskOutsetShadowNode]

Returns

the size of the shadow, in pixels


gsk_outset_shadow_node_get_blur_radius ()

float
gsk_outset_shadow_node_get_blur_radius
                               (GskRenderNode *node);

Retrieves the blur radius of the shadow.

Parameters

node

a GskRenderNode for an outset shadow.

[type GskOutsetShadowNode]

Returns

the blur radius, in pixels


gsk_cairo_node_new ()

GskRenderNode *
gsk_cairo_node_new (const graphene_rect_t *bounds);

Creates a GskRenderNode that will render a cairo surface into the area given by bounds . You can draw to the cairo surface using gsk_cairo_node_get_draw_context()

Parameters

bounds

the rectangle to render to

 

Returns

A new GskRenderNode.

[transfer full][type GskCairoNode]


gsk_cairo_node_get_draw_context ()

cairo_t *
gsk_cairo_node_get_draw_context (GskRenderNode *node);

Creates a Cairo context for drawing using the surface associated to the render node.

If no surface exists yet, a surface will be created optimized for rendering to renderer .

Parameters

node

a GskRenderNode for a Cairo surface.

[type GskCairoNode]

Returns

a Cairo context used for drawing; use cairo_destroy() when done drawing.

[transfer full]


gsk_cairo_node_get_surface ()

cairo_surface_t *
gsk_cairo_node_get_surface (GskRenderNode *node);

Retrieves the Cairo surface used by the render node.

Parameters

node

a GskRenderNode for a Cairo surface.

[type GskCairoNode]

Returns

a Cairo surface.

[transfer none]


gsk_container_node_new ()

GskRenderNode *
gsk_container_node_new (GskRenderNode **children,
                        guint n_children);

Creates a new GskRenderNode instance for holding the given children . The new node will acquire a reference to each of the children.

Parameters

children

The children of the node.

[array length=n_children][transfer none]

n_children

Number of children in the children array

 

Returns

the new GskRenderNode.

[transfer full][type GskContainerNode]


gsk_container_node_get_n_children ()

guint
gsk_container_node_get_n_children (GskRenderNode *node);

Retrieves the number of direct children of node .

Parameters

node

a container GskRenderNode.

[type GskContainerNode]

Returns

the number of children of the GskRenderNode


gsk_container_node_get_child ()

GskRenderNode *
gsk_container_node_get_child (GskRenderNode *node,
                              guint idx);

Gets one of the children of container .

Parameters

node

a container GskRenderNode.

[type GskContainerNode]

idx

the position of the child to get

 

Returns

the idx 'th child of container .

[transfer none]


gsk_transform_node_new ()

GskRenderNode *
gsk_transform_node_new (GskRenderNode *child,
                        GskTransform *transform);

Creates a GskRenderNode that will transform the given child with the given transform .

Parameters

child

The node to transform

 

transform

The transform to apply.

[transfer none]

Returns

A new GskRenderNode.

[transfer full][type GskTransformNode]


gsk_transform_node_get_child ()

GskRenderNode *
gsk_transform_node_get_child (GskRenderNode *node);

Gets the child node that is getting transformed by the given node .

Parameters

node

a GskRenderNode for a transform.

[type GskTransformNode]

Returns

The child that is getting transformed.

[transfer none]


gsk_transform_node_get_transform ()

GskTransform *
gsk_transform_node_get_transform (GskRenderNode *node);

Retrieves the GskTransform used by the node .

Parameters

node

a GskRenderNode for a transform.

[type GskTransformNode]

Returns

a GskTransform.

[transfer none]


gsk_opacity_node_new ()

GskRenderNode *
gsk_opacity_node_new (GskRenderNode *child,
                      float opacity);

Creates a GskRenderNode that will drawn the child with reduced opacity .

Parameters

child

The node to draw

 

opacity

The opacity to apply

 

Returns

A new GskRenderNode.

[transfer full][type GskOpacityNode]


gsk_opacity_node_get_child ()

GskRenderNode *
gsk_opacity_node_get_child (GskRenderNode *node);

Gets the child node that is getting opacityed by the given node .

Parameters

node

a GskRenderNode for an opacity.

[type GskOpacityNode]

Returns

The child that is getting opacityed.

[transfer none]


gsk_opacity_node_get_opacity ()

float
gsk_opacity_node_get_opacity (GskRenderNode *node);

Gets the transparency factor for an opacity node.

Parameters

node

a GskRenderNode for an opacity.

[type GskOpacityNode]

Returns

the opacity factor


gsk_color_matrix_node_new ()

GskRenderNode *
gsk_color_matrix_node_new (GskRenderNode *child,
                           const graphene_matrix_t *color_matrix,
                           const graphene_vec4_t *color_offset);

Creates a GskRenderNode that will drawn the child with reduced color_matrix .

In particular, the node will transform the operation

1
pixel = color_matrix * pixel + color_offset

for every pixel.

Parameters

child

The node to draw

 

color_matrix

The matrix to apply

 

color_offset

Values to add to the color

 

Returns

A new GskRenderNode.

[transfer full][type GskColorMatrixNode]


gsk_color_matrix_node_get_child ()

GskRenderNode *
gsk_color_matrix_node_get_child (GskRenderNode *node);

Gets the child node that is getting its colors modified by the given node .

Parameters

node

a color matrix GskRenderNode.

[type GskColorMatrixNode]

Returns

The child that is getting its colors modified.

[transfer none]


gsk_color_matrix_node_get_color_matrix ()

const graphene_matrix_t *
gsk_color_matrix_node_get_color_matrix
                               (GskRenderNode *node);

Retrieves the color matrix used by the node .

Parameters

node

a color matrix GskRenderNode.

[type GskColorMatrixNode]

Returns

a 4x4 color matrix


gsk_color_matrix_node_get_color_offset ()

const graphene_vec4_t *
gsk_color_matrix_node_get_color_offset
                               (GskRenderNode *node);

Retrieves the color offset used by the node .

Parameters

node

a color matrix GskRenderNode.

[type GskColorMatrixNode]

Returns

a color vector


gsk_repeat_node_new ()

GskRenderNode *
gsk_repeat_node_new (const graphene_rect_t *bounds,
                     GskRenderNode *child,
                     const graphene_rect_t *child_bounds);

Creates a GskRenderNode that will repeat the drawing of child across the given bounds .

Parameters

bounds

The bounds of the area to be painted

 

child

The child to repeat

 

child_bounds

The area of the child to repeat or NULL to use the child's bounds.

[allow-none]

Returns

A new GskRenderNode.

[transfer full][type GskRepeatNode]


gsk_repeat_node_get_child ()

GskRenderNode *
gsk_repeat_node_get_child (GskRenderNode *node);

Retrieves the child of node .

Parameters

node

a repeat GskRenderNode.

[type GskRepeatNode]

Returns

a GskRenderNode.

[transfer none]


gsk_repeat_node_get_child_bounds ()

const graphene_rect_t *
gsk_repeat_node_get_child_bounds (GskRenderNode *node);

Retrieves the bounding rectangle of the child of node .

Parameters

node

a repeat GskRenderNode.

[type GskRepeatNode]

Returns

a bounding rectangle.

[transfer none]


gsk_clip_node_new ()

GskRenderNode *
gsk_clip_node_new (GskRenderNode *child,
                   const graphene_rect_t *clip);

Creates a GskRenderNode that will clip the child to the area given by clip .

Parameters

child

The node to draw

 

clip

The clip to apply

 

Returns

A new GskRenderNode.

[transfer full][type GskClipNode]


gsk_clip_node_get_child ()

GskRenderNode *
gsk_clip_node_get_child (GskRenderNode *node);

Gets the child node that is getting clipped by the given node .

Parameters

node

a clip GskRenderNode .

[type GskClipNode]

Returns

The child that is getting clipped.

[transfer none]


gsk_clip_node_get_clip ()

const graphene_rect_t *
gsk_clip_node_get_clip (GskRenderNode *node);

Retrieves the clip rectangle for node .

Parameters

node

a GskClipNode.

[type GskClipNode]

Returns

a clip rectangle


gsk_rounded_clip_node_new ()

GskRenderNode *
gsk_rounded_clip_node_new (GskRenderNode *child,
                           const GskRoundedRect *clip);

Creates a GskRenderNode that will clip the child to the area given by clip .

Parameters

child

The node to draw

 

clip

The clip to apply

 

Returns

A new GskRenderNode.

[transfer none][type GskRoundedClipNode]


gsk_rounded_clip_node_get_child ()

GskRenderNode *
gsk_rounded_clip_node_get_child (GskRenderNode *node);

Gets the child node that is getting clipped by the given node .

Parameters

node

a rounded clip GskRenderNode.

[type GskRoundedClipNode]

Returns

The child that is getting clipped.

[transfer none]


gsk_rounded_clip_node_get_clip ()

const GskRoundedRect *
gsk_rounded_clip_node_get_clip (GskRenderNode *node);

Retrievs the rounded rectangle used to clip the contents of the node .

Parameters

node

a rounded clip GskRenderNode.

[type GskRoundedClipNode]

Returns

a rounded rectangle.

[transfer none]


gsk_shadow_node_new ()

GskRenderNode *
gsk_shadow_node_new (GskRenderNode *child,
                     const GskShadow *shadows,
                     gsize n_shadows);

Creates a GskRenderNode that will draw a child with the given shadows below it.

Parameters

child

The node to draw

 

shadows

The shadows to apply.

[array length=n_shadows]

n_shadows

number of entries in the shadows array

 

Returns

A new GskRenderNode.

[transfer full][type GskShadowNode]


gsk_shadow_node_get_shadow ()

const GskShadow *
gsk_shadow_node_get_shadow (GskRenderNode *node,
                            gsize i);

Retrieves the shadow data at the given index i .

Parameters

node

a shadow GskRenderNode.

[type GskShadowNode]

i

the given index

 

Returns

the shadow data.

[transfer none]


gsk_shadow_node_get_n_shadows ()

gsize
gsk_shadow_node_get_n_shadows (GskRenderNode *node);

Retrieves the number of shadows in the node .

Parameters

node

a shadow GskRenderNode.

[type GskShadowNode]

Returns

the number of shadows.


gsk_shadow_node_get_child ()

GskRenderNode *
gsk_shadow_node_get_child (GskRenderNode *node);

Retrieves the child GskRenderNode of the shadow node .

Parameters

node

a shadow GskRenderNode.

[type GskShadowNode]

Returns

the child render node.

[transfer none]


gsk_blend_node_new ()

GskRenderNode *
gsk_blend_node_new (GskRenderNode *bottom,
                    GskRenderNode *top,
                    GskBlendMode blend_mode);

Creates a GskRenderNode that will use blend_mode to blend the top node onto the bottom node.

Parameters

bottom

The bottom node to be drawn

 

top

The node to be blended onto the bottom node

 

blend_mode

The blend mode to use

 

Returns

A new GskRenderNode.

[transfer full][type GskBlendNode]


gsk_blend_node_get_bottom_child ()

GskRenderNode *
gsk_blend_node_get_bottom_child (GskRenderNode *node);

Retrieves the bottom GskRenderNode child of the node .

Parameters

node

a blending GskRenderNode.

[type GskBlendNode]

Returns

the bottom child node.

[transfer none]


gsk_blend_node_get_top_child ()

GskRenderNode *
gsk_blend_node_get_top_child (GskRenderNode *node);

Retrieves the top GskRenderNode child of the node .

Parameters

node

a blending GskRenderNode.

[type GskBlendNode]

Returns

the top child node.

[transfer none]


gsk_blend_node_get_blend_mode ()

GskBlendMode
gsk_blend_node_get_blend_mode (GskRenderNode *node);

Retrieves the blend mode used by node .

Parameters

node

a blending GskRenderNode.

[type GskBlendNode]

Returns

the blend mode


gsk_cross_fade_node_new ()

GskRenderNode *
gsk_cross_fade_node_new (GskRenderNode *start,
                         GskRenderNode *end,
                         float progress);

Creates a GskRenderNode that will do a cross-fade between start and end .

Parameters

start

The start node to be drawn

 

end

The node to be cross_fadeed onto the start node

 

progress

How far the fade has progressed from start to end. The value will be clamped to the range [0 ... 1]

 

Returns

A new GskRenderNode.

[transfer full][type GskCrossFadeNode]


gsk_cross_fade_node_get_start_child ()

GskRenderNode *
gsk_cross_fade_node_get_start_child (GskRenderNode *node);

Retrieves the child GskRenderNode at the beginning of the cross-fade.

Parameters

node

a cross-fading GskRenderNode.

[type GskCrossFadeNode]

Returns

a GskRenderNode.

[transfer none]


gsk_cross_fade_node_get_end_child ()

GskRenderNode *
gsk_cross_fade_node_get_end_child (GskRenderNode *node);

Retrieves the child GskRenderNode at the end of the cross-fade.

Parameters

node

a cross-fading GskRenderNode.

[type GskCrossFadeNode]

Returns

a GskRenderNode.

[transfer none]


gsk_cross_fade_node_get_progress ()

float
gsk_cross_fade_node_get_progress (GskRenderNode *node);

Retrieves the progress value of the cross fade.

Parameters

node

a cross-fading GskRenderNode.

[type GskCrossFadeNode]

Returns

the progress value, between 0 and 1


gsk_text_node_new ()

GskRenderNode *
gsk_text_node_new (PangoFont *font,
                   PangoGlyphString *glyphs,
                   const GdkRGBA *color,
                   const graphene_point_t *offset);

Creates a render node that renders the given glyphs, Note that color may not be used if the font contains color glyphs.

Parameters

font

the PangoFont containing the glyphs

 

glyphs

the PangoGlyphString to render

 

color

the foreground color to render with

 

offset

offset of the baseline

 

Returns

a new GskRenderNode.

[nullable][transfer full][type GskTextNode]


gsk_text_node_get_font ()

PangoFont *
gsk_text_node_get_font (GskRenderNode *node);

Returns the font used by the text node .

Parameters

node

The GskRenderNode.

[type GskTextNode]

Returns

the font.

[transfer none]


gsk_text_node_get_glyphs ()

const PangoGlyphInfo *
gsk_text_node_get_glyphs (GskRenderNode *node,
                          guint *n_glyphs);

Retrieves the glyph information in the node .

Parameters

node

a text GskRenderNode.

[type GskTextNode]

n_glyphs

the number of glyphs returned.

[out][optional]

Returns

the glyph information.

[transfer none][array length=n_glyphs]


gsk_text_node_get_color ()

const GdkRGBA *
gsk_text_node_get_color (GskRenderNode *node);

Retrieves the color used by the text node .

Parameters

node

a text GskRenderNode.

[type GskTextNode]

Returns

the text color.

[transfer none]


gsk_text_node_has_color_glyphs ()

gboolean
gsk_text_node_has_color_glyphs (GskRenderNode *node);

Checks whether the text node has color glyphs.

Parameters

node

a text GskRenderNode.

[type GskTextNode]

Returns

TRUE if the text node has color glyphs


gsk_text_node_get_num_glyphs ()

guint
gsk_text_node_get_num_glyphs (GskRenderNode *node);

Retrieves the number of glyphs in the text node.

Parameters

node

a text GskRenderNode.

[type GskTextNode]

Returns

the number of glyphs


gsk_text_node_get_offset ()

const graphene_point_t *
gsk_text_node_get_offset (GskRenderNode *node);

Retrieves the offset applied to the text.

Parameters

node

a text GskRenderNode.

[type GskTextNode]

Returns

a point with the horizontal and vertical offsets.

[transfer none]


gsk_blur_node_new ()

GskRenderNode *
gsk_blur_node_new (GskRenderNode *child,
                   float radius);

Creates a render node that blurs the child.

Parameters

child

the child node to blur

 

radius

the blur radius

 

Returns

a new GskRenderNode.

[transfer full][type GskBlurNode]


gsk_blur_node_get_child ()

GskRenderNode *
gsk_blur_node_get_child (GskRenderNode *node);

Retrieves the child GskRenderNode of the blur node .

Parameters

node

a blur GskRenderNode.

[type GskBlurNode]

Returns

the blurred child node.

[transfer none]


gsk_blur_node_get_radius ()

float
gsk_blur_node_get_radius (GskRenderNode *node);

Retrieves the blur radius of the node .

Parameters

node

a blur GskRenderNode.

[type GskBlurNode]

Returns

the blur radius


gsk_debug_node_new ()

GskRenderNode *
gsk_debug_node_new (GskRenderNode *child,
                    char *message);

Creates a GskRenderNode that will add debug information about the given child .

Adding this node has no visual effect.

Parameters

child

The child to add debug info for

 

message

The debug message.

[transfer full]

Returns

A new GskRenderNode.

[transfer full][type GskDebugNode]


gsk_debug_node_get_child ()

GskRenderNode *
gsk_debug_node_get_child (GskRenderNode *node);

Gets the child node that is getting drawn by the given node .

Parameters

node

a debug GskRenderNode.

[type GskDebugNode]

Returns

the child GskRenderNode.

[transfer none]


gsk_debug_node_get_message ()

const char *
gsk_debug_node_get_message (GskRenderNode *node);

Gets the debug message that was set on this node

Parameters

node

a debug GskRenderNode.

[type GskDebugNode]

Returns

The debug message.

[transfer none]


gsk_gl_shader_node_new ()

GskRenderNode *
gsk_gl_shader_node_new (GskGLShader *shader,
                        const graphene_rect_t *bounds,
                        GBytes *args,
                        GskRenderNode **children,
                        guint n_children);

Creates a GskRenderNode that will render the given shader into the area given by bounds . The args is a block of data to use for uniform input, as per types and offsets defined by the shader . Normally this is generated by gsk_gl_shader_format_args() or GskGLShaderArgBuilder.

See GskGLShader for details about how the shader should be written.

All the children will be rendered into textures (if they aren't already GskTextureNodes, which will be used directly). These textures will be sent as input to the shader.

If the renderer doesn't support GL shaders, or if there is any problem when compiling the shader, then the node will draw pink. You should use gsk_gl_shader_compile() to ensure the shader will work for the renderer before using it.

Parameters

shader

the GskGLShader

 

bounds

the rectangle to render the shader into

 

args

Arguments for the uniforms

 

children

array of child nodes, these will be rendered to textures and used as input.

[array length=n_children]

n_children

Length of children (currenly the GL backend supports up to 4 children)

 

Returns

A new GskRenderNode.

[transfer full][type GskGLShaderNode]


gsk_gl_shader_node_get_n_children ()

guint
gsk_gl_shader_node_get_n_children (GskRenderNode *node);

Returns the number of children

Parameters

node

a GskRenderNode for a gl shader.

[type GskGLShaderNode]

Returns

The number of children


gsk_gl_shader_node_get_child ()

GskRenderNode *
gsk_gl_shader_node_get_child (GskRenderNode *node,
                              guint idx);

Gets one of the children.

Parameters

node

a GskRenderNode for a gl shader.

[type GskGLShaderNode]

idx

the position of the child to get

 

Returns

the idx 'th child of node .

[transfer none]


gsk_gl_shader_node_get_args ()

GBytes *
gsk_gl_shader_node_get_args (GskRenderNode *node);

Gets args for the node.

Parameters

node

a GskRenderNode for a gl shader.

[type GskGLShaderNode]

Returns

A GBytes with the uniform arguments.

[transfer none]


gsk_gl_shader_node_get_shader ()

GskGLShader *
gsk_gl_shader_node_get_shader (GskRenderNode *node);

Gets shader code for the node.

Parameters

node

a GskRenderNode for a gl shader.

[type GskGLShaderNode]

Returns

the GskGLShader shader.

[transfer none]

Types and Values

GskRenderNode

typedef struct _GskRenderNode GskRenderNode;

A node in the render tree.


GskBlendNode

typedef struct _GskBlendNode GskBlendNode;

A render node applying a blending function between its two child nodes.


GskBlurNode

typedef struct _GskBlurNode GskBlurNode;

A render node applying a blur effect to its single child.


GskBorderNode

typedef struct _GskBorderNode GskBorderNode;

A render node for a border.


GskCairoNode

typedef struct _GskCairoNode GskCairoNode;

A render node for a Cairo surface.


GskClipNode

typedef struct _GskClipNode GskClipNode;

A render node applying a rectangular clip to its single child node.


GskColorMatrixNode

typedef struct _GskColorMatrixNode GskColorMatrixNode;

A render node controlling the color matrix of its single child node.


GskColorNode

typedef struct _GskColorNode GskColorNode;

A render node for a solid color.


GskConicGradientNode

typedef struct _GskConicGradientNode GskConicGradientNode;

A render node for a conic gradient.


GskContainerNode

typedef struct _GskContainerNode GskContainerNode;

A render node that can contain other render nodes.


GskCrossFadeNode

typedef struct _GskCrossFadeNode GskCrossFadeNode;

A render node cross fading between two child nodes.


GskDebugNode

typedef struct _GskDebugNode GskDebugNode;

A render node that emits a debugging message when drawing its child node.


GskInsetShadowNode

typedef struct _GskInsetShadowNode GskInsetShadowNode;

A render node for an inset shadow.


GskLinearGradientNode

typedef struct _GskLinearGradientNode GskLinearGradientNode;

A render node for a linear gradient.


GskRadialGradientNode

typedef struct _GskRadialGradientNode GskRadialGradientNode;

A render node for a radial gradient.


GskOpacityNode

typedef struct _GskOpacityNode GskOpacityNode;

A render node controlling the opacity of its single child node.


GskOutsetShadowNode

typedef struct _GskOutsetShadowNode GskOutsetShadowNode;

A render node for an outset shadow.


GskRepeatingLinearGradientNode

typedef struct _GskRepeatingLinearGradientNode GskRepeatingLinearGradientNode;

A render node for a repeating linear gradient.


GskRepeatingRadialGradientNode

typedef struct _GskRepeatingRadialGradientNode GskRepeatingRadialGradientNode;

A render node for a repeating radial gradient.


GskRepeatNode

typedef struct _GskRepeatNode GskRepeatNode;

A render node repeating its single child node.


GskRoundedClipNode

typedef struct _GskRoundedClipNode GskRoundedClipNode;

A render node applying a rounded rectangle clip to its single child.


GskShadowNode

typedef struct _GskShadowNode GskShadowNode;

A render node drawing one or more shadows behind its single child node.


GskTextNode

typedef struct _GskTextNode GskTextNode;

A render node drawing a set of glyphs.


GskTextureNode

typedef struct _GskTextureNode GskTextureNode;

A render node for a GdkTexture.


GskTransformNode

typedef struct _GskTransformNode GskTransformNode;

A render node applying a GskTransform to its single child node.


GskGLShaderNode

typedef struct _GskGLShaderNode GskGLShaderNode;

A render node using a GL shader when drawing its children nodes.


enum GskRenderNodeType

The type of a node determines what the node is rendering.

Members

GSK_NOT_A_RENDER_NODE

Error type. No node will ever have this type.

 

GSK_CONTAINER_NODE

A node containing a stack of children

 

GSK_CAIRO_NODE

A node drawing a cairo_surface_t

 

GSK_COLOR_NODE

A node drawing a single color rectangle

 

GSK_LINEAR_GRADIENT_NODE

A node drawing a linear gradient

 

GSK_REPEATING_LINEAR_GRADIENT_NODE

A node drawing a repeating linear gradient

 

GSK_RADIAL_GRADIENT_NODE

A node drawing a radial gradient

 

GSK_REPEATING_RADIAL_GRADIENT_NODE

A node drawing a repeating radial gradient

 

GSK_CONIC_GRADIENT_NODE

A node drawing a conic gradient

 

GSK_BORDER_NODE

A node stroking a border around an area

 

GSK_TEXTURE_NODE

A node drawing a GdkTexture

 

GSK_INSET_SHADOW_NODE

A node drawing an inset shadow

 

GSK_OUTSET_SHADOW_NODE

A node drawing an outset shadow

 

GSK_TRANSFORM_NODE

A node that renders its child after applying a matrix transform

 

GSK_OPACITY_NODE

A node that changes the opacity of its child

 

GSK_COLOR_MATRIX_NODE

A node that applies a color matrix to every pixel

 

GSK_REPEAT_NODE

A node that repeats the child's contents

 

GSK_CLIP_NODE

A node that clips its child to a rectangular area

 

GSK_ROUNDED_CLIP_NODE

A node that clips its child to a rounded rectangle

 

GSK_SHADOW_NODE

A node that draws a shadow below its child

 

GSK_BLEND_NODE

A node that blends two children together

 

GSK_CROSS_FADE_NODE

A node that cross-fades between two children

 

GSK_TEXT_NODE

A node containing a glyph string

 

GSK_BLUR_NODE

A node that applies a blur

 

GSK_DEBUG_NODE

Debug information that does not affect the rendering

 

GSK_GL_SHADER_NODE

A node that uses OpenGL fragment shaders to render

 

enum GskSerializationError

Errors that can happen during (de)serialization.

Members

GSK_SERIALIZATION_UNSUPPORTED_FORMAT

The format can not be identified

 

GSK_SERIALIZATION_UNSUPPORTED_VERSION

The version of the data is not understood

 

GSK_SERIALIZATION_INVALID_DATA

The given data may not exist in a proper serialization

 

struct GskParseLocation

struct GskParseLocation {
  gsize bytes;
  gsize chars;
  gsize lines;
  gsize line_bytes;
  gsize line_chars;
};

A location in a parse buffer.

Members

gsize bytes;

the offset of the location in the parse buffer, as bytes

 

gsize chars;

the offset of the location in the parse buffer, as characters

 

gsize lines;

the line of the location in the parse buffer

 

gsize line_bytes;

the position in the line, as bytes

 

gsize line_chars;

the position in the line, as characters

 

enum GskScalingFilter

The filters used when scaling texture data.

The actual implementation of each filter is deferred to the rendering pipeline.

Members

GSK_SCALING_FILTER_LINEAR

linear interpolation filter

 

GSK_SCALING_FILTER_NEAREST

nearest neighbor interpolation filter

 

GSK_SCALING_FILTER_TRILINEAR

linear interpolation along each axis, plus mipmap generation, with linear interpolation along the mipmap levels

 

struct GskColorStop

struct GskColorStop {
  float offset;
  GdkRGBA color;
};

A color stop in a gradient node.

Members

float offset;

the offset of the color stop

 

GdkRGBA color;

the color at the given offset

 

struct GskShadow

struct GskShadow {
  GdkRGBA color;
  float dx;
  float dy;
  float radius;
};

The shadow parameters in a shadow node.

Members

GdkRGBA color;

the color of the shadow

 

float dx;

the horizontal offset of the shadow

 

float dy;

the vertical offset of the shadow

 

float radius;

the radius of the shadow

 

enum GskBlendMode

The blend modes available for render nodes.

The implementation of each blend mode is deferred to the rendering pipeline.

See https://www.w3.org/TR/compositing-1/blending for more information on blending and blend modes.

Members

GSK_BLEND_MODE_DEFAULT

The default blend mode, which specifies no blending

 

GSK_BLEND_MODE_MULTIPLY

The source color is multiplied by the destination and replaces the destination

 

GSK_BLEND_MODE_SCREEN

Multiplies the complements of the destination and source color values, then complements the result.

 

GSK_BLEND_MODE_OVERLAY

Multiplies or screens the colors, depending on the destination color value. This is the inverse of hard-list

 

GSK_BLEND_MODE_DARKEN

Selects the darker of the destination and source colors

 

GSK_BLEND_MODE_LIGHTEN

Selects the lighter of the destination and source colors

 

GSK_BLEND_MODE_COLOR_DODGE

Brightens the destination color to reflect the source color

 

GSK_BLEND_MODE_COLOR_BURN

Darkens the destination color to reflect the source color

 

GSK_BLEND_MODE_HARD_LIGHT

Multiplies or screens the colors, depending on the source color value

 

GSK_BLEND_MODE_SOFT_LIGHT

Darkens or lightens the colors, depending on the source color value

 

GSK_BLEND_MODE_DIFFERENCE

Subtracts the darker of the two constituent colors from the lighter color

 

GSK_BLEND_MODE_EXCLUSION

Produces an effect similar to that of the difference mode but lower in contrast

 

GSK_BLEND_MODE_COLOR

Creates a color with the hue and saturation of the source color and the luminosity of the destination color

 

GSK_BLEND_MODE_HUE

Creates a color with the hue of the source color and the saturation and luminosity of the destination color

 

GSK_BLEND_MODE_SATURATION

Creates a color with the saturation of the source color and the hue and luminosity of the destination color

 

GSK_BLEND_MODE_LUMINOSITY

Creates a color with the luminosity of the source color and the hue and saturation of the destination color

 
docs/reference/gsk/html/GskRenderer.html0000664000175000017500000006744313766440701020453 0ustar mclasenmclasen GskRenderer: GSK 4 Reference Manual

GskRenderer

GskRenderer — Renders a scene

Properties

gboolean realized Read
GdkSurface * surface Read

Types and Values

Object Hierarchy

    GObject
    ╰── GskRenderer

Description

GskRenderer is a class that renders a scene graph defined via a tree of GskRenderNode instances.

Typically you will use a GskRenderer instance to repeatedly call gsk_renderer_render() to update the contents of its associated GdkSurface.

It is necessary to realize a GskRenderer instance using gsk_renderer_realize() before calling gsk_renderer_render(), in order to create the appropriate windowing system resources needed to render the scene.

Functions

gsk_renderer_get_surface ()

GdkSurface *
gsk_renderer_get_surface (GskRenderer *renderer);

Retrieves the GdkSurface set using gsk_renderer_realize(). If the renderer has not been realized yet, NULL will be returned.

Parameters

renderer

a GskRenderer

 

Returns

a GdkSurface.

[transfer none][nullable]


gsk_renderer_realize ()

gboolean
gsk_renderer_realize (GskRenderer *renderer,
                      GdkSurface *surface,
                      GError **error);

Creates the resources needed by the renderer to render the scene graph.

Parameters

renderer

a GskRenderer

 

surface

the GdkSurface renderer will be used on

 

error

return location for an error

 

gsk_renderer_unrealize ()

void
gsk_renderer_unrealize (GskRenderer *renderer);

Releases all the resources created by gsk_renderer_realize().

Parameters

renderer

a GskRenderer

 

gsk_renderer_is_realized ()

gboolean
gsk_renderer_is_realized (GskRenderer *renderer);

Checks whether the renderer is realized or not.

Parameters

renderer

a GskRenderer

 

Returns

TRUE if the GskRenderer was realized, and FALSE otherwise


gsk_renderer_render ()

void
gsk_renderer_render (GskRenderer *renderer,
                     GskRenderNode *root,
                     const cairo_region_t *region);

Renders the scene graph, described by a tree of GskRenderNode instances, ensuring that the given region gets redrawn.

Renderers must ensure that changes of the contents given by the root node as well as the area given by region are redrawn. They are however free to not redraw any pixel outside of region if they can guarantee that it didn't change.

The renderer will acquire a reference on the GskRenderNode tree while the rendering is in progress.

Parameters

renderer

a GskRenderer

 

root

a GskRenderNode

 

region

the cairo_region_t that must be redrawn or NULL for the whole window.

[nullable]

gsk_renderer_render_texture ()

GdkTexture *
gsk_renderer_render_texture (GskRenderer *renderer,
                             GskRenderNode *root,
                             const graphene_rect_t *viewport);

Renders the scene graph, described by a tree of GskRenderNode instances, to a GdkTexture.

The renderer will acquire a reference on the GskRenderNode tree while the rendering is in progress.

If you want to apply any transformations to root , you should put it into a transform node and pass that node instead.

Parameters

renderer

a realized GskRenderer

 

root

a GskRenderNode

 

viewport

the section to draw or NULL to use root 's bounds.

[allow-none]

Returns

a GdkTexture with the rendered contents of root .

[transfer full]


gsk_renderer_new_for_surface ()

GskRenderer *
gsk_renderer_new_for_surface (GdkSurface *surface);

Creates an appropriate GskRenderer instance for the given surface .

If the GSK_RENDERER environment variable is set, GSK will try that renderer first, before trying the backend-specific default. The ultimate fallback is the cairo renderer.

The renderer will be realized before it is returned.

Parameters

surface

a GdkSurface

 

Returns

a GskRenderer.

[transfer full][nullable]


gsk_gl_renderer_new ()

GskRenderer *
gsk_gl_renderer_new (void);

Creates a new GskRenderer using OpenGL. This is the default renderer used by GTK.

Returns

a new GL renderer


gsk_cairo_renderer_new ()

GskRenderer *
gsk_cairo_renderer_new (void);

Creates a new Cairo renderer.

The Cairo renderer is the fallback renderer drawing in ways similar to how GTK 3 drew its content. Its primary use is as comparison tool.

The Cairo renderer is incomplete. It cannot render 3D transformed content and will instead render an error marker. Its usage should be avoided.

Returns

a new Cairo renderer.


gsk_vulkan_renderer_new ()

GskRenderer *
gsk_vulkan_renderer_new (void);

Creates a new Vulkan renderer.

The Vulkan renderer is a renderer that uses the Vulkan library for rendering.

This function is only available when GTK was compiled with Vulkan support.

Returns

a new Vulkan renderer


gsk_broadway_renderer_new ()

GskRenderer *
gsk_broadway_renderer_new (void);

Creates a new Broadway renderer.

The Broadway renderer is the default renderer for the broadway backend. It will only work with broadway surfaces, otherwise it will fail the call to gsk_renderer_realize().

This function is only available when GTK was compiled with Broadway support.

Returns

a new Broadway renderer.

Types and Values

GskRenderer

typedef struct _GskRenderer GskRenderer;

Base type for the object managing the rendering pipeline for a GdkSurface.

Property Details

The “realized” property

  “realized”                 gboolean

The renderer has been associated with a surface.

Owner: GskRenderer

Flags: Read

Default value: FALSE


The “surface” property

  “surface”                  GdkSurface *

The surface associated to the renderer.

Owner: GskRenderer

Flags: Read

docs/reference/gsk/html/annotation-glossary.html0000664000175000017500000001105613766440701022240 0ustar mclasenmclasen Annotation Glossary: GSK 4 Reference Manual

Annotation Glossary

A

allow-none

NULL is OK, both for passing and for returning.

array

Parameter points to an array of items.

C

closure

This parameter is a 'user_data', for callbacks; many bindings can pass NULL here.

N

nullable

NULL may be passed as the value in, out, in-out; or as a return value.

O

optional

NULL may be passed instead of a pointer to a location.

out

Parameter for returning results. Default is transfer full.

out caller-allocates

Out parameter, where caller must allocate storage.

S

scope call

The callback is valid only during the call to the method.

skip

Exposed in C code, not necessarily available in other languages.

T

transfer full

Free data after the code is done.

transfer none

Don't free data after the code is done.

type

Override the parsed C type with given type.

docs/reference/gsk/html/api-index-full.html0000664000175000017500000016667013766440701021060 0ustar mclasenmclasen Index of all symbols: GSK 4 Reference Manual

Index of all symbols

B

GskBlendMode, enum in GskRenderNode
GskBlendNode, struct in GskRenderNode
gsk_blend_node_get_blend_mode, function in GskRenderNode
gsk_blend_node_get_bottom_child, function in GskRenderNode
gsk_blend_node_get_top_child, function in GskRenderNode
gsk_blend_node_new, function in GskRenderNode
GskBlurNode, struct in GskRenderNode
gsk_blur_node_get_child, function in GskRenderNode
gsk_blur_node_get_radius, function in GskRenderNode
gsk_blur_node_new, function in GskRenderNode
GskBorderNode, struct in GskRenderNode
gsk_border_node_get_colors, function in GskRenderNode
gsk_border_node_get_outline, function in GskRenderNode
gsk_border_node_get_widths, function in GskRenderNode
gsk_border_node_new, function in GskRenderNode
gsk_broadway_renderer_new, function in GskRenderer

C

GskCairoNode, struct in GskRenderNode
gsk_cairo_node_get_draw_context, function in GskRenderNode
gsk_cairo_node_get_surface, function in GskRenderNode
gsk_cairo_node_new, function in GskRenderNode
gsk_cairo_renderer_new, function in GskRenderer
GskClipNode, struct in GskRenderNode
gsk_clip_node_get_child, function in GskRenderNode
gsk_clip_node_get_clip, function in GskRenderNode
gsk_clip_node_new, function in GskRenderNode
GskColorMatrixNode, struct in GskRenderNode
GskColorNode, struct in GskRenderNode
GskColorStop, struct in GskRenderNode
gsk_color_matrix_node_get_child, function in GskRenderNode
gsk_color_matrix_node_get_color_matrix, function in GskRenderNode
gsk_color_matrix_node_get_color_offset, function in GskRenderNode
gsk_color_matrix_node_new, function in GskRenderNode
gsk_color_node_get_color, function in GskRenderNode
gsk_color_node_new, function in GskRenderNode
GskConicGradientNode, struct in GskRenderNode
gsk_conic_gradient_node_get_center, function in GskRenderNode
gsk_conic_gradient_node_get_color_stops, function in GskRenderNode
gsk_conic_gradient_node_get_n_color_stops, function in GskRenderNode
gsk_conic_gradient_node_get_rotation, function in GskRenderNode
gsk_conic_gradient_node_new, function in GskRenderNode
GskContainerNode, struct in GskRenderNode
gsk_container_node_get_child, function in GskRenderNode
gsk_container_node_get_n_children, function in GskRenderNode
gsk_container_node_new, function in GskRenderNode
GskCorner, enum in GskRoundedRect
GskCrossFadeNode, struct in GskRenderNode
gsk_cross_fade_node_get_end_child, function in GskRenderNode
gsk_cross_fade_node_get_progress, function in GskRenderNode
gsk_cross_fade_node_get_start_child, function in GskRenderNode
gsk_cross_fade_node_new, function in GskRenderNode

D

GskDebugNode, struct in GskRenderNode
gsk_debug_node_get_child, function in GskRenderNode
gsk_debug_node_get_message, function in GskRenderNode
gsk_debug_node_new, function in GskRenderNode

G

GskGLShader, struct in GskGLShader
GskGLShader:resource, object property in GskGLShader
GskGLShader:source, object property in GskGLShader
GskGLShaderNode, struct in GskRenderNode
GskGLUniformType, enum in GskGLShader
gsk_gl_renderer_new, function in GskRenderer
gsk_gl_shader_compile, function in GskGLShader
gsk_gl_shader_find_uniform_by_name, function in GskGLShader
gsk_gl_shader_format_args, function in GskGLShader
gsk_gl_shader_format_args_va, function in GskGLShader
gsk_gl_shader_get_args_size, function in GskGLShader
gsk_gl_shader_get_arg_bool, function in GskGLShader
gsk_gl_shader_get_arg_float, function in GskGLShader
gsk_gl_shader_get_arg_int, function in GskGLShader
gsk_gl_shader_get_arg_uint, function in GskGLShader
gsk_gl_shader_get_arg_vec2, function in GskGLShader
gsk_gl_shader_get_arg_vec3, function in GskGLShader
gsk_gl_shader_get_arg_vec4, function in GskGLShader
gsk_gl_shader_get_n_textures, function in GskGLShader
gsk_gl_shader_get_n_uniforms, function in GskGLShader
gsk_gl_shader_get_resource, function in GskGLShader
gsk_gl_shader_get_source, function in GskGLShader
gsk_gl_shader_get_uniform_name, function in GskGLShader
gsk_gl_shader_get_uniform_offset, function in GskGLShader
gsk_gl_shader_get_uniform_type, function in GskGLShader
gsk_gl_shader_new_from_bytes, function in GskGLShader
gsk_gl_shader_new_from_resource, function in GskGLShader
gsk_gl_shader_node_get_args, function in GskRenderNode
gsk_gl_shader_node_get_child, function in GskRenderNode
gsk_gl_shader_node_get_n_children, function in GskRenderNode
gsk_gl_shader_node_get_shader, function in GskRenderNode
gsk_gl_shader_node_new, function in GskRenderNode

I

GskInsetShadowNode, struct in GskRenderNode
gsk_inset_shadow_node_get_blur_radius, function in GskRenderNode
gsk_inset_shadow_node_get_color, function in GskRenderNode
gsk_inset_shadow_node_get_dx, function in GskRenderNode
gsk_inset_shadow_node_get_dy, function in GskRenderNode
gsk_inset_shadow_node_get_outline, function in GskRenderNode
gsk_inset_shadow_node_get_spread, function in GskRenderNode
gsk_inset_shadow_node_new, function in GskRenderNode

L

GskLinearGradientNode, struct in GskRenderNode
gsk_linear_gradient_node_get_color_stops, function in GskRenderNode
gsk_linear_gradient_node_get_end, function in GskRenderNode
gsk_linear_gradient_node_get_n_color_stops, function in GskRenderNode
gsk_linear_gradient_node_get_start, function in GskRenderNode
gsk_linear_gradient_node_new, function in GskRenderNode

O

GskOpacityNode, struct in GskRenderNode
gsk_opacity_node_get_child, function in GskRenderNode
gsk_opacity_node_get_opacity, function in GskRenderNode
gsk_opacity_node_new, function in GskRenderNode
GskOutsetShadowNode, struct in GskRenderNode
gsk_outset_shadow_node_get_blur_radius, function in GskRenderNode
gsk_outset_shadow_node_get_color, function in GskRenderNode
gsk_outset_shadow_node_get_dx, function in GskRenderNode
gsk_outset_shadow_node_get_dy, function in GskRenderNode
gsk_outset_shadow_node_get_outline, function in GskRenderNode
gsk_outset_shadow_node_get_spread, function in GskRenderNode
gsk_outset_shadow_node_new, function in GskRenderNode

P

GskParseErrorFunc, user_function in GskRenderNode
GskParseLocation, struct in GskRenderNode

R

GskRadialGradientNode, struct in GskRenderNode
gsk_radial_gradient_node_get_center, function in GskRenderNode
gsk_radial_gradient_node_get_color_stops, function in GskRenderNode
gsk_radial_gradient_node_get_end, function in GskRenderNode
gsk_radial_gradient_node_get_hradius, function in GskRenderNode
gsk_radial_gradient_node_get_n_color_stops, function in GskRenderNode
gsk_radial_gradient_node_get_start, function in GskRenderNode
gsk_radial_gradient_node_get_vradius, function in GskRenderNode
gsk_radial_gradient_node_new, function in GskRenderNode
GskRenderer, struct in GskRenderer
GskRenderer:realized, object property in GskRenderer
GskRenderer:surface, object property in GskRenderer
gsk_renderer_get_surface, function in GskRenderer
gsk_renderer_is_realized, function in GskRenderer
gsk_renderer_new_for_surface, function in GskRenderer
gsk_renderer_realize, function in GskRenderer
gsk_renderer_render, function in GskRenderer
gsk_renderer_render_texture, function in GskRenderer
gsk_renderer_unrealize, function in GskRenderer
GskRenderNode, struct in GskRenderNode
GskRenderNodeType, enum in GskRenderNode
gsk_render_node_deserialize, function in GskRenderNode
gsk_render_node_draw, function in GskRenderNode
gsk_render_node_get_bounds, function in GskRenderNode
gsk_render_node_get_node_type, function in GskRenderNode
gsk_render_node_ref, function in GskRenderNode
gsk_render_node_serialize, function in GskRenderNode
gsk_render_node_unref, function in GskRenderNode
gsk_render_node_write_to_file, function in GskRenderNode
GskRepeatingLinearGradientNode, struct in GskRenderNode
GskRepeatingRadialGradientNode, struct in GskRenderNode
gsk_repeating_linear_gradient_node_new, function in GskRenderNode
gsk_repeating_radial_gradient_node_new, function in GskRenderNode
GskRepeatNode, struct in GskRenderNode
gsk_repeat_node_get_child, function in GskRenderNode
gsk_repeat_node_get_child_bounds, function in GskRenderNode
gsk_repeat_node_new, function in GskRenderNode
GskRoundedClipNode, struct in GskRenderNode
GskRoundedRect, struct in GskRoundedRect
gsk_rounded_clip_node_get_child, function in GskRenderNode
gsk_rounded_clip_node_get_clip, function in GskRenderNode
gsk_rounded_clip_node_new, function in GskRenderNode
gsk_rounded_rect_contains_point, function in GskRoundedRect
gsk_rounded_rect_contains_rect, function in GskRoundedRect
GSK_ROUNDED_RECT_INIT, macro in GskRoundedRect
gsk_rounded_rect_init, function in GskRoundedRect
gsk_rounded_rect_init_copy, function in GskRoundedRect
gsk_rounded_rect_init_from_rect, function in GskRoundedRect
gsk_rounded_rect_intersects_rect, function in GskRoundedRect
gsk_rounded_rect_is_rectilinear, function in GskRoundedRect
gsk_rounded_rect_normalize, function in GskRoundedRect
gsk_rounded_rect_offset, function in GskRoundedRect
gsk_rounded_rect_shrink, function in GskRoundedRect

S

GskScalingFilter, enum in GskRenderNode
GskSerializationError, enum in GskRenderNode
GskShaderArgsBuilder, struct in GskGLShader
gsk_shader_args_builder_free_to_args, function in GskGLShader
gsk_shader_args_builder_new, function in GskGLShader
gsk_shader_args_builder_ref, function in GskGLShader
gsk_shader_args_builder_set_bool, function in GskGLShader
gsk_shader_args_builder_set_float, function in GskGLShader
gsk_shader_args_builder_set_int, function in GskGLShader
gsk_shader_args_builder_set_uint, function in GskGLShader
gsk_shader_args_builder_set_vec2, function in GskGLShader
gsk_shader_args_builder_set_vec3, function in GskGLShader
gsk_shader_args_builder_set_vec4, function in GskGLShader
gsk_shader_args_builder_to_args, function in GskGLShader
gsk_shader_args_builder_unref, function in GskGLShader
GskShadow, struct in GskRenderNode
GskShadowNode, struct in GskRenderNode
gsk_shadow_node_get_child, function in GskRenderNode
gsk_shadow_node_get_n_shadows, function in GskRenderNode
gsk_shadow_node_get_shadow, function in GskRenderNode
gsk_shadow_node_new, function in GskRenderNode

T

GskTextNode, struct in GskRenderNode
GskTextureNode, struct in GskRenderNode
gsk_texture_node_get_texture, function in GskRenderNode
gsk_texture_node_new, function in GskRenderNode
gsk_text_node_get_color, function in GskRenderNode
gsk_text_node_get_font, function in GskRenderNode
gsk_text_node_get_glyphs, function in GskRenderNode
gsk_text_node_get_num_glyphs, function in GskRenderNode
gsk_text_node_get_offset, function in GskRenderNode
gsk_text_node_has_color_glyphs, function in GskRenderNode
gsk_text_node_new, function in GskRenderNode
GskTransform, struct in GskTransform
GskTransformCategory, enum in GskTransform
GskTransformNode, struct in GskRenderNode
gsk_transform_equal, function in GskTransform
gsk_transform_get_category, function in GskTransform
gsk_transform_invert, function in GskTransform
gsk_transform_matrix, function in GskTransform
gsk_transform_node_get_child, function in GskRenderNode
gsk_transform_node_get_transform, function in GskRenderNode
gsk_transform_node_new, function in GskRenderNode
gsk_transform_parse, function in GskTransform
gsk_transform_perspective, function in GskTransform
gsk_transform_print, function in GskTransform
gsk_transform_ref, function in GskTransform
gsk_transform_rotate, function in GskTransform
gsk_transform_rotate_3d, function in GskTransform
gsk_transform_scale, function in GskTransform
gsk_transform_scale_3d, function in GskTransform
gsk_transform_to_2d, function in GskTransform
gsk_transform_to_affine, function in GskTransform
gsk_transform_to_matrix, function in GskTransform
gsk_transform_to_string, function in GskTransform
gsk_transform_to_translate, function in GskTransform
gsk_transform_transform, function in GskTransform
gsk_transform_transform_bounds, function in GskTransform
gsk_transform_transform_point, function in GskTransform
gsk_transform_translate, function in GskTransform
gsk_transform_translate_3d, function in GskTransform
gsk_transform_unref, function in GskTransform

V

gsk_vulkan_renderer_new, function in GskRenderer
docs/reference/gsk/html/gsk4-GskRoundedRect.html0000664000175000017500000010745113766440701021763 0ustar mclasenmclasen GskRoundedRect: GSK 4 Reference Manual

GskRoundedRect

GskRoundedRect — A rounded rectangle

Types and Values

Description

GskRoundedRect defines a rectangle with rounded corners, as is commonly used in drawing.

Operations on a GskRoundedRect will normalize the rectangle, to ensure that the bounds are normalized and that the corner sizes don't exceed the size of the rectangle. The algorithm used for normalizing corner sizes is described in the CSS specification.

Functions

GSK_ROUNDED_RECT_INIT()

#define             GSK_ROUNDED_RECT_INIT(_x,_y,_w,_h)

Initializes a GskRoundedRect when declaring it. All corner sizes will be initialized to 0.

Parameters

_x

the X coordinate of the origin

 

_y

the Y coordinate of the origin

 

_w

the width

 

_h

the height

 

gsk_rounded_rect_init ()

GskRoundedRect *
gsk_rounded_rect_init (GskRoundedRect *self,
                       const graphene_rect_t *bounds,
                       const graphene_size_t *top_left,
                       const graphene_size_t *top_right,
                       const graphene_size_t *bottom_right,
                       const graphene_size_t *bottom_left);

Initializes the given GskRoundedRect with the given values.

This function will implicitly normalize the GskRoundedRect before returning.

Parameters

self

The GskRoundedRect to initialize

 

bounds

a graphene_rect_t describing the bounds

 

top_left

the rounding radius of the top left corner

 

top_right

the rounding radius of the top right corner

 

bottom_right

the rounding radius of the bottom right corner

 

bottom_left

the rounding radius of the bottom left corner

 

Returns

the initialized rectangle.

[transfer none]


gsk_rounded_rect_init_copy ()

GskRoundedRect *
gsk_rounded_rect_init_copy (GskRoundedRect *self,
                            const GskRoundedRect *src);

Initializes self using the given src rectangle.

This function will not normalize the GskRoundedRect, so make sure the source is normalized.

Parameters

self

a GskRoundedRect

 

src

a GskRoundedRect

 

Returns

the initialized rectangle.

[transfer none]


gsk_rounded_rect_init_from_rect ()

GskRoundedRect *
gsk_rounded_rect_init_from_rect (GskRoundedRect *self,
                                 const graphene_rect_t *bounds,
                                 float radius);

Initializes self to the given bounds and sets the radius of all four corners to radius .

Parameters

self

a GskRoundedRect

 

bounds

a graphene_rect_t

 

radius

the border radius

 

Returns

the initialized rectangle.

[transfer none]


gsk_rounded_rect_normalize ()

GskRoundedRect *
gsk_rounded_rect_normalize (GskRoundedRect *self);

Normalizes the passed rectangle.

this function will ensure that the bounds of the rectangle are normalized and ensure that the corner values are positive and the corners do not overlap.

Parameters

self

a GskRoundedRect

 

Returns

the normalized rectangle.

[transfer none]


gsk_rounded_rect_offset ()

GskRoundedRect *
gsk_rounded_rect_offset (GskRoundedRect *self,
                         float dx,
                         float dy);

Offsets the bound's origin by dx and dy .

The size and corners of the rectangle are unchanged.

Parameters

self

a GskRoundedRect

 

dx

the horizontal offset

 

dy

the vertical offset

 

Returns

the offset rectangle.

[transfer none]


gsk_rounded_rect_shrink ()

GskRoundedRect *
gsk_rounded_rect_shrink (GskRoundedRect *self,
                         float top,
                         float right,
                         float bottom,
                         float left);

Shrinks (or grows) the given rectangle by moving the 4 sides according to the offsets given. The corner radii will be changed in a way that tries to keep the center of the corner circle intact. This emulates CSS behavior.

This function also works for growing rectangles if you pass negative values for the top , right , bottom or left .

Parameters

self

The GskRoundedRect to shrink or grow

 

top

How far to move the top side downwards

 

right

How far to move the right side to the left

 

bottom

How far to move the bottom side upwards

 

left

How far to move the left side to the right

 

Returns

the resized GskRoundedRect.

[transfer none]


gsk_rounded_rect_is_rectilinear ()

gboolean
gsk_rounded_rect_is_rectilinear (const GskRoundedRect *self);

Checks if all corners of self are right angles and the rectangle covers all of its bounds.

This information can be used to decide if gsk_clip_node_new() or gsk_rounded_clip_node_new() should be called.

Parameters

self

the GskRoundedRect to check

 

Returns

TRUE if the rectangle is rectilinear


gsk_rounded_rect_contains_point ()

gboolean
gsk_rounded_rect_contains_point (const GskRoundedRect *self,
                                 const graphene_point_t *point);

Checks if the given point is inside the rounded rectangle. This function returns FALSE if the point is in the rounded corner areas.

Parameters

self

a GskRoundedRect

 

point

the point to check

 

Returns

TRUE if the point is inside the rounded rectangle


gsk_rounded_rect_contains_rect ()

gboolean
gsk_rounded_rect_contains_rect (const GskRoundedRect *self,
                                const graphene_rect_t *rect);

Checks if the given rect is contained inside the rounded rectangle. This function returns FALSE if rect extends into one of the rounded corner areas.

Parameters

self

a GskRoundedRect

 

rect

the rectangle to check

 

Returns

TRUE if the rect is fully contained inside the rounded rectangle


gsk_rounded_rect_intersects_rect ()

gboolean
gsk_rounded_rect_intersects_rect (const GskRoundedRect *self,
                                  const graphene_rect_t *rect);

Checks if part of the given rect is contained inside the rounded rectangle. This function returns FALSE if rect only extends into one of the rounded corner areas but not into the rounded rectangle itself.

Parameters

self

a GskRoundedRect

 

rect

the rectangle to check

 

Returns

TRUE if the rect intersects with the rounded rectangle

Types and Values

enum GskCorner

The corner indices used by GskRoundedRect.

Members

GSK_CORNER_TOP_LEFT

The top left corner

 

GSK_CORNER_TOP_RIGHT

The top right corner

 

GSK_CORNER_BOTTOM_RIGHT

The bottom right corner

 

GSK_CORNER_BOTTOM_LEFT

The bottom left corner

 

struct GskRoundedRect

struct GskRoundedRect {
  graphene_rect_t bounds;

  graphene_size_t corner[4];
};

A rectangular region with rounded corners.

Application code should normalize rectangles using gsk_rounded_rect_normalize(); this function will ensure that the bounds of the rectangle are normalized and ensure that the corner values are positive and the corners do not overlap. All functions taking a GskRoundedRect as an argument will internally operate on a normalized copy; all functions returning a GskRoundedRect will always return a normalized one.

Members

graphene_rect_t bounds;

the bounds of the rectangle

 

graphene_size_t corner[4];

the size of the 4 rounded corners

 
docs/reference/gsk/html/gsk4-GskTransform.html0000664000175000017500000020167513766440701021523 0ustar mclasenmclasen GskTransform: GSK 4 Reference Manual

GskTransform

GskTransform — A description for transform operations

Types and Values

Description

GskTransform is an object to describe transform matrices. Unlike graphene_matrix_t, GskTransform retains the steps in how a transform was constructed, and allows inspecting them. It is modeled after the way CSS describes transforms.

GskTransform objects are immutable and cannot be changed after creation. This means code can safely expose them as properties of objects without having to worry about others changing them.

Functions

gsk_transform_ref ()

GskTransform *
gsk_transform_ref (GskTransform *self);

Acquires a reference on the given GskTransform.

Parameters

self

a GskTransform.

[allow-none]

Returns

the GskTransform with an additional reference.

[transfer none]


gsk_transform_unref ()

void
gsk_transform_unref (GskTransform *self);

Releases a reference on the given GskTransform.

If the reference was the last, the resources associated to the self are freed.

Parameters

self

a GskTransform.

[allow-none]

gsk_transform_get_category ()

GskTransformCategory
gsk_transform_get_category (GskTransform *self);

Returns the category this transform belongs to.

Parameters

self

A GskTransform.

[allow-none]

Returns

The category of the transform


gsk_transform_print ()

void
gsk_transform_print (GskTransform *self,
                     GString *string);

Converts self into a human-readable string representation suitable for printing that can later be parsed with gsk_transform_parse().

Parameters

self

a GskTransform.

[allow-none]

string

The string to print into

 

gsk_transform_to_string ()

char *
gsk_transform_to_string (GskTransform *self);

Converts a matrix into a string that is suitable for printing and can later be parsed with gsk_transform_parse().

This is a wrapper around gsk_transform_print(), see that function for details.

Parameters

self

a GskTransform.

[allow-none]

Returns

A new string for self


gsk_transform_parse ()

gboolean
gsk_transform_parse (const char *string,
                     GskTransform **out_transform);

Parses the given string into a transform and puts it in out_transform . Strings printed via gsk_transform_to_string() can be read in again successfully using this function.

If string does not describe a valid transform, FALSE is returned and NULL is put in out_transform .

Parameters

string

the string to parse

 

out_transform

The location to put the transform in.

[out]

Returns

TRUE if string described a valid transform.


gsk_transform_to_matrix ()

void
gsk_transform_to_matrix (GskTransform *self,
                         graphene_matrix_t *out_matrix);

Computes the actual value of self and stores it in out_matrix . The previous value of out_matrix will be ignored.

Parameters

self

a GskTransform.

[allow-none]

out_matrix

The matrix to set.

[out caller-allocates]

gsk_transform_to_2d ()

void
gsk_transform_to_2d (GskTransform *self,
                     float *out_xx,
                     float *out_yx,
                     float *out_xy,
                     float *out_yy,
                     float *out_dx,
                     float *out_dy);

Converts a GskTransform to a 2D transformation matrix. self must be a 2D transformation. If you are not sure, use gsk_transform_get_category() >= GSK_TRANSFORM_CATEGORY_2D to check.

The returned values have the following layout:

1
2
3
| xx yx |   |  a  b  0 |
| xy yy | = |  c  d  0 |
| dx dy |   | tx ty  1 |

This function can be used to convert between a GskTransform and a matrix type from other 2D drawing libraries, in particular Cairo.

Parameters

self

a 2D GskTransform

 

out_xx

return location for the xx member.

[out]

out_yx

return location for the yx member.

[out]

out_xy

return location for the xy member.

[out]

out_yy

return location for the yy member.

[out]

out_dx

return location for the x0 member.

[out]

out_dy

return location for the y0 member.

[out]

gsk_transform_to_affine ()

void
gsk_transform_to_affine (GskTransform *self,
                         float *out_scale_x,
                         float *out_scale_y,
                         float *out_dx,
                         float *out_dy);

Converts a GskTransform to 2D affine transformation factors. self must be a 2D transformation. If you are not sure, use gsk_transform_get_category() >= GSK_TRANSFORM_CATEGORY_2D_AFFINE to check.

Parameters

self

a GskTransform

 

out_scale_x

return location for the scale factor in the x direction.

[out]

out_scale_y

return location for the scale factor in the y direction.

[out]

out_dx

return location for the translation in the x direction.

[out]

out_dy

return location for the translation in the y direction.

[out]

gsk_transform_to_translate ()

void
gsk_transform_to_translate (GskTransform *self,
                            float *out_dx,
                            float *out_dy);

Converts a GskTransform to a translation operation. self must be a 2D transformation. If you are not sure, use gsk_transform_get_category() >= GSK_TRANSFORM_CATEGORY_2D_TRANSLATE to check.

Parameters

self

a GskTransform

 

out_dx

return location for the translation in the x direction.

[out]

out_dy

return location for the translation in the y direction.

[out]

gsk_transform_transform ()

GskTransform *
gsk_transform_transform (GskTransform *next,
                         GskTransform *other);

Applies all the operations from other to next .

Parameters

next

Transform to apply other to.

[allow-none][transfer full]

other

Transform to apply.

[allow-none]

Returns

The new transform


gsk_transform_invert ()

GskTransform *
gsk_transform_invert (GskTransform *self);

Inverts the given transform.

If self is not invertible, NULL is returned. Note that inverting NULL also returns NULL, which is the correct inverse of NULL. If you need to differentiate between those cases, you should check self is not NULL before calling this function.

Parameters

self

Transform to invert.

[allow-none][transfer full]

Returns

The inverted transform or NULL if the transform cannot be inverted.

[nullable]


gsk_transform_matrix ()

GskTransform *
gsk_transform_matrix (GskTransform *next,
                      const graphene_matrix_t *matrix);

Multiplies next with the given matrix .

Parameters

next

the next transform.

[allow-none][transfer full]

matrix

the matrix to multiply next with

 

Returns

The new transform


gsk_transform_translate ()

GskTransform *
gsk_transform_translate (GskTransform *next,
                         const graphene_point_t *point);

Translates next in 2dimensional space by point .

Parameters

next

the next transform.

[allow-none][transfer full]

point

the point to translate the transform by

 

Returns

The new transform


gsk_transform_translate_3d ()

GskTransform *
gsk_transform_translate_3d (GskTransform *next,
                            const graphene_point3d_t *point);

Translates next by point .

Parameters

next

the next transform.

[allow-none][transfer full]

point

the point to translate the transform by

 

Returns

The new transform


gsk_transform_rotate ()

GskTransform *
gsk_transform_rotate (GskTransform *next,
                      float angle);

Rotates next angle degrees in 2D - or in 3Dspeak, around the z axis.

Parameters

next

the next transform.

[allow-none][transfer full]

angle

the rotation angle, in degrees (clockwise)

 

Returns

The new transform


gsk_transform_rotate_3d ()

GskTransform *
gsk_transform_rotate_3d (GskTransform *next,
                         float angle,
                         const graphene_vec3_t *axis);

Rotates next angle degrees around axis .

For a rotation in 2D space, use gsk_transform_rotate().

Parameters

next

the next transform.

[allow-none][transfer full]

angle

the rotation angle, in degrees (clockwise)

 

axis

The rotation axis

 

Returns

The new transform


gsk_transform_scale ()

GskTransform *
gsk_transform_scale (GskTransform *next,
                     float factor_x,
                     float factor_y);

Scales next in 2-dimensional space by the given factors. Use gsk_transform_scale_3d() to scale in all 3 dimensions.

Parameters

next

the next transform.

[allow-none][transfer full]

factor_x

scaling factor on the X axis

 

factor_y

scaling factor on the Y axis

 

Returns

The new transform


gsk_transform_scale_3d ()

GskTransform *
gsk_transform_scale_3d (GskTransform *next,
                        float factor_x,
                        float factor_y,
                        float factor_z);

Scales next by the given factors.

Parameters

next

the next transform.

[allow-none][transfer full]

factor_x

scaling factor on the X axis

 

factor_y

scaling factor on the Y axis

 

factor_z

scaling factor on the Z axis

 

Returns

The new transform


gsk_transform_perspective ()

GskTransform *
gsk_transform_perspective (GskTransform *next,
                           float depth);

Applies a perspective projection transform. This transform scales points in X and Y based on their Z value, scaling points with positive Z values away from the origin, and those with negative Z values towards the origin. Points on the z=0 plane are unchanged.

Parameters

next

the next transform.

[allow-none][transfer full]

depth

distance of the z=0 plane. Lower values give a more flattened pyramid and therefore a more pronounced perspective effect.

 

Returns

The new transform


gsk_transform_equal ()

gboolean
gsk_transform_equal (GskTransform *first,
                     GskTransform *second);

Checks two transforms for equality.

Parameters

first

the first transform

 

second

the second transform

 

Returns

TRUE if the two transforms perform the same operation.


gsk_transform_transform_bounds ()

void
gsk_transform_transform_bounds (GskTransform *self,
                                const graphene_rect_t *rect,
                                graphene_rect_t *out_rect);

Transforms a graphene_rect_t using the given transform self . The result is the bounding box containing the coplanar quad.

Parameters

self

a GskTransform

 

rect

a graphene_rect_t

 

out_rect

return location for the bounds of the transformed rectangle.

[out caller-allocates]

gsk_transform_transform_point ()

void
gsk_transform_transform_point (GskTransform *self,
                               const graphene_point_t *point,
                               graphene_point_t *out_point);

Transforms a graphene_point_t using the given transform self .

Parameters

self

a GskTransform

 

point

a graphene_point_t

 

out_point

return location for the transformed point.

[out caller-allocates]

Types and Values

GskTransform

typedef struct _GskTransform GskTransform;

The GskTransform structure contains only private data.


enum GskTransformCategory

The categories of matrices relevant for GSK and GTK. Note that any category includes matrices of all later categories. So if you want to for example check if a matrix is a 2D matrix, category &gt;= GSK_TRANSFORM_CATEGORY_2D is the way to do this.

Also keep in mind that rounding errors may cause matrices to not conform to their categories. Otherwise, matrix operations done via mutliplication will not worsen categories. So for the matrix multiplication C = A * B, category(C) = MIN (category(A), category(B)).

Members

GSK_TRANSFORM_CATEGORY_UNKNOWN

The category of the matrix has not been determined.

 

GSK_TRANSFORM_CATEGORY_ANY

Analyzing the matrix concluded that it does not fit in any other category.

 

GSK_TRANSFORM_CATEGORY_3D

The matrix is a 3D matrix. This means that the w column (the last column) has the values (0, 0, 0, 1).

 

GSK_TRANSFORM_CATEGORY_2D

The matrix is a 2D matrix. This is equivalent to graphene_matrix_is_2d() returning TRUE. In particular, this means that Cairo can deal with the matrix.

 

GSK_TRANSFORM_CATEGORY_2D_AFFINE

The matrix is a combination of 2D scale and 2D translation operations. In particular, this means that any rectangle can be transformed exactly using this matrix.

 

GSK_TRANSFORM_CATEGORY_2D_TRANSLATE

The matrix is a 2D translation.

 

GSK_TRANSFORM_CATEGORY_IDENTITY

The matrix is the identity matrix.

 
docs/reference/gsk/html/index.html0000664000175000017500000000442713766440701017340 0ustar mclasenmclasen GSK 4 Reference Manual: GSK 4 Reference Manual

This document is for the GSK 4 library, version 4.0.0 The latest versions can be found online at https://developer.gnome.org/gsk4/.


I. API Reference
GskRenderer — Renders a scene
GskRenderNode — Simple scene graph element
GskRoundedRect — A rounded rectangle
GskTransform — A description for transform operations
GskGLShader — Fragment shaders for GSK
Index of all symbols
Annotation Glossary
docs/reference/gsk/html/reference.html0000664000175000017500000000460513766440701020165 0ustar mclasenmclasen API Reference: GSK 4 Reference Manual

API Reference


Table of Contents

GskRenderer — Renders a scene
GskRenderNode — Simple scene graph element
GskRoundedRect — A rounded rectangle
GskTransform — A description for transform operations
GskGLShader — Fragment shaders for GSK
docs/reference/gsk/gsk4-decl-list.txt0000664000175000017500000002236313766440674017676 0ustar mclasenmclasen
gsk
gskbroadwayrenderer GskBroadwayRenderer gsk_broadway_renderer_new GSK_BROADWAY_RENDERER GSK_BROADWAY_RENDERER_CLASS GSK_BROADWAY_RENDERER_GET_CLASS GSK_IS_BROADWAY_RENDERER GSK_IS_BROADWAY_RENDERER_CLASS GSK_TYPE_BROADWAY_RENDERER GskBroadwayRenderer GskBroadwayRendererClass gsk_broadway_renderer_get_type
gskcairorenderer GskCairoRenderer gsk_cairo_renderer_new GSK_CAIRO_RENDERER GSK_CAIRO_RENDERER_CLASS GSK_CAIRO_RENDERER_GET_CLASS GSK_IS_CAIRO_RENDERER GSK_IS_CAIRO_RENDERER_CLASS GSK_TYPE_CAIRO_RENDERER GskCairoRenderer GskCairoRendererClass gsk_cairo_renderer_get_type
gskenums GskRenderNodeType GskScalingFilter GskBlendMode GskCorner GskSerializationError GskTransformCategory GskGLUniformType
gskenumtypes GSK_TYPE_RENDER_NODE_TYPE GSK_TYPE_SCALING_FILTER GSK_TYPE_BLEND_MODE GSK_TYPE_CORNER GSK_TYPE_SERIALIZATION_ERROR GSK_TYPE_TRANSFORM_CATEGORY GSK_TYPE_GL_UNIFORM_TYPE
gskglrenderer GskGLRenderer gsk_gl_renderer_new GSK_GL_RENDERER GSK_GL_RENDERER_CLASS GSK_GL_RENDERER_GET_CLASS GSK_IS_GL_RENDERER GSK_IS_GL_RENDERER_CLASS GSK_TYPE_GL_RENDERER GskGLRenderer GskGLRendererClass gsk_gl_renderer_get_type
gskglshader GSK_TYPE_GL_SHADER gsk_gl_shader_new_from_bytes gsk_gl_shader_new_from_resource gsk_gl_shader_compile gsk_gl_shader_get_source gsk_gl_shader_get_resource gsk_gl_shader_get_n_textures gsk_gl_shader_get_n_uniforms gsk_gl_shader_get_uniform_name gsk_gl_shader_find_uniform_by_name gsk_gl_shader_get_uniform_type gsk_gl_shader_get_uniform_offset gsk_gl_shader_get_args_size gsk_gl_shader_format_args_va gsk_gl_shader_format_args gsk_gl_shader_get_arg_float gsk_gl_shader_get_arg_int gsk_gl_shader_get_arg_uint gsk_gl_shader_get_arg_bool gsk_gl_shader_get_arg_vec2 gsk_gl_shader_get_arg_vec3 gsk_gl_shader_get_arg_vec4 gsk_shader_args_builder_new gsk_shader_args_builder_to_args gsk_shader_args_builder_free_to_args gsk_shader_args_builder_ref gsk_shader_args_builder_unref gsk_shader_args_builder_set_float gsk_shader_args_builder_set_int gsk_shader_args_builder_set_uint gsk_shader_args_builder_set_bool gsk_shader_args_builder_set_vec2 gsk_shader_args_builder_set_vec3 gsk_shader_args_builder_set_vec4 GskGLShader GskShaderArgsBuilder GSK_TYPE_SHADER_ARGS_BUILDER gsk_shader_args_builder_get_type
gskrenderer GskRenderer gsk_renderer_new_for_surface gsk_renderer_get_surface gsk_renderer_realize gsk_renderer_unrealize gsk_renderer_is_realized gsk_renderer_render_texture gsk_renderer_render GSK_IS_RENDERER GSK_RENDERER GSK_TYPE_RENDERER GskRendererClass gsk_renderer_get_type
gskrendernode GSK_SERIALIZATION_ERROR GskColorStop GskShadow GskParseLocation GskParseErrorFunc gsk_serialization_error_quark gsk_render_node_ref gsk_render_node_unref gsk_render_node_get_node_type gsk_render_node_get_bounds gsk_render_node_draw gsk_render_node_serialize gsk_render_node_write_to_file gsk_render_node_deserialize gsk_debug_node_new gsk_debug_node_get_child gsk_debug_node_get_message gsk_color_node_new gsk_color_node_get_color gsk_texture_node_new gsk_texture_node_get_texture gsk_linear_gradient_node_new gsk_linear_gradient_node_get_start gsk_linear_gradient_node_get_end gsk_linear_gradient_node_get_n_color_stops gsk_linear_gradient_node_get_color_stops gsk_repeating_linear_gradient_node_new gsk_conic_gradient_node_new gsk_conic_gradient_node_get_center gsk_conic_gradient_node_get_rotation gsk_conic_gradient_node_get_n_color_stops gsk_conic_gradient_node_get_color_stops gsk_radial_gradient_node_new gsk_radial_gradient_node_get_n_color_stops gsk_radial_gradient_node_get_color_stops gsk_radial_gradient_node_get_center gsk_radial_gradient_node_get_hradius gsk_radial_gradient_node_get_vradius gsk_radial_gradient_node_get_start gsk_radial_gradient_node_get_end gsk_repeating_radial_gradient_node_new gsk_border_node_new gsk_border_node_get_outline gsk_border_node_get_widths gsk_border_node_get_colors gsk_inset_shadow_node_new gsk_inset_shadow_node_get_outline gsk_inset_shadow_node_get_color gsk_inset_shadow_node_get_dx gsk_inset_shadow_node_get_dy gsk_inset_shadow_node_get_spread gsk_inset_shadow_node_get_blur_radius gsk_outset_shadow_node_new gsk_outset_shadow_node_get_outline gsk_outset_shadow_node_get_color gsk_outset_shadow_node_get_dx gsk_outset_shadow_node_get_dy gsk_outset_shadow_node_get_spread gsk_outset_shadow_node_get_blur_radius gsk_cairo_node_new gsk_cairo_node_get_draw_context gsk_cairo_node_get_surface gsk_container_node_new gsk_container_node_get_n_children gsk_container_node_get_child gsk_transform_node_new gsk_transform_node_get_child gsk_transform_node_get_transform gsk_opacity_node_new gsk_opacity_node_get_child gsk_opacity_node_get_opacity gsk_color_matrix_node_new gsk_color_matrix_node_get_child gsk_color_matrix_node_get_color_matrix gsk_color_matrix_node_get_color_offset gsk_repeat_node_new gsk_repeat_node_get_child gsk_repeat_node_get_child_bounds gsk_clip_node_new gsk_clip_node_get_child gsk_clip_node_get_clip gsk_rounded_clip_node_new gsk_rounded_clip_node_get_child gsk_rounded_clip_node_get_clip gsk_shadow_node_new gsk_shadow_node_get_child gsk_shadow_node_get_shadow gsk_shadow_node_get_n_shadows gsk_blend_node_new gsk_blend_node_get_bottom_child gsk_blend_node_get_top_child gsk_blend_node_get_blend_mode gsk_cross_fade_node_new gsk_cross_fade_node_get_start_child gsk_cross_fade_node_get_end_child gsk_cross_fade_node_get_progress gsk_text_node_new gsk_text_node_get_font gsk_text_node_has_color_glyphs gsk_text_node_get_num_glyphs gsk_text_node_get_glyphs gsk_text_node_get_color gsk_text_node_get_offset gsk_blur_node_new gsk_blur_node_get_child gsk_blur_node_get_radius gsk_gl_shader_node_new gsk_gl_shader_node_get_n_children gsk_gl_shader_node_get_child gsk_gl_shader_node_get_args gsk_gl_shader_node_get_shader GskRepeatingLinearGradientNode GskRepeatingRadialGradientNode GskRoundedClipNode GSK_IS_RENDER_NODE GSK_TYPE_BLEND_NODE GSK_TYPE_BLUR_NODE GSK_TYPE_BORDER_NODE GSK_TYPE_CAIRO_NODE GSK_TYPE_CLIP_NODE GSK_TYPE_COLOR_MATRIX_NODE GSK_TYPE_COLOR_NODE GSK_TYPE_CONIC_GRADIENT_NODE GSK_TYPE_CONTAINER_NODE GSK_TYPE_CROSS_FADE_NODE GSK_TYPE_DEBUG_NODE GSK_TYPE_GL_SHADER_NODE GSK_TYPE_INSET_SHADOW_NODE GSK_TYPE_LINEAR_GRADIENT_NODE GSK_TYPE_OPACITY_NODE GSK_TYPE_OUTSET_SHADOW_NODE GSK_TYPE_RADIAL_GRADIENT_NODE GSK_TYPE_RENDER_NODE GSK_TYPE_REPEATING_LINEAR_GRADIENT_NODE GSK_TYPE_REPEATING_RADIAL_GRADIENT_NODE GSK_TYPE_REPEAT_NODE GSK_TYPE_ROUNDED_CLIP_NODE GSK_TYPE_SHADOW_NODE GSK_TYPE_TEXTURE_NODE GSK_TYPE_TEXT_NODE GSK_TYPE_TRANSFORM_NODE GskBlendNode GskBlurNode GskBorderNode GskCairoNode GskClipNode GskColorMatrixNode GskColorNode GskConicGradientNode GskContainerNode GskCrossFadeNode GskDebugNode GskGLShaderNode GskInsetShadowNode GskLinearGradientNode GskOpacityNode GskOutsetShadowNode GskRadialGradientNode GskRenderNode GskRepeatNode GskShadowNode GskTextNode GskTextureNode GskTransformNode gsk_blend_node_get_type gsk_blur_node_get_type gsk_border_node_get_type gsk_cairo_node_get_type gsk_clip_node_get_type gsk_color_matrix_node_get_type gsk_color_node_get_type gsk_conic_gradient_node_get_type gsk_container_node_get_type gsk_cross_fade_node_get_type gsk_debug_node_get_type gsk_gl_shader_node_get_type gsk_inset_shadow_node_get_type gsk_linear_gradient_node_get_type gsk_opacity_node_get_type gsk_outset_shadow_node_get_type gsk_radial_gradient_node_get_type gsk_render_node_get_type gsk_repeat_node_get_type gsk_shadow_node_get_type gsk_text_node_get_type gsk_texture_node_get_type gsk_transform_node_get_type
gskresources
gskroundedrect GSK_ROUNDED_RECT_INIT GskRoundedRect gsk_rounded_rect_init gsk_rounded_rect_init_copy gsk_rounded_rect_init_from_rect gsk_rounded_rect_normalize gsk_rounded_rect_offset gsk_rounded_rect_shrink gsk_rounded_rect_is_rectilinear gsk_rounded_rect_contains_point gsk_rounded_rect_contains_rect gsk_rounded_rect_intersects_rect
gsktransform gsk_transform_ref gsk_transform_unref gsk_transform_print gsk_transform_to_string gsk_transform_parse gsk_transform_to_matrix gsk_transform_to_2d gsk_transform_to_affine gsk_transform_to_translate gsk_transform_get_category gsk_transform_equal gsk_transform_new gsk_transform_transform gsk_transform_invert gsk_transform_matrix gsk_transform_translate gsk_transform_translate_3d gsk_transform_rotate gsk_transform_rotate_3d gsk_transform_scale gsk_transform_scale_3d gsk_transform_perspective gsk_transform_transform_bounds gsk_transform_transform_point GSK_TYPE_TRANSFORM gsk_transform_get_type
gsktypes GskRenderer GskTransform
gskvulkanrenderer GskVulkanRenderer gsk_vulkan_renderer_new GSK_IS_VULKAN_RENDERER GSK_IS_VULKAN_RENDERER_CLASS GSK_TYPE_VULKAN_RENDERER GSK_VULKAN_RENDERER GSK_VULKAN_RENDERER_CLASS GSK_VULKAN_RENDERER_GET_CLASS GskVulkanRenderer GskVulkanRendererClass gsk_vulkan_renderer_get_type
docs/reference/gsk/gsk4-decl.txt0000664000175000017500000013364113766440674016727 0ustar mclasenmclasen GSK_TYPE_CAIRO_RENDERER #define GSK_TYPE_CAIRO_RENDERER (gsk_cairo_renderer_get_type ()) GSK_CAIRO_RENDERER #define GSK_CAIRO_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSK_TYPE_CAIRO_RENDERER, GskCairoRenderer)) GSK_IS_CAIRO_RENDERER #define GSK_IS_CAIRO_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSK_TYPE_CAIRO_RENDERER)) GSK_CAIRO_RENDERER_CLASS #define GSK_CAIRO_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GSK_TYPE_CAIRO_RENDERER, GskCairoRendererClass)) GSK_IS_CAIRO_RENDERER_CLASS #define GSK_IS_CAIRO_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GSK_TYPE_CAIRO_RENDERER)) GSK_CAIRO_RENDERER_GET_CLASS #define GSK_CAIRO_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GSK_TYPE_CAIRO_RENDERER, GskCairoRendererClass)) gsk_cairo_renderer_get_type GType void gsk_cairo_renderer_new GskRenderer * void GskCairoRenderer GskCairoRendererClass GskRenderNodeType typedef enum { GSK_NOT_A_RENDER_NODE = 0, GSK_CONTAINER_NODE, GSK_CAIRO_NODE, GSK_COLOR_NODE, GSK_LINEAR_GRADIENT_NODE, GSK_REPEATING_LINEAR_GRADIENT_NODE, GSK_RADIAL_GRADIENT_NODE, GSK_REPEATING_RADIAL_GRADIENT_NODE, GSK_CONIC_GRADIENT_NODE, GSK_BORDER_NODE, GSK_TEXTURE_NODE, GSK_INSET_SHADOW_NODE, GSK_OUTSET_SHADOW_NODE, GSK_TRANSFORM_NODE, GSK_OPACITY_NODE, GSK_COLOR_MATRIX_NODE, GSK_REPEAT_NODE, GSK_CLIP_NODE, GSK_ROUNDED_CLIP_NODE, GSK_SHADOW_NODE, GSK_BLEND_NODE, GSK_CROSS_FADE_NODE, GSK_TEXT_NODE, GSK_BLUR_NODE, GSK_DEBUG_NODE, GSK_GL_SHADER_NODE } GskRenderNodeType; GskScalingFilter typedef enum { GSK_SCALING_FILTER_LINEAR, GSK_SCALING_FILTER_NEAREST, GSK_SCALING_FILTER_TRILINEAR } GskScalingFilter; GskBlendMode typedef enum { GSK_BLEND_MODE_DEFAULT = 0, GSK_BLEND_MODE_MULTIPLY, GSK_BLEND_MODE_SCREEN, GSK_BLEND_MODE_OVERLAY, GSK_BLEND_MODE_DARKEN, GSK_BLEND_MODE_LIGHTEN, GSK_BLEND_MODE_COLOR_DODGE, GSK_BLEND_MODE_COLOR_BURN, GSK_BLEND_MODE_HARD_LIGHT, GSK_BLEND_MODE_SOFT_LIGHT, GSK_BLEND_MODE_DIFFERENCE, GSK_BLEND_MODE_EXCLUSION, GSK_BLEND_MODE_COLOR, GSK_BLEND_MODE_HUE, GSK_BLEND_MODE_SATURATION, GSK_BLEND_MODE_LUMINOSITY } GskBlendMode; GskCorner typedef enum { GSK_CORNER_TOP_LEFT, GSK_CORNER_TOP_RIGHT, GSK_CORNER_BOTTOM_RIGHT, GSK_CORNER_BOTTOM_LEFT } GskCorner; GskSerializationError typedef enum { GSK_SERIALIZATION_UNSUPPORTED_FORMAT, GSK_SERIALIZATION_UNSUPPORTED_VERSION, GSK_SERIALIZATION_INVALID_DATA } GskSerializationError; GskTransformCategory typedef enum { GSK_TRANSFORM_CATEGORY_UNKNOWN, GSK_TRANSFORM_CATEGORY_ANY, GSK_TRANSFORM_CATEGORY_3D, GSK_TRANSFORM_CATEGORY_2D, GSK_TRANSFORM_CATEGORY_2D_AFFINE, GSK_TRANSFORM_CATEGORY_2D_TRANSLATE, GSK_TRANSFORM_CATEGORY_IDENTITY } GskTransformCategory; GskGLUniformType typedef enum { GSK_GL_UNIFORM_TYPE_NONE, GSK_GL_UNIFORM_TYPE_FLOAT, GSK_GL_UNIFORM_TYPE_INT, GSK_GL_UNIFORM_TYPE_UINT, GSK_GL_UNIFORM_TYPE_BOOL, GSK_GL_UNIFORM_TYPE_VEC2, GSK_GL_UNIFORM_TYPE_VEC3, GSK_GL_UNIFORM_TYPE_VEC4, } GskGLUniformType; GSK_TYPE_SHADER_ARGS_BUILDER #define GSK_TYPE_SHADER_ARGS_BUILDER (gsk_shader_args_builder_get_type ()) GSK_TYPE_GL_SHADER #define GSK_TYPE_GL_SHADER (gsk_gl_shader_get_type ()) gsk_gl_shader_new_from_bytes GskGLShader * GBytes *sourcecode gsk_gl_shader_new_from_resource GskGLShader * const char *resource_path gsk_gl_shader_compile gboolean GskGLShader *shader, GskRenderer *renderer, GError **error gsk_gl_shader_get_source GBytes * GskGLShader *shader gsk_gl_shader_get_resource const char * GskGLShader *shader gsk_gl_shader_get_n_textures int GskGLShader *shader gsk_gl_shader_get_n_uniforms int GskGLShader *shader gsk_gl_shader_get_uniform_name const char * GskGLShader *shader, int idx gsk_gl_shader_find_uniform_by_name int GskGLShader *shader, const char *name gsk_gl_shader_get_uniform_type GskGLUniformType GskGLShader *shader, int idx gsk_gl_shader_get_uniform_offset int GskGLShader *shader, int idx gsk_gl_shader_get_args_size gsize GskGLShader *shader gsk_gl_shader_format_args_va GBytes * GskGLShader *shader, va_list uniforms gsk_gl_shader_format_args GBytes * GskGLShader *shader, ... gsk_gl_shader_get_arg_float float GskGLShader *shader, GBytes *args, int idx gsk_gl_shader_get_arg_int gint32 GskGLShader *shader, GBytes *args, int idx gsk_gl_shader_get_arg_uint guint32 GskGLShader *shader, GBytes *args, int idx gsk_gl_shader_get_arg_bool gboolean GskGLShader *shader, GBytes *args, int idx gsk_gl_shader_get_arg_vec2 void GskGLShader *shader, GBytes *args, int idx, graphene_vec2_t *out_value gsk_gl_shader_get_arg_vec3 void GskGLShader *shader, GBytes *args, int idx, graphene_vec3_t *out_value gsk_gl_shader_get_arg_vec4 void GskGLShader *shader, GBytes *args, int idx, graphene_vec4_t *out_value gsk_shader_args_builder_get_type GType void gsk_shader_args_builder_new GskShaderArgsBuilder * GskGLShader *shader, GBytes *initial_values gsk_shader_args_builder_to_args GBytes * GskShaderArgsBuilder *builder gsk_shader_args_builder_free_to_args GBytes * GskShaderArgsBuilder *builder gsk_shader_args_builder_ref GskShaderArgsBuilder * GskShaderArgsBuilder *builder gsk_shader_args_builder_unref void GskShaderArgsBuilder *builder gsk_shader_args_builder_set_float void GskShaderArgsBuilder *builder, int idx, float value gsk_shader_args_builder_set_int void GskShaderArgsBuilder *builder, int idx, gint32 value gsk_shader_args_builder_set_uint void GskShaderArgsBuilder *builder, int idx, guint32 value gsk_shader_args_builder_set_bool void GskShaderArgsBuilder *builder, int idx, gboolean value gsk_shader_args_builder_set_vec2 void GskShaderArgsBuilder *builder, int idx, const graphene_vec2_t *value gsk_shader_args_builder_set_vec3 void GskShaderArgsBuilder *builder, int idx, const graphene_vec3_t *value gsk_shader_args_builder_set_vec4 void GskShaderArgsBuilder *builder, int idx, const graphene_vec4_t *value GskGLShader GskShaderArgsBuilder GSK_TYPE_RENDERER #define GSK_TYPE_RENDERER (gsk_renderer_get_type ()) GSK_RENDERER #define GSK_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSK_TYPE_RENDERER, GskRenderer)) GSK_IS_RENDERER #define GSK_IS_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSK_TYPE_RENDERER)) gsk_renderer_get_type GType void gsk_renderer_new_for_surface GskRenderer * GdkSurface *surface gsk_renderer_get_surface GdkSurface * GskRenderer *renderer gsk_renderer_realize gboolean GskRenderer *renderer, GdkSurface *surface, GError **error gsk_renderer_unrealize void GskRenderer *renderer gsk_renderer_is_realized gboolean GskRenderer *renderer gsk_renderer_render_texture GdkTexture * GskRenderer *renderer, GskRenderNode *root, const graphene_rect_t *viewport gsk_renderer_render void GskRenderer *renderer, GskRenderNode *root, const cairo_region_t *region GskRendererClass GSK_TYPE_RENDER_NODE #define GSK_TYPE_RENDER_NODE (gsk_render_node_get_type ()) GSK_IS_RENDER_NODE #define GSK_IS_RENDER_NODE(obj) ((obj) != NULL) GSK_SERIALIZATION_ERROR #define GSK_SERIALIZATION_ERROR (gsk_serialization_error_quark ()) GskColorStop struct _GskColorStop { float offset; GdkRGBA color; }; GskShadow struct _GskShadow { GdkRGBA color; float dx; float dy; float radius; }; GskParseLocation struct _GskParseLocation { gsize bytes; gsize chars; gsize lines; gsize line_bytes; gsize line_chars; }; GskParseErrorFunc void const GskParseLocation *start, const GskParseLocation *end, const GError *error, gpointer user_data gsk_render_node_get_type GType void gsk_serialization_error_quark GQuark void gsk_render_node_ref GskRenderNode * GskRenderNode *node gsk_render_node_unref void GskRenderNode *node gsk_render_node_get_node_type GskRenderNodeType GskRenderNode *node gsk_render_node_get_bounds void GskRenderNode *node, graphene_rect_t *bounds gsk_render_node_draw void GskRenderNode *node, cairo_t *cr gsk_render_node_serialize GBytes * GskRenderNode *node gsk_render_node_write_to_file gboolean GskRenderNode *node, const char *filename, GError **error gsk_render_node_deserialize GskRenderNode * GBytes *bytes, GskParseErrorFunc error_func, gpointer user_data GSK_TYPE_DEBUG_NODE #define GSK_TYPE_DEBUG_NODE (gsk_debug_node_get_type()) GSK_TYPE_COLOR_NODE #define GSK_TYPE_COLOR_NODE (gsk_color_node_get_type()) GSK_TYPE_TEXTURE_NODE #define GSK_TYPE_TEXTURE_NODE (gsk_texture_node_get_type()) GSK_TYPE_LINEAR_GRADIENT_NODE #define GSK_TYPE_LINEAR_GRADIENT_NODE (gsk_linear_gradient_node_get_type()) GSK_TYPE_REPEATING_LINEAR_GRADIENT_NODE #define GSK_TYPE_REPEATING_LINEAR_GRADIENT_NODE (gsk_repeating_linear_gradient_node_get_type()) GSK_TYPE_RADIAL_GRADIENT_NODE #define GSK_TYPE_RADIAL_GRADIENT_NODE (gsk_radial_gradient_node_get_type()) GSK_TYPE_REPEATING_RADIAL_GRADIENT_NODE #define GSK_TYPE_REPEATING_RADIAL_GRADIENT_NODE (gsk_repeating_radial_gradient_node_get_type()) GSK_TYPE_CONIC_GRADIENT_NODE #define GSK_TYPE_CONIC_GRADIENT_NODE (gsk_conic_gradient_node_get_type()) GSK_TYPE_BORDER_NODE #define GSK_TYPE_BORDER_NODE (gsk_border_node_get_type()) GSK_TYPE_INSET_SHADOW_NODE #define GSK_TYPE_INSET_SHADOW_NODE (gsk_inset_shadow_node_get_type()) GSK_TYPE_OUTSET_SHADOW_NODE #define GSK_TYPE_OUTSET_SHADOW_NODE (gsk_outset_shadow_node_get_type()) GSK_TYPE_CAIRO_NODE #define GSK_TYPE_CAIRO_NODE (gsk_cairo_node_get_type()) GSK_TYPE_CONTAINER_NODE #define GSK_TYPE_CONTAINER_NODE (gsk_container_node_get_type()) GSK_TYPE_TRANSFORM_NODE #define GSK_TYPE_TRANSFORM_NODE (gsk_transform_node_get_type()) GSK_TYPE_OPACITY_NODE #define GSK_TYPE_OPACITY_NODE (gsk_opacity_node_get_type()) GSK_TYPE_COLOR_MATRIX_NODE #define GSK_TYPE_COLOR_MATRIX_NODE (gsk_color_matrix_node_get_type()) GSK_TYPE_REPEAT_NODE #define GSK_TYPE_REPEAT_NODE (gsk_repeat_node_get_type()) GSK_TYPE_CLIP_NODE #define GSK_TYPE_CLIP_NODE (gsk_clip_node_get_type()) GSK_TYPE_ROUNDED_CLIP_NODE #define GSK_TYPE_ROUNDED_CLIP_NODE (gsk_rounded_clip_node_get_type()) GSK_TYPE_SHADOW_NODE #define GSK_TYPE_SHADOW_NODE (gsk_shadow_node_get_type()) GSK_TYPE_BLEND_NODE #define GSK_TYPE_BLEND_NODE (gsk_blend_node_get_type()) GSK_TYPE_CROSS_FADE_NODE #define GSK_TYPE_CROSS_FADE_NODE (gsk_cross_fade_node_get_type()) GSK_TYPE_TEXT_NODE #define GSK_TYPE_TEXT_NODE (gsk_text_node_get_type()) GSK_TYPE_BLUR_NODE #define GSK_TYPE_BLUR_NODE (gsk_blur_node_get_type()) GSK_TYPE_GL_SHADER_NODE #define GSK_TYPE_GL_SHADER_NODE (gsk_gl_shader_node_get_type()) gsk_debug_node_get_type GType void gsk_debug_node_new GskRenderNode * GskRenderNode *child, char *message gsk_debug_node_get_child GskRenderNode * GskRenderNode *node gsk_debug_node_get_message const char * GskRenderNode *node gsk_color_node_get_type GType void gsk_color_node_new GskRenderNode * const GdkRGBA *rgba, const graphene_rect_t *bounds gsk_color_node_get_color const GdkRGBA * GskRenderNode *node gsk_texture_node_get_type GType void gsk_texture_node_new GskRenderNode * GdkTexture *texture, const graphene_rect_t *bounds gsk_texture_node_get_texture GdkTexture * GskRenderNode *node gsk_linear_gradient_node_get_type GType void gsk_linear_gradient_node_new GskRenderNode * const graphene_rect_t *bounds, const graphene_point_t *start, const graphene_point_t *end, const GskColorStop *color_stops, gsize n_color_stops gsk_linear_gradient_node_get_start const graphene_point_t * GskRenderNode *node gsk_linear_gradient_node_get_end const graphene_point_t * GskRenderNode *node gsk_linear_gradient_node_get_n_color_stops gsize GskRenderNode *node gsk_linear_gradient_node_get_color_stops const GskColorStop * GskRenderNode *node, gsize *n_stops gsk_repeating_linear_gradient_node_get_type GType void gsk_repeating_linear_gradient_node_new GskRenderNode * const graphene_rect_t *bounds, const graphene_point_t *start, const graphene_point_t *end, const GskColorStop *color_stops, gsize n_color_stops gsk_conic_gradient_node_get_type GType void gsk_conic_gradient_node_new GskRenderNode * const graphene_rect_t *bounds, const graphene_point_t *center, float rotation, const GskColorStop *color_stops, gsize n_color_stops gsk_conic_gradient_node_get_center const graphene_point_t * GskRenderNode *node gsk_conic_gradient_node_get_rotation float GskRenderNode *node gsk_conic_gradient_node_get_n_color_stops gsize GskRenderNode *node gsk_conic_gradient_node_get_color_stops const GskColorStop * GskRenderNode *node, gsize *n_stops gsk_radial_gradient_node_get_type GType void gsk_radial_gradient_node_new GskRenderNode * const graphene_rect_t *bounds, const graphene_point_t *center, float hradius, float vradius, float start, float end, const GskColorStop *color_stops, gsize n_color_stops gsk_radial_gradient_node_get_n_color_stops gsize GskRenderNode *node gsk_radial_gradient_node_get_color_stops const GskColorStop * GskRenderNode *node, gsize *n_stops gsk_radial_gradient_node_get_center const graphene_point_t * GskRenderNode *node gsk_radial_gradient_node_get_hradius float GskRenderNode *node gsk_radial_gradient_node_get_vradius float GskRenderNode *node gsk_radial_gradient_node_get_start float GskRenderNode *node gsk_radial_gradient_node_get_end float GskRenderNode *node gsk_repeating_radial_gradient_node_get_type GType void gsk_repeating_radial_gradient_node_new GskRenderNode * const graphene_rect_t *bounds, const graphene_point_t *center, float hradius, float vradius, float start, float end, const GskColorStop *color_stops, gsize n_color_stops gsk_border_node_get_type GType void gsk_border_node_new GskRenderNode * const GskRoundedRect *outline, const float border_width[4], const GdkRGBA border_color[4] gsk_border_node_get_outline const GskRoundedRect * GskRenderNode *node gsk_border_node_get_widths const float * GskRenderNode *node gsk_border_node_get_colors const GdkRGBA * GskRenderNode *node gsk_inset_shadow_node_get_type GType void gsk_inset_shadow_node_new GskRenderNode * const GskRoundedRect *outline, const GdkRGBA *color, float dx, float dy, float spread, float blur_radius gsk_inset_shadow_node_get_outline const GskRoundedRect * GskRenderNode *node gsk_inset_shadow_node_get_color const GdkRGBA * GskRenderNode *node gsk_inset_shadow_node_get_dx float GskRenderNode *node gsk_inset_shadow_node_get_dy float GskRenderNode *node gsk_inset_shadow_node_get_spread float GskRenderNode *node gsk_inset_shadow_node_get_blur_radius float GskRenderNode *node gsk_outset_shadow_node_get_type GType void gsk_outset_shadow_node_new GskRenderNode * const GskRoundedRect *outline, const GdkRGBA *color, float dx, float dy, float spread, float blur_radius gsk_outset_shadow_node_get_outline const GskRoundedRect * GskRenderNode *node gsk_outset_shadow_node_get_color const GdkRGBA * GskRenderNode *node gsk_outset_shadow_node_get_dx float GskRenderNode *node gsk_outset_shadow_node_get_dy float GskRenderNode *node gsk_outset_shadow_node_get_spread float GskRenderNode *node gsk_outset_shadow_node_get_blur_radius float GskRenderNode *node gsk_cairo_node_get_type GType void gsk_cairo_node_new GskRenderNode * const graphene_rect_t *bounds gsk_cairo_node_get_draw_context cairo_t * GskRenderNode *node gsk_cairo_node_get_surface cairo_surface_t * GskRenderNode *node gsk_container_node_get_type GType void gsk_container_node_new GskRenderNode * GskRenderNode **children, guint n_children gsk_container_node_get_n_children guint GskRenderNode *node gsk_container_node_get_child GskRenderNode * GskRenderNode *node, guint idx gsk_transform_node_get_type GType void gsk_transform_node_new GskRenderNode * GskRenderNode *child, GskTransform *transform gsk_transform_node_get_child GskRenderNode * GskRenderNode *node gsk_transform_node_get_transform GskTransform * GskRenderNode *node gsk_opacity_node_get_type GType void gsk_opacity_node_new GskRenderNode * GskRenderNode *child, float opacity gsk_opacity_node_get_child GskRenderNode * GskRenderNode *node gsk_opacity_node_get_opacity float GskRenderNode *node gsk_color_matrix_node_get_type GType void gsk_color_matrix_node_new GskRenderNode * GskRenderNode *child, const graphene_matrix_t *color_matrix, const graphene_vec4_t *color_offset gsk_color_matrix_node_get_child GskRenderNode * GskRenderNode *node gsk_color_matrix_node_get_color_matrix const graphene_matrix_t * GskRenderNode *node gsk_color_matrix_node_get_color_offset const graphene_vec4_t * GskRenderNode *node gsk_repeat_node_get_type GType void gsk_repeat_node_new GskRenderNode * const graphene_rect_t *bounds, GskRenderNode *child, const graphene_rect_t *child_bounds gsk_repeat_node_get_child GskRenderNode * GskRenderNode *node gsk_repeat_node_get_child_bounds const graphene_rect_t * GskRenderNode *node gsk_clip_node_get_type GType void gsk_clip_node_new GskRenderNode * GskRenderNode *child, const graphene_rect_t *clip gsk_clip_node_get_child GskRenderNode * GskRenderNode *node gsk_clip_node_get_clip const graphene_rect_t * GskRenderNode *node gsk_rounded_clip_node_get_type GType void gsk_rounded_clip_node_new GskRenderNode * GskRenderNode *child, const GskRoundedRect *clip gsk_rounded_clip_node_get_child GskRenderNode * GskRenderNode *node gsk_rounded_clip_node_get_clip const GskRoundedRect * GskRenderNode *node gsk_shadow_node_get_type GType void gsk_shadow_node_new GskRenderNode * GskRenderNode *child, const GskShadow *shadows, gsize n_shadows gsk_shadow_node_get_child GskRenderNode * GskRenderNode *node gsk_shadow_node_get_shadow const GskShadow * GskRenderNode *node, gsize i gsk_shadow_node_get_n_shadows gsize GskRenderNode *node gsk_blend_node_get_type GType void gsk_blend_node_new GskRenderNode * GskRenderNode *bottom, GskRenderNode *top, GskBlendMode blend_mode gsk_blend_node_get_bottom_child GskRenderNode * GskRenderNode *node gsk_blend_node_get_top_child GskRenderNode * GskRenderNode *node gsk_blend_node_get_blend_mode GskBlendMode GskRenderNode *node gsk_cross_fade_node_get_type GType void gsk_cross_fade_node_new GskRenderNode * GskRenderNode *start, GskRenderNode *end, float progress gsk_cross_fade_node_get_start_child GskRenderNode * GskRenderNode *node gsk_cross_fade_node_get_end_child GskRenderNode * GskRenderNode *node gsk_cross_fade_node_get_progress float GskRenderNode *node gsk_text_node_get_type GType void gsk_text_node_new GskRenderNode * PangoFont *font, PangoGlyphString *glyphs, const GdkRGBA *color, const graphene_point_t *offset gsk_text_node_get_font PangoFont * GskRenderNode *node gsk_text_node_has_color_glyphs gboolean GskRenderNode *node gsk_text_node_get_num_glyphs guint GskRenderNode *node gsk_text_node_get_glyphs const PangoGlyphInfo * GskRenderNode *node, guint *n_glyphs gsk_text_node_get_color const GdkRGBA * GskRenderNode *node gsk_text_node_get_offset const graphene_point_t * GskRenderNode *node gsk_blur_node_get_type GType void gsk_blur_node_new GskRenderNode * GskRenderNode *child, float radius gsk_blur_node_get_child GskRenderNode * GskRenderNode *node gsk_blur_node_get_radius float GskRenderNode *node gsk_gl_shader_node_get_type GType void gsk_gl_shader_node_new GskRenderNode * GskGLShader *shader, const graphene_rect_t *bounds, GBytes *args, GskRenderNode **children, guint n_children gsk_gl_shader_node_get_n_children guint GskRenderNode *node gsk_gl_shader_node_get_child GskRenderNode * GskRenderNode *node, guint idx gsk_gl_shader_node_get_args GBytes * GskRenderNode *node gsk_gl_shader_node_get_shader GskGLShader * GskRenderNode *node GskBlendNode GskBlurNode GskBorderNode GskCairoNode GskClipNode GskColorMatrixNode GskColorNode GskConicGradientNode GskContainerNode GskCrossFadeNode GskDebugNode GskGLShaderNode GskInsetShadowNode GskLinearGradientNode GskOpacityNode GskOutsetShadowNode GskRadialGradientNode GskRenderNode GskRepeatNode GskRepeatingLinearGradientNode GskRepeatingRadialGradientNode GskRoundedClipNode GskShadowNode GskTextNode GskTextureNode GskTransformNode GSK_ROUNDED_RECT_INIT #define GSK_ROUNDED_RECT_INIT(_x,_y,_w,_h) (GskRoundedRect) { .bounds = GRAPHENE_RECT_INIT(_x,_y,_w,_h), \ .corner = { \ GRAPHENE_SIZE_INIT(0, 0),\ GRAPHENE_SIZE_INIT(0, 0),\ GRAPHENE_SIZE_INIT(0, 0),\ GRAPHENE_SIZE_INIT(0, 0),\ }} GskRoundedRect struct _GskRoundedRect { graphene_rect_t bounds; graphene_size_t corner[4]; }; gsk_rounded_rect_init GskRoundedRect * GskRoundedRect *self, const graphene_rect_t *bounds, const graphene_size_t *top_left, const graphene_size_t *top_right, const graphene_size_t *bottom_right, const graphene_size_t *bottom_left gsk_rounded_rect_init_copy GskRoundedRect * GskRoundedRect *self, const GskRoundedRect *src gsk_rounded_rect_init_from_rect GskRoundedRect * GskRoundedRect *self, const graphene_rect_t *bounds, float radius gsk_rounded_rect_normalize GskRoundedRect * GskRoundedRect *self gsk_rounded_rect_offset GskRoundedRect * GskRoundedRect *self, float dx, float dy gsk_rounded_rect_shrink GskRoundedRect * GskRoundedRect *self, float top, float right, float bottom, float left gsk_rounded_rect_is_rectilinear gboolean const GskRoundedRect *self gsk_rounded_rect_contains_point gboolean const GskRoundedRect *self, const graphene_point_t *point gsk_rounded_rect_contains_rect gboolean const GskRoundedRect *self, const graphene_rect_t *rect gsk_rounded_rect_intersects_rect gboolean const GskRoundedRect *self, const graphene_rect_t *rect GSK_TYPE_TRANSFORM #define GSK_TYPE_TRANSFORM (gsk_transform_get_type ()) gsk_transform_get_type GType void gsk_transform_ref GskTransform * GskTransform *self gsk_transform_unref void GskTransform *self gsk_transform_print void GskTransform *self, GString *string gsk_transform_to_string char * GskTransform *self gsk_transform_parse gboolean const char *string, GskTransform **out_transform gsk_transform_to_matrix void GskTransform *self, graphene_matrix_t *out_matrix gsk_transform_to_2d void GskTransform *self, float *out_xx, float *out_yx, float *out_xy, float *out_yy, float *out_dx, float *out_dy gsk_transform_to_affine void GskTransform *self, float *out_scale_x, float *out_scale_y, float *out_dx, float *out_dy gsk_transform_to_translate void GskTransform *self, float *out_dx, float *out_dy gsk_transform_get_category GskTransformCategory GskTransform *self gsk_transform_equal gboolean GskTransform *first, GskTransform *second gsk_transform_new GskTransform * void gsk_transform_transform GskTransform * GskTransform *next, GskTransform *other gsk_transform_invert GskTransform * GskTransform *self gsk_transform_matrix GskTransform * GskTransform *next, const graphene_matrix_t *matrix gsk_transform_translate GskTransform * GskTransform *next, const graphene_point_t *point gsk_transform_translate_3d GskTransform * GskTransform *next, const graphene_point3d_t *point gsk_transform_rotate GskTransform * GskTransform *next, float angle gsk_transform_rotate_3d GskTransform * GskTransform *next, float angle, const graphene_vec3_t *axis gsk_transform_scale GskTransform * GskTransform *next, float factor_x, float factor_y gsk_transform_scale_3d GskTransform * GskTransform *next, float factor_x, float factor_y, float factor_z gsk_transform_perspective GskTransform * GskTransform *next, float depth gsk_transform_transform_bounds void GskTransform *self, const graphene_rect_t *rect, graphene_rect_t *out_rect gsk_transform_transform_point void GskTransform *self, const graphene_point_t *point, graphene_point_t *out_point GskRenderer GskTransform GSK_TYPE_BROADWAY_RENDERER #define GSK_TYPE_BROADWAY_RENDERER (gsk_broadway_renderer_get_type ()) GSK_BROADWAY_RENDERER #define GSK_BROADWAY_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSK_TYPE_BROADWAY_RENDERER, GskBroadwayRenderer)) GSK_IS_BROADWAY_RENDERER #define GSK_IS_BROADWAY_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSK_TYPE_BROADWAY_RENDERER)) GSK_BROADWAY_RENDERER_CLASS #define GSK_BROADWAY_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GSK_TYPE_BROADWAY_RENDERER, GskBroadwayRendererClass)) GSK_IS_BROADWAY_RENDERER_CLASS #define GSK_IS_BROADWAY_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GSK_TYPE_BROADWAY_RENDERER)) GSK_BROADWAY_RENDERER_GET_CLASS #define GSK_BROADWAY_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GSK_TYPE_BROADWAY_RENDERER, GskBroadwayRendererClass)) gsk_broadway_renderer_get_type GType void gsk_broadway_renderer_new GskRenderer * void GskBroadwayRenderer GskBroadwayRendererClass GSK_TYPE_GL_RENDERER #define GSK_TYPE_GL_RENDERER (gsk_gl_renderer_get_type ()) GSK_GL_RENDERER #define GSK_GL_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSK_TYPE_GL_RENDERER, GskGLRenderer)) GSK_IS_GL_RENDERER #define GSK_IS_GL_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSK_TYPE_GL_RENDERER)) GSK_GL_RENDERER_CLASS #define GSK_GL_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GSK_TYPE_GL_RENDERER, GskGLRendererClass)) GSK_IS_GL_RENDERER_CLASS #define GSK_IS_GL_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GSK_TYPE_GL_RENDERER)) GSK_GL_RENDERER_GET_CLASS #define GSK_GL_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GSK_TYPE_GL_RENDERER, GskGLRendererClass)) gsk_gl_renderer_get_type GType void gsk_gl_renderer_new GskRenderer * void GskGLRenderer GskGLRendererClass GSK_TYPE_VULKAN_RENDERER #define GSK_TYPE_VULKAN_RENDERER (gsk_vulkan_renderer_get_type ()) GSK_VULKAN_RENDERER #define GSK_VULKAN_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSK_TYPE_VULKAN_RENDERER, GskVulkanRenderer)) GSK_IS_VULKAN_RENDERER #define GSK_IS_VULKAN_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSK_TYPE_VULKAN_RENDERER)) GSK_VULKAN_RENDERER_CLASS #define GSK_VULKAN_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GSK_TYPE_VULKAN_RENDERER, GskVulkanRendererClass)) GSK_IS_VULKAN_RENDERER_CLASS #define GSK_IS_VULKAN_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GSK_TYPE_VULKAN_RENDERER)) GSK_VULKAN_RENDERER_GET_CLASS #define GSK_VULKAN_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GSK_TYPE_VULKAN_RENDERER, GskVulkanRendererClass)) gsk_vulkan_renderer_get_type GType void gsk_vulkan_renderer_new GskRenderer * void GskVulkanRenderer GskVulkanRendererClass GSK_TYPE_RENDER_NODE_TYPE #define GSK_TYPE_RENDER_NODE_TYPE (gsk_render_node_type_get_type ()) GSK_TYPE_SCALING_FILTER #define GSK_TYPE_SCALING_FILTER (gsk_scaling_filter_get_type ()) GSK_TYPE_BLEND_MODE #define GSK_TYPE_BLEND_MODE (gsk_blend_mode_get_type ()) GSK_TYPE_CORNER #define GSK_TYPE_CORNER (gsk_corner_get_type ()) GSK_TYPE_SERIALIZATION_ERROR #define GSK_TYPE_SERIALIZATION_ERROR (gsk_serialization_error_get_type ()) GSK_TYPE_TRANSFORM_CATEGORY #define GSK_TYPE_TRANSFORM_CATEGORY (gsk_transform_category_get_type ()) GSK_TYPE_GL_UNIFORM_TYPE #define GSK_TYPE_GL_UNIFORM_TYPE (gsk_gl_uniform_type_get_type ()) docs/reference/gsk/gsk4-overrides.txt0000664000175000017500000000000013766440674020000 0ustar mclasenmclasendocs/reference/gsk/gsk4.signals0000664000175000017500000000000013766440674016621 0ustar mclasenmclasendocs/reference/gsk/gsk4.hierarchy0000664000175000017500000000013013766440674017143 0ustar mclasenmclasenGObject GskRenderer GskGLShader GdkSurface GInterface GTypePlugin GskRenderNode docs/reference/gsk/gsk4.interfaces0000664000175000017500000000000013766440674017304 0ustar mclasenmclasendocs/reference/gsk/gsk4.prerequisites0000664000175000017500000000000013766440674020065 0ustar mclasenmclasendocs/reference/gsk/gsk4.args0000664000175000017500000000144513766440674016133 0ustar mclasenmclasen GskRenderer::realized gboolean r Realized The renderer has been associated with a surface. FALSE GskRenderer::surface GdkSurface* r Surface The surface associated to the renderer. GskGLShader::resource char* rwX Resources Resource path to the source code. NULL GskGLShader::source GBytes* rwX Source The sourcecode for the shader. docs/reference/gsk/gsk4.actions0000664000175000017500000000000013766440674016621 0ustar mclasenmclasendocs/reference/gsk/xml/0000775000175000017500000000000013766440675015202 5ustar mclasenmclasendocs/reference/gsk/xml/GskRenderer.xml0000664000175000017500000006067413766440675020154 0ustar mclasenmclasen ]> GskRenderer 3 GSK4 Library GskRenderer Renders a scene Functions GdkSurface * gsk_renderer_get_surface () gboolean gsk_renderer_realize () void gsk_renderer_unrealize () gboolean gsk_renderer_is_realized () void gsk_renderer_render () GdkTexture * gsk_renderer_render_texture () GskRenderer * gsk_renderer_new_for_surface () GskRenderer * gsk_gl_renderer_new () GskRenderer * gsk_cairo_renderer_new () GskRenderer * gsk_vulkan_renderer_new () GskRenderer * gsk_broadway_renderer_new () Properties gbooleanrealizedRead GdkSurface *surfaceRead Types and Values GskRenderer Object Hierarchy GObject ╰── GskRenderer Description GskRenderer is a class that renders a scene graph defined via a tree of GskRenderNode instances. Typically you will use a GskRenderer instance to repeatedly call gsk_renderer_render() to update the contents of its associated GdkSurface. It is necessary to realize a GskRenderer instance using gsk_renderer_realize() before calling gsk_renderer_render(), in order to create the appropriate windowing system resources needed to render the scene. Functions gsk_renderer_get_surface () gsk_renderer_get_surface GdkSurface * gsk_renderer_get_surface (GskRenderer *renderer); Retrieves the GdkSurface set using gsk_renderer_realize(). If the renderer has not been realized yet, NULL will be returned. Parameters renderer a GskRenderer Returns a GdkSurface. [transfer none][nullable] gsk_renderer_realize () gsk_renderer_realize gboolean gsk_renderer_realize (GskRenderer *renderer, GdkSurface *surface, GError **error); Creates the resources needed by the renderer to render the scene graph. Parameters renderer a GskRenderer surface the GdkSurface renderer will be used on error return location for an error gsk_renderer_unrealize () gsk_renderer_unrealize void gsk_renderer_unrealize (GskRenderer *renderer); Releases all the resources created by gsk_renderer_realize(). Parameters renderer a GskRenderer gsk_renderer_is_realized () gsk_renderer_is_realized gboolean gsk_renderer_is_realized (GskRenderer *renderer); Checks whether the renderer is realized or not. Parameters renderer a GskRenderer Returns TRUE if the GskRenderer was realized, and FALSE otherwise gsk_renderer_render () gsk_renderer_render void gsk_renderer_render (GskRenderer *renderer, GskRenderNode *root, const cairo_region_t *region); Renders the scene graph, described by a tree of GskRenderNode instances, ensuring that the given region gets redrawn. Renderers must ensure that changes of the contents given by the root node as well as the area given by region are redrawn. They are however free to not redraw any pixel outside of region if they can guarantee that it didn't change. The renderer will acquire a reference on the GskRenderNode tree while the rendering is in progress. Parameters renderer a GskRenderer root a GskRenderNode region the cairo_region_t that must be redrawn or NULL for the whole window. [nullable] gsk_renderer_render_texture () gsk_renderer_render_texture GdkTexture * gsk_renderer_render_texture (GskRenderer *renderer, GskRenderNode *root, const graphene_rect_t *viewport); Renders the scene graph, described by a tree of GskRenderNode instances, to a GdkTexture. The renderer will acquire a reference on the GskRenderNode tree while the rendering is in progress. If you want to apply any transformations to root , you should put it into a transform node and pass that node instead. Parameters renderer a realized GskRenderer root a GskRenderNode viewport the section to draw or NULL to use root 's bounds. [allow-none] Returns a GdkTexture with the rendered contents of root . [transfer full] gsk_renderer_new_for_surface () gsk_renderer_new_for_surface GskRenderer * gsk_renderer_new_for_surface (GdkSurface *surface); Creates an appropriate GskRenderer instance for the given surface . If the GSK_RENDERER environment variable is set, GSK will try that renderer first, before trying the backend-specific default. The ultimate fallback is the cairo renderer. The renderer will be realized before it is returned. Parameters surface a GdkSurface Returns a GskRenderer. [transfer full][nullable] gsk_gl_renderer_new () gsk_gl_renderer_new GskRenderer * gsk_gl_renderer_new (void); Creates a new GskRenderer using OpenGL. This is the default renderer used by GTK. Returns a new GL renderer gsk_cairo_renderer_new () gsk_cairo_renderer_new GskRenderer * gsk_cairo_renderer_new (void); Creates a new Cairo renderer. The Cairo renderer is the fallback renderer drawing in ways similar to how GTK 3 drew its content. Its primary use is as comparison tool. The Cairo renderer is incomplete. It cannot render 3D transformed content and will instead render an error marker. Its usage should be avoided. Returns a new Cairo renderer. gsk_vulkan_renderer_new () gsk_vulkan_renderer_new GskRenderer * gsk_vulkan_renderer_new (void); Creates a new Vulkan renderer. The Vulkan renderer is a renderer that uses the Vulkan library for rendering. This function is only available when GTK was compiled with Vulkan support. Returns a new Vulkan renderer gsk_broadway_renderer_new () gsk_broadway_renderer_new GskRenderer * gsk_broadway_renderer_new (void); Creates a new Broadway renderer. The Broadway renderer is the default renderer for the broadway backend. It will only work with broadway surfaces, otherwise it will fail the call to gsk_renderer_realize(). This function is only available when GTK was compiled with Broadway support. Returns a new Broadway renderer. Types and Values GskRenderer GskRenderer typedef struct _GskRenderer GskRenderer; Base type for the object managing the rendering pipeline for a GdkSurface. Property Details The <literal>“realized”</literal> property GskRenderer:realized “realized” gboolean The renderer has been associated with a surface.Owner: GskRenderer Flags: Read Default value: FALSE The <literal>“surface”</literal> property GskRenderer:surface “surface” GdkSurface * The surface associated to the renderer.Owner: GskRenderer Flags: Read docs/reference/gsk/xml/GskRenderNode.xml0000664000175000017500000100206113766440675020416 0ustar mclasenmclasen ]> GskRenderNode 3 GSK4 Library GskRenderNode Simple scene graph element Functions GskRenderNode * gsk_render_node_ref () void gsk_render_node_unref () GskRenderNodeType gsk_render_node_get_node_type () void gsk_render_node_draw () void (*GskParseErrorFunc) () GBytes * gsk_render_node_serialize () GskRenderNode * gsk_render_node_deserialize () gboolean gsk_render_node_write_to_file () void gsk_render_node_get_bounds () GskRenderNode * gsk_color_node_new () const GdkRGBA * gsk_color_node_get_color () GskRenderNode * gsk_texture_node_new () GdkTexture * gsk_texture_node_get_texture () GskRenderNode * gsk_linear_gradient_node_new () const graphene_point_t * gsk_linear_gradient_node_get_start () const graphene_point_t * gsk_linear_gradient_node_get_end () gsize gsk_linear_gradient_node_get_n_color_stops () const GskColorStop * gsk_linear_gradient_node_get_color_stops () GskRenderNode * gsk_repeating_linear_gradient_node_new () GskRenderNode * gsk_radial_gradient_node_new () gsize gsk_radial_gradient_node_get_n_color_stops () const GskColorStop * gsk_radial_gradient_node_get_color_stops () float gsk_radial_gradient_node_get_start () float gsk_radial_gradient_node_get_end () float gsk_radial_gradient_node_get_hradius () float gsk_radial_gradient_node_get_vradius () const graphene_point_t * gsk_radial_gradient_node_get_center () GskRenderNode * gsk_repeating_radial_gradient_node_new () GskRenderNode * gsk_conic_gradient_node_new () gsize gsk_conic_gradient_node_get_n_color_stops () const GskColorStop * gsk_conic_gradient_node_get_color_stops () const graphene_point_t * gsk_conic_gradient_node_get_center () float gsk_conic_gradient_node_get_rotation () GskRenderNode * gsk_border_node_new () const GskRoundedRect * gsk_border_node_get_outline () const float * gsk_border_node_get_widths () const GdkRGBA * gsk_border_node_get_colors () GskRenderNode * gsk_inset_shadow_node_new () const GskRoundedRect * gsk_inset_shadow_node_get_outline () const GdkRGBA * gsk_inset_shadow_node_get_color () float gsk_inset_shadow_node_get_dx () float gsk_inset_shadow_node_get_dy () float gsk_inset_shadow_node_get_spread () float gsk_inset_shadow_node_get_blur_radius () GskRenderNode * gsk_outset_shadow_node_new () const GskRoundedRect * gsk_outset_shadow_node_get_outline () const GdkRGBA * gsk_outset_shadow_node_get_color () float gsk_outset_shadow_node_get_dx () float gsk_outset_shadow_node_get_dy () float gsk_outset_shadow_node_get_spread () float gsk_outset_shadow_node_get_blur_radius () GskRenderNode * gsk_cairo_node_new () cairo_t * gsk_cairo_node_get_draw_context () cairo_surface_t * gsk_cairo_node_get_surface () GskRenderNode * gsk_container_node_new () guint gsk_container_node_get_n_children () GskRenderNode * gsk_container_node_get_child () GskRenderNode * gsk_transform_node_new () GskRenderNode * gsk_transform_node_get_child () GskTransform * gsk_transform_node_get_transform () GskRenderNode * gsk_opacity_node_new () GskRenderNode * gsk_opacity_node_get_child () float gsk_opacity_node_get_opacity () GskRenderNode * gsk_color_matrix_node_new () GskRenderNode * gsk_color_matrix_node_get_child () const graphene_matrix_t * gsk_color_matrix_node_get_color_matrix () const graphene_vec4_t * gsk_color_matrix_node_get_color_offset () GskRenderNode * gsk_repeat_node_new () GskRenderNode * gsk_repeat_node_get_child () const graphene_rect_t * gsk_repeat_node_get_child_bounds () GskRenderNode * gsk_clip_node_new () GskRenderNode * gsk_clip_node_get_child () const graphene_rect_t * gsk_clip_node_get_clip () GskRenderNode * gsk_rounded_clip_node_new () GskRenderNode * gsk_rounded_clip_node_get_child () const GskRoundedRect * gsk_rounded_clip_node_get_clip () GskRenderNode * gsk_shadow_node_new () const GskShadow * gsk_shadow_node_get_shadow () gsize gsk_shadow_node_get_n_shadows () GskRenderNode * gsk_shadow_node_get_child () GskRenderNode * gsk_blend_node_new () GskRenderNode * gsk_blend_node_get_bottom_child () GskRenderNode * gsk_blend_node_get_top_child () GskBlendMode gsk_blend_node_get_blend_mode () GskRenderNode * gsk_cross_fade_node_new () GskRenderNode * gsk_cross_fade_node_get_start_child () GskRenderNode * gsk_cross_fade_node_get_end_child () float gsk_cross_fade_node_get_progress () GskRenderNode * gsk_text_node_new () PangoFont * gsk_text_node_get_font () const PangoGlyphInfo * gsk_text_node_get_glyphs () const GdkRGBA * gsk_text_node_get_color () gboolean gsk_text_node_has_color_glyphs () guint gsk_text_node_get_num_glyphs () const graphene_point_t * gsk_text_node_get_offset () GskRenderNode * gsk_blur_node_new () GskRenderNode * gsk_blur_node_get_child () float gsk_blur_node_get_radius () GskRenderNode * gsk_debug_node_new () GskRenderNode * gsk_debug_node_get_child () const char * gsk_debug_node_get_message () GskRenderNode * gsk_gl_shader_node_new () guint gsk_gl_shader_node_get_n_children () GskRenderNode * gsk_gl_shader_node_get_child () GBytes * gsk_gl_shader_node_get_args () GskGLShader * gsk_gl_shader_node_get_shader () Types and Values GskRenderNode GskBlendNode GskBlurNode GskBorderNode GskCairoNode GskClipNode GskColorMatrixNode GskColorNode GskConicGradientNode GskContainerNode GskCrossFadeNode GskDebugNode GskInsetShadowNode GskLinearGradientNode GskRadialGradientNode GskOpacityNode GskOutsetShadowNode GskRepeatingLinearGradientNode GskRepeatingRadialGradientNode GskRepeatNode GskRoundedClipNode GskShadowNode GskTextNode GskTextureNode GskTransformNode GskGLShaderNode enumGskRenderNodeType enumGskSerializationError structGskParseLocation enumGskScalingFilter structGskColorStop structGskShadow enumGskBlendMode Object Hierarchy GskRenderNode Description GskRenderNode is the basic block in a scene graph to be rendered using GskRenderer. Each node has a parent, except the top-level node; each node may have children nodes. Each node has an associated drawing surface, which has the size of the rectangle set using gsk_render_node_set_bounds(). Render nodes are meant to be transient; once they have been associated to a GskRenderer it's safe to release any reference you have on them. All GskRenderNodes are immutable, you can only specify their properties during construction. Functions gsk_render_node_ref () gsk_render_node_ref GskRenderNode * gsk_render_node_ref (GskRenderNode *node); Acquires a reference on the given GskRenderNode. Parameters node a GskRenderNode Returns the GskRenderNode with an additional reference. [transfer full] gsk_render_node_unref () gsk_render_node_unref void gsk_render_node_unref (GskRenderNode *node); Releases a reference on the given GskRenderNode. If the reference was the last, the resources associated to the node are freed. Parameters node a GskRenderNode. [transfer full] gsk_render_node_get_node_type () gsk_render_node_get_node_type GskRenderNodeType gsk_render_node_get_node_type (GskRenderNode *node); Returns the type of the node . Parameters node a GskRenderNode Returns the type of the GskRenderNode gsk_render_node_draw () gsk_render_node_draw void gsk_render_node_draw (GskRenderNode *node, cairo_t *cr); Draw the contents of node to the given cairo context. Typically, you'll use this function to implement fallback rendering of GskRenderNodes on an intermediate Cairo context, instead of using the drawing context associated to a GdkSurface's rendering buffer. For advanced nodes that cannot be supported using Cairo, in particular for nodes doing 3D operations, this function may fail. Parameters node a GskRenderNode cr cairo context to draw to GskParseErrorFunc () GskParseErrorFunc void (*GskParseErrorFunc) (const GskParseLocation *start, const GskParseLocation *end, const GError *error, gpointer user_data); The type of callback that is called when a parse error occurs during deserialization of node data. Parameters start start of the error location end end of the error location error the error user_data user data gsk_render_node_serialize () gsk_render_node_serialize GBytes * gsk_render_node_serialize (GskRenderNode *node); Serializes the node for later deserialization via gsk_render_node_deserialize(). No guarantees are made about the format used other than that the same version of GTK will be able to deserialize the result of a call to gsk_render_node_serialize() and gsk_render_node_deserialize() will correctly reject files it cannot open that were created with previous versions of GTK. The intended use of this functions is testing, benchmarking and debugging. The format is not meant as a permanent storage format. Parameters node a GskRenderNode Returns a GBytes representing the node. gsk_render_node_deserialize () gsk_render_node_deserialize GskRenderNode * gsk_render_node_deserialize (GBytes *bytes, GskParseErrorFunc error_func, gpointer user_data); Loads data previously created via gsk_render_node_serialize(). For a discussion of the supported format, see that function. Parameters bytes the bytes containing the data error_func Callback on parsing errors or NULL. [nullable][scope call] user_data user_data for error_func . [closure error_func] Returns a new GskRenderNode or NULL on error. [nullable][transfer full] gsk_render_node_write_to_file () gsk_render_node_write_to_file gboolean gsk_render_node_write_to_file (GskRenderNode *node, const char *filename, GError **error); This function is equivalent to calling gsk_render_node_serialize() followed by g_file_set_contents(). See those two functions for details on the arguments. It is mostly intended for use inside a debugger to quickly dump a render node to a file for later inspection. Parameters node a GskRenderNode filename the file to save it to. error Return location for a potential error Returns TRUE if saving was successful gsk_render_node_get_bounds () gsk_render_node_get_bounds void gsk_render_node_get_bounds (GskRenderNode *node, graphene_rect_t *bounds); Retrieves the boundaries of the node . The node will not draw outside of its boundaries. Parameters node a GskRenderNode bounds return location for the boundaries. [out caller-allocates] gsk_color_node_new () gsk_color_node_new GskRenderNode * gsk_color_node_new (const GdkRGBA *rgba, const graphene_rect_t *bounds); Creates a GskRenderNode that will render the color specified by rgba into the area given by bounds . Parameters rgba a GdkRGBA specifying a color bounds the rectangle to render the color into Returns A new GskRenderNode. [transfer full][type GskColorNode] gsk_color_node_get_color () gsk_color_node_get_color const GdkRGBA * gsk_color_node_get_color (GskRenderNode *node); Retrieves the color of the given node . Parameters node a GskColorNode. [type GskColorNode] Returns the color of the node. [transfer none] gsk_texture_node_new () gsk_texture_node_new GskRenderNode * gsk_texture_node_new (GdkTexture *texture, const graphene_rect_t *bounds); Creates a GskRenderNode that will render the given texture into the area given by bounds . Parameters texture the GdkTexture bounds the rectangle to render the texture into Returns A new GskRenderNode. [transfer full][type GskTextureNode] gsk_texture_node_get_texture () gsk_texture_node_get_texture GdkTexture * gsk_texture_node_get_texture (GskRenderNode *node); Retrieves the GdkTexture used when creating this GskRenderNode. Parameters node a GskRenderNode of type GSK_TEXTURE_NODE. [type GskTextureNode] Returns the GdkTexture. [transfer none] gsk_linear_gradient_node_new () gsk_linear_gradient_node_new GskRenderNode * gsk_linear_gradient_node_new (const graphene_rect_t *bounds, const graphene_point_t *start, const graphene_point_t *end, const GskColorStop *color_stops, gsize n_color_stops); Creates a GskRenderNode that will create a linear gradient from the given points and color stops, and render that into the area given by bounds . Parameters bounds the rectangle to render the linear gradient into start the point at which the linear gradient will begin end the point at which the linear gradient will finish color_stops a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1. [array length=n_color_stops] n_color_stops the number of elements in color_stops Returns A new GskRenderNode. [transfer full][type GskLinearGradientNode] gsk_linear_gradient_node_get_start () gsk_linear_gradient_node_get_start const graphene_point_t * gsk_linear_gradient_node_get_start (GskRenderNode *node); Retrieves the initial point of the linear gradient. Parameters node a GskRenderNode for a linear gradient. [type GskLinearGradientNode] Returns the initial point. [transfer none] gsk_linear_gradient_node_get_end () gsk_linear_gradient_node_get_end const graphene_point_t * gsk_linear_gradient_node_get_end (GskRenderNode *node); Retrieves the final point of the linear gradient. Parameters node a GskRenderNode for a linear gradient. [type GskLinearGradientNode] Returns the final point. [transfer none] gsk_linear_gradient_node_get_n_color_stops () gsk_linear_gradient_node_get_n_color_stops gsize gsk_linear_gradient_node_get_n_color_stops (GskRenderNode *node); Retrieves the number of color stops in the gradient. Parameters node a GskRenderNode for a linear gradient. [type GskLinearGradientNode] Returns the number of color stops gsk_linear_gradient_node_get_color_stops () gsk_linear_gradient_node_get_color_stops const GskColorStop * gsk_linear_gradient_node_get_color_stops (GskRenderNode *node, gsize *n_stops); Retrieves the color stops in the gradient. Parameters node a GskRenderNode for a linear gradient. [type GskLinearGradientNode] n_stops the number of color stops in the returned array. [out][optional] Returns the color stops in the gradient. [array length=n_stops] gsk_repeating_linear_gradient_node_new () gsk_repeating_linear_gradient_node_new GskRenderNode * gsk_repeating_linear_gradient_node_new (const graphene_rect_t *bounds, const graphene_point_t *start, const graphene_point_t *end, const GskColorStop *color_stops, gsize n_color_stops); Creates a GskRenderNode that will create a repeating linear gradient from the given points and color stops, and render that into the area given by bounds . Parameters bounds the rectangle to render the linear gradient into start the point at which the linear gradient will begin end the point at which the linear gradient will finish color_stops a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1. [array length=n_color_stops] n_color_stops the number of elements in color_stops Returns A new GskRenderNode. [transfer full][type GskRepeatingLinearGradientNode] gsk_radial_gradient_node_new () gsk_radial_gradient_node_new GskRenderNode * gsk_radial_gradient_node_new (const graphene_rect_t *bounds, const graphene_point_t *center, float hradius, float vradius, float start, float end, const GskColorStop *color_stops, gsize n_color_stops); Creates a GskRenderNode that draws a radial gradient. The radial gradient starts around center . The size of the gradient is dictated by hradius in horizontal orientation and by vradius in vertial orientation. Parameters bounds the bounds of the node center the center of the gradient hradius the horizontal radius vradius the vertical radius start a percentage >= 0 that defines the start of the gradient around center end a percentage >= 0 that defines the end of the gradient around center color_stops a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1. [array length=n_color_stops] n_color_stops the number of elements in color_stops Returns A new GskRenderNode. [transfer full][type GskRadialGradientNode] gsk_radial_gradient_node_get_n_color_stops () gsk_radial_gradient_node_get_n_color_stops gsize gsk_radial_gradient_node_get_n_color_stops (GskRenderNode *node); Retrieves the number of color stops in the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] Returns the number of color stops gsk_radial_gradient_node_get_color_stops () gsk_radial_gradient_node_get_color_stops const GskColorStop * gsk_radial_gradient_node_get_color_stops (GskRenderNode *node, gsize *n_stops); Retrieves the color stops in the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] n_stops the number of color stops in the returned array. [out][optional] Returns the color stops in the gradient. [array length=n_stops] gsk_radial_gradient_node_get_start () gsk_radial_gradient_node_get_start float gsk_radial_gradient_node_get_start (GskRenderNode *node); Retrieves the start value for the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] Returns the start value for the gradient gsk_radial_gradient_node_get_end () gsk_radial_gradient_node_get_end float gsk_radial_gradient_node_get_end (GskRenderNode *node); Retrieves the end value for the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] Returns the end value for the gradient gsk_radial_gradient_node_get_hradius () gsk_radial_gradient_node_get_hradius float gsk_radial_gradient_node_get_hradius (GskRenderNode *node); Retrieves the horizonal radius for the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] Returns the horizontal radius for the gradient gsk_radial_gradient_node_get_vradius () gsk_radial_gradient_node_get_vradius float gsk_radial_gradient_node_get_vradius (GskRenderNode *node); Retrieves the vertical radius for the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] Returns the vertical radius for the gradient gsk_radial_gradient_node_get_center () gsk_radial_gradient_node_get_center const graphene_point_t * gsk_radial_gradient_node_get_center (GskRenderNode *node); Retrieves the center pointer for the gradient. Parameters node a GskRenderNode for a radial gradient. [type GskRadialGradientNode] Returns the center point for the gradient gsk_repeating_radial_gradient_node_new () gsk_repeating_radial_gradient_node_new GskRenderNode * gsk_repeating_radial_gradient_node_new (const graphene_rect_t *bounds, const graphene_point_t *center, float hradius, float vradius, float start, float end, const GskColorStop *color_stops, gsize n_color_stops); Creates a GskRenderNode that draws a repeating radial gradient. The radial gradient starts around center . The size of the gradient is dictated by hradius in horizontal orientation and by vradius in vertial orientation. Parameters bounds the bounds of the node center the center of the gradient hradius the horizontal radius vradius the vertical radius start a percentage >= 0 that defines the start of the gradient around center end a percentage >= 0 that defines the end of the gradient around center color_stops a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1. [array length=n_color_stops] n_color_stops the number of elements in color_stops Returns A new GskRenderNode. [transfer full][type GskRepeatingRadialGradientNode] gsk_conic_gradient_node_new () gsk_conic_gradient_node_new GskRenderNode * gsk_conic_gradient_node_new (const graphene_rect_t *bounds, const graphene_point_t *center, float rotation, const GskColorStop *color_stops, gsize n_color_stops); Creates a GskRenderNode that draws a conic gradient. The conic gradient starts around center in the direction of rotation . A rotation of 0 means that the gradient points up. Color stops are then added clockwise. Parameters bounds the bounds of the node center the center of the gradient rotation the rotation of the gradient in degrees color_stops a pointer to an array of GskColorStop defining the gradient The offsets of all color steps must be increasing. The first stop's offset must be >= 0 and the last stop's offset must be <= 1. [array length=n_color_stops] n_color_stops the number of elements in color_stops Returns A new GskRenderNode. [transfer full][type GskConicGradientNode] gsk_conic_gradient_node_get_n_color_stops () gsk_conic_gradient_node_get_n_color_stops gsize gsk_conic_gradient_node_get_n_color_stops (GskRenderNode *node); Retrieves the number of color stops in the gradient. Parameters node a GskRenderNode for a conic gradient. [type GskConicGradientNode] Returns the number of color stops gsk_conic_gradient_node_get_color_stops () gsk_conic_gradient_node_get_color_stops const GskColorStop * gsk_conic_gradient_node_get_color_stops (GskRenderNode *node, gsize *n_stops); Retrieves the color stops in the gradient. Parameters node a GskRenderNode for a conic gradient. [type GskConicGradientNode] n_stops the number of color stops in the returned array. [out][optional] Returns the color stops in the gradient. [array length=n_stops] gsk_conic_gradient_node_get_center () gsk_conic_gradient_node_get_center const graphene_point_t * gsk_conic_gradient_node_get_center (GskRenderNode *node); Retrieves the center pointer for the gradient. Parameters node a GskRenderNode for a conic gradient. [type GskConicGradientNode] Returns the center point for the gradient gsk_conic_gradient_node_get_rotation () gsk_conic_gradient_node_get_rotation float gsk_conic_gradient_node_get_rotation (GskRenderNode *node); Retrieves the rotation for the gradient in degrees. Parameters node a GskRenderNode for a conic gradient. [type GskConicGradientNode] Returns the rotation for the gradient gsk_border_node_new () gsk_border_node_new GskRenderNode * gsk_border_node_new (const GskRoundedRect *outline, const float border_width[4], const GdkRGBA border_color[4]); Creates a GskRenderNode that will stroke a border rectangle inside the given outline . The 4 sides of the border can have different widths and colors. Parameters outline a GskRoundedRect describing the outline of the border border_width the stroke width of the border on the top, right, bottom and left side respectively. [array fixed-size=4] border_color the color used on the top, right, bottom and left side. [array fixed-size=4] Returns A new GskRenderNode. [transfer full][type GskBorderNode] gsk_border_node_get_outline () gsk_border_node_get_outline const GskRoundedRect * gsk_border_node_get_outline (GskRenderNode *node); Retrieves the outline of the border. Parameters node a GskRenderNode for a border. [type GskBorderNode] Returns the outline of the border gsk_border_node_get_widths () gsk_border_node_get_widths const float * gsk_border_node_get_widths (GskRenderNode *node); Retrieves the stroke widths of the border. Parameters node a GskRenderNode for a border. [type GskBorderNode] Returns an array of 4 floats for the top, right, bottom and left stroke width of the border, respectively. [transfer none][array fixed-size=4] gsk_border_node_get_colors () gsk_border_node_get_colors const GdkRGBA * gsk_border_node_get_colors (GskRenderNode *node); Retrieves the colors of the border. Parameters node a GskRenderNode for a border. [type GskBorderNode] Returns an array of 4 GdkRGBA structs for the top, right, bottom and left color of the border. [transfer none] gsk_inset_shadow_node_new () gsk_inset_shadow_node_new GskRenderNode * gsk_inset_shadow_node_new (const GskRoundedRect *outline, const GdkRGBA *color, float dx, float dy, float spread, float blur_radius); Creates a GskRenderNode that will render an inset shadow into the box given by outline . Parameters outline outline of the region containing the shadow color color of the shadow dx horizontal offset of shadow dy vertical offset of shadow spread how far the shadow spreads towards the inside blur_radius how much blur to apply to the shadow Returns A new GskRenderNode. [transfer full][type GskInsetShadowNode] gsk_inset_shadow_node_get_outline () gsk_inset_shadow_node_get_outline const GskRoundedRect * gsk_inset_shadow_node_get_outline (GskRenderNode *node); Retrieves the outline rectangle of the inset shadow. Parameters node a GskRenderNode for an inset shadow. [type GskInsetShadowNode] Returns a rounded rectangle. [transfer none] gsk_inset_shadow_node_get_color () gsk_inset_shadow_node_get_color const GdkRGBA * gsk_inset_shadow_node_get_color (GskRenderNode *node); Retrieves the color of the inset shadow. Parameters node a GskRenderNode for an inset shadow. [type GskInsetShadowNode] Returns the color of the shadow. [transfer none] gsk_inset_shadow_node_get_dx () gsk_inset_shadow_node_get_dx float gsk_inset_shadow_node_get_dx (GskRenderNode *node); Retrieves the horizontal offset of the inset shadow. Parameters node a GskRenderNode for an inset shadow. [type GskInsetShadowNode] Returns an offset, in pixels gsk_inset_shadow_node_get_dy () gsk_inset_shadow_node_get_dy float gsk_inset_shadow_node_get_dy (GskRenderNode *node); Retrieves the vertical offset of the inset shadow. Parameters node a GskRenderNode for an inset shadow. [type GskInsetShadowNode] Returns an offset, in pixels gsk_inset_shadow_node_get_spread () gsk_inset_shadow_node_get_spread float gsk_inset_shadow_node_get_spread (GskRenderNode *node); Retrieves how much the shadow spreads inwards. Parameters node a GskRenderNode for an inset shadow. [type GskInsetShadowNode] Returns the size of the shadow, in pixels gsk_inset_shadow_node_get_blur_radius () gsk_inset_shadow_node_get_blur_radius float gsk_inset_shadow_node_get_blur_radius (GskRenderNode *node); Retrieves the blur radius to apply to the shadow. Parameters node a GskRenderNode for an inset shadow. [type GskInsetShadowNode] Returns the blur radius, in pixels gsk_outset_shadow_node_new () gsk_outset_shadow_node_new GskRenderNode * gsk_outset_shadow_node_new (const GskRoundedRect *outline, const GdkRGBA *color, float dx, float dy, float spread, float blur_radius); Creates a GskRenderNode that will render an outset shadow around the box given by outline . Parameters outline outline of the region surrounded by shadow color color of the shadow dx horizontal offset of shadow dy vertical offset of shadow spread how far the shadow spreads towards the inside blur_radius how much blur to apply to the shadow Returns A new GskRenderNode. [transfer full][type GskOutsetShadowNode] gsk_outset_shadow_node_get_outline () gsk_outset_shadow_node_get_outline const GskRoundedRect * gsk_outset_shadow_node_get_outline (GskRenderNode *node); Retrieves the outline rectangle of the outset shadow. Parameters node a GskRenderNode for an outset shadow. [type GskOutsetShadowNode] Returns a rounded rectangle. [transfer none] gsk_outset_shadow_node_get_color () gsk_outset_shadow_node_get_color const GdkRGBA * gsk_outset_shadow_node_get_color (GskRenderNode *node); Retrieves the color of the outset shadow. Parameters node a GskRenderNode for an outset shadow. [type GskOutsetShadowNode] Returns a color. [transfer none] gsk_outset_shadow_node_get_dx () gsk_outset_shadow_node_get_dx float gsk_outset_shadow_node_get_dx (GskRenderNode *node); Retrieves the horizontal offset of the outset shadow. Parameters node a GskRenderNode for an outset shadow. [type GskOutsetShadowNode] Returns an offset, in pixels gsk_outset_shadow_node_get_dy () gsk_outset_shadow_node_get_dy float gsk_outset_shadow_node_get_dy (GskRenderNode *node); Retrieves the vertical offset of the outset shadow. Parameters node a GskRenderNode for an outset shadow. [type GskOutsetShadowNode] Returns an offset, in pixels gsk_outset_shadow_node_get_spread () gsk_outset_shadow_node_get_spread float gsk_outset_shadow_node_get_spread (GskRenderNode *node); Retrieves how much the shadow spreads outwards. Parameters node a GskRenderNode for an outset shadow. [type GskOutsetShadowNode] Returns the size of the shadow, in pixels gsk_outset_shadow_node_get_blur_radius () gsk_outset_shadow_node_get_blur_radius float gsk_outset_shadow_node_get_blur_radius (GskRenderNode *node); Retrieves the blur radius of the shadow. Parameters node a GskRenderNode for an outset shadow. [type GskOutsetShadowNode] Returns the blur radius, in pixels gsk_cairo_node_new () gsk_cairo_node_new GskRenderNode * gsk_cairo_node_new (const graphene_rect_t *bounds); Creates a GskRenderNode that will render a cairo surface into the area given by bounds . You can draw to the cairo surface using gsk_cairo_node_get_draw_context() Parameters bounds the rectangle to render to Returns A new GskRenderNode. [transfer full][type GskCairoNode] gsk_cairo_node_get_draw_context () gsk_cairo_node_get_draw_context cairo_t * gsk_cairo_node_get_draw_context (GskRenderNode *node); Creates a Cairo context for drawing using the surface associated to the render node. If no surface exists yet, a surface will be created optimized for rendering to renderer . Parameters node a GskRenderNode for a Cairo surface. [type GskCairoNode] Returns a Cairo context used for drawing; use cairo_destroy() when done drawing. [transfer full] gsk_cairo_node_get_surface () gsk_cairo_node_get_surface cairo_surface_t * gsk_cairo_node_get_surface (GskRenderNode *node); Retrieves the Cairo surface used by the render node. Parameters node a GskRenderNode for a Cairo surface. [type GskCairoNode] Returns a Cairo surface. [transfer none] gsk_container_node_new () gsk_container_node_new GskRenderNode * gsk_container_node_new (GskRenderNode **children, guint n_children); Creates a new GskRenderNode instance for holding the given children . The new node will acquire a reference to each of the children. Parameters children The children of the node. [array length=n_children][transfer none] n_children Number of children in the children array Returns the new GskRenderNode. [transfer full][type GskContainerNode] gsk_container_node_get_n_children () gsk_container_node_get_n_children guint gsk_container_node_get_n_children (GskRenderNode *node); Retrieves the number of direct children of node . Parameters node a container GskRenderNode. [type GskContainerNode] Returns the number of children of the GskRenderNode gsk_container_node_get_child () gsk_container_node_get_child GskRenderNode * gsk_container_node_get_child (GskRenderNode *node, guint idx); Gets one of the children of container . Parameters node a container GskRenderNode. [type GskContainerNode] idx the position of the child to get Returns the idx 'th child of container . [transfer none] gsk_transform_node_new () gsk_transform_node_new GskRenderNode * gsk_transform_node_new (GskRenderNode *child, GskTransform *transform); Creates a GskRenderNode that will transform the given child with the given transform . Parameters child The node to transform transform The transform to apply. [transfer none] Returns A new GskRenderNode. [transfer full][type GskTransformNode] gsk_transform_node_get_child () gsk_transform_node_get_child GskRenderNode * gsk_transform_node_get_child (GskRenderNode *node); Gets the child node that is getting transformed by the given node . Parameters node a GskRenderNode for a transform. [type GskTransformNode] Returns The child that is getting transformed. [transfer none] gsk_transform_node_get_transform () gsk_transform_node_get_transform GskTransform * gsk_transform_node_get_transform (GskRenderNode *node); Retrieves the GskTransform used by the node . Parameters node a GskRenderNode for a transform. [type GskTransformNode] Returns a GskTransform. [transfer none] gsk_opacity_node_new () gsk_opacity_node_new GskRenderNode * gsk_opacity_node_new (GskRenderNode *child, float opacity); Creates a GskRenderNode that will drawn the child with reduced opacity . Parameters child The node to draw opacity The opacity to apply Returns A new GskRenderNode. [transfer full][type GskOpacityNode] gsk_opacity_node_get_child () gsk_opacity_node_get_child GskRenderNode * gsk_opacity_node_get_child (GskRenderNode *node); Gets the child node that is getting opacityed by the given node . Parameters node a GskRenderNode for an opacity. [type GskOpacityNode] Returns The child that is getting opacityed. [transfer none] gsk_opacity_node_get_opacity () gsk_opacity_node_get_opacity float gsk_opacity_node_get_opacity (GskRenderNode *node); Gets the transparency factor for an opacity node. Parameters node a GskRenderNode for an opacity. [type GskOpacityNode] Returns the opacity factor gsk_color_matrix_node_new () gsk_color_matrix_node_new GskRenderNode * gsk_color_matrix_node_new (GskRenderNode *child, const graphene_matrix_t *color_matrix, const graphene_vec4_t *color_offset); Creates a GskRenderNode that will drawn the child with reduced color_matrix . In particular, the node will transform the operation for every pixel. Parameters child The node to draw color_matrix The matrix to apply color_offset Values to add to the color Returns A new GskRenderNode. [transfer full][type GskColorMatrixNode] gsk_color_matrix_node_get_child () gsk_color_matrix_node_get_child GskRenderNode * gsk_color_matrix_node_get_child (GskRenderNode *node); Gets the child node that is getting its colors modified by the given node . Parameters node a color matrix GskRenderNode. [type GskColorMatrixNode] Returns The child that is getting its colors modified. [transfer none] gsk_color_matrix_node_get_color_matrix () gsk_color_matrix_node_get_color_matrix const graphene_matrix_t * gsk_color_matrix_node_get_color_matrix (GskRenderNode *node); Retrieves the color matrix used by the node . Parameters node a color matrix GskRenderNode. [type GskColorMatrixNode] Returns a 4x4 color matrix gsk_color_matrix_node_get_color_offset () gsk_color_matrix_node_get_color_offset const graphene_vec4_t * gsk_color_matrix_node_get_color_offset (GskRenderNode *node); Retrieves the color offset used by the node . Parameters node a color matrix GskRenderNode. [type GskColorMatrixNode] Returns a color vector gsk_repeat_node_new () gsk_repeat_node_new GskRenderNode * gsk_repeat_node_new (const graphene_rect_t *bounds, GskRenderNode *child, const graphene_rect_t *child_bounds); Creates a GskRenderNode that will repeat the drawing of child across the given bounds . Parameters bounds The bounds of the area to be painted child The child to repeat child_bounds The area of the child to repeat or NULL to use the child's bounds. [allow-none] Returns A new GskRenderNode. [transfer full][type GskRepeatNode] gsk_repeat_node_get_child () gsk_repeat_node_get_child GskRenderNode * gsk_repeat_node_get_child (GskRenderNode *node); Retrieves the child of node . Parameters node a repeat GskRenderNode. [type GskRepeatNode] Returns a GskRenderNode. [transfer none] gsk_repeat_node_get_child_bounds () gsk_repeat_node_get_child_bounds const graphene_rect_t * gsk_repeat_node_get_child_bounds (GskRenderNode *node); Retrieves the bounding rectangle of the child of node . Parameters node a repeat GskRenderNode. [type GskRepeatNode] Returns a bounding rectangle. [transfer none] gsk_clip_node_new () gsk_clip_node_new GskRenderNode * gsk_clip_node_new (GskRenderNode *child, const graphene_rect_t *clip); Creates a GskRenderNode that will clip the child to the area given by clip . Parameters child The node to draw clip The clip to apply Returns A new GskRenderNode. [transfer full][type GskClipNode] gsk_clip_node_get_child () gsk_clip_node_get_child GskRenderNode * gsk_clip_node_get_child (GskRenderNode *node); Gets the child node that is getting clipped by the given node . Parameters node a clip GskRenderNode . [type GskClipNode] Returns The child that is getting clipped. [transfer none] gsk_clip_node_get_clip () gsk_clip_node_get_clip const graphene_rect_t * gsk_clip_node_get_clip (GskRenderNode *node); Retrieves the clip rectangle for node . Parameters node a GskClipNode. [type GskClipNode] Returns a clip rectangle gsk_rounded_clip_node_new () gsk_rounded_clip_node_new GskRenderNode * gsk_rounded_clip_node_new (GskRenderNode *child, const GskRoundedRect *clip); Creates a GskRenderNode that will clip the child to the area given by clip . Parameters child The node to draw clip The clip to apply Returns A new GskRenderNode. [transfer none][type GskRoundedClipNode] gsk_rounded_clip_node_get_child () gsk_rounded_clip_node_get_child GskRenderNode * gsk_rounded_clip_node_get_child (GskRenderNode *node); Gets the child node that is getting clipped by the given node . Parameters node a rounded clip GskRenderNode. [type GskRoundedClipNode] Returns The child that is getting clipped. [transfer none] gsk_rounded_clip_node_get_clip () gsk_rounded_clip_node_get_clip const GskRoundedRect * gsk_rounded_clip_node_get_clip (GskRenderNode *node); Retrievs the rounded rectangle used to clip the contents of the node . Parameters node a rounded clip GskRenderNode. [type GskRoundedClipNode] Returns a rounded rectangle. [transfer none] gsk_shadow_node_new () gsk_shadow_node_new GskRenderNode * gsk_shadow_node_new (GskRenderNode *child, const GskShadow *shadows, gsize n_shadows); Creates a GskRenderNode that will draw a child with the given shadows below it. Parameters child The node to draw shadows The shadows to apply. [array length=n_shadows] n_shadows number of entries in the shadows array Returns A new GskRenderNode. [transfer full][type GskShadowNode] gsk_shadow_node_get_shadow () gsk_shadow_node_get_shadow const GskShadow * gsk_shadow_node_get_shadow (GskRenderNode *node, gsize i); Retrieves the shadow data at the given index i . Parameters node a shadow GskRenderNode. [type GskShadowNode] i the given index Returns the shadow data. [transfer none] gsk_shadow_node_get_n_shadows () gsk_shadow_node_get_n_shadows gsize gsk_shadow_node_get_n_shadows (GskRenderNode *node); Retrieves the number of shadows in the node . Parameters node a shadow GskRenderNode. [type GskShadowNode] Returns the number of shadows. gsk_shadow_node_get_child () gsk_shadow_node_get_child GskRenderNode * gsk_shadow_node_get_child (GskRenderNode *node); Retrieves the child GskRenderNode of the shadow node . Parameters node a shadow GskRenderNode. [type GskShadowNode] Returns the child render node. [transfer none] gsk_blend_node_new () gsk_blend_node_new GskRenderNode * gsk_blend_node_new (GskRenderNode *bottom, GskRenderNode *top, GskBlendMode blend_mode); Creates a GskRenderNode that will use blend_mode to blend the top node onto the bottom node. Parameters bottom The bottom node to be drawn top The node to be blended onto the bottom node blend_mode The blend mode to use Returns A new GskRenderNode. [transfer full][type GskBlendNode] gsk_blend_node_get_bottom_child () gsk_blend_node_get_bottom_child GskRenderNode * gsk_blend_node_get_bottom_child (GskRenderNode *node); Retrieves the bottom GskRenderNode child of the node . Parameters node a blending GskRenderNode. [type GskBlendNode] Returns the bottom child node. [transfer none] gsk_blend_node_get_top_child () gsk_blend_node_get_top_child GskRenderNode * gsk_blend_node_get_top_child (GskRenderNode *node); Retrieves the top GskRenderNode child of the node . Parameters node a blending GskRenderNode. [type GskBlendNode] Returns the top child node. [transfer none] gsk_blend_node_get_blend_mode () gsk_blend_node_get_blend_mode GskBlendMode gsk_blend_node_get_blend_mode (GskRenderNode *node); Retrieves the blend mode used by node . Parameters node a blending GskRenderNode. [type GskBlendNode] Returns the blend mode gsk_cross_fade_node_new () gsk_cross_fade_node_new GskRenderNode * gsk_cross_fade_node_new (GskRenderNode *start, GskRenderNode *end, float progress); Creates a GskRenderNode that will do a cross-fade between start and end . Parameters start The start node to be drawn end The node to be cross_fadeed onto the start node progress How far the fade has progressed from start to end. The value will be clamped to the range [0 ... 1] Returns A new GskRenderNode. [transfer full][type GskCrossFadeNode] gsk_cross_fade_node_get_start_child () gsk_cross_fade_node_get_start_child GskRenderNode * gsk_cross_fade_node_get_start_child (GskRenderNode *node); Retrieves the child GskRenderNode at the beginning of the cross-fade. Parameters node a cross-fading GskRenderNode. [type GskCrossFadeNode] Returns a GskRenderNode. [transfer none] gsk_cross_fade_node_get_end_child () gsk_cross_fade_node_get_end_child GskRenderNode * gsk_cross_fade_node_get_end_child (GskRenderNode *node); Retrieves the child GskRenderNode at the end of the cross-fade. Parameters node a cross-fading GskRenderNode. [type GskCrossFadeNode] Returns a GskRenderNode. [transfer none] gsk_cross_fade_node_get_progress () gsk_cross_fade_node_get_progress float gsk_cross_fade_node_get_progress (GskRenderNode *node); Retrieves the progress value of the cross fade. Parameters node a cross-fading GskRenderNode. [type GskCrossFadeNode] Returns the progress value, between 0 and 1 gsk_text_node_new () gsk_text_node_new GskRenderNode * gsk_text_node_new (PangoFont *font, PangoGlyphString *glyphs, const GdkRGBA *color, const graphene_point_t *offset); Creates a render node that renders the given glyphs, Note that color may not be used if the font contains color glyphs. Parameters font the PangoFont containing the glyphs glyphs the PangoGlyphString to render color the foreground color to render with offset offset of the baseline Returns a new GskRenderNode. [nullable][transfer full][type GskTextNode] gsk_text_node_get_font () gsk_text_node_get_font PangoFont * gsk_text_node_get_font (GskRenderNode *node); Returns the font used by the text node . Parameters node The GskRenderNode. [type GskTextNode] Returns the font. [transfer none] gsk_text_node_get_glyphs () gsk_text_node_get_glyphs const PangoGlyphInfo * gsk_text_node_get_glyphs (GskRenderNode *node, guint *n_glyphs); Retrieves the glyph information in the node . Parameters node a text GskRenderNode. [type GskTextNode] n_glyphs the number of glyphs returned. [out][optional] Returns the glyph information. [transfer none][array length=n_glyphs] gsk_text_node_get_color () gsk_text_node_get_color const GdkRGBA * gsk_text_node_get_color (GskRenderNode *node); Retrieves the color used by the text node . Parameters node a text GskRenderNode. [type GskTextNode] Returns the text color. [transfer none] gsk_text_node_has_color_glyphs () gsk_text_node_has_color_glyphs gboolean gsk_text_node_has_color_glyphs (GskRenderNode *node); Checks whether the text node has color glyphs. Parameters node a text GskRenderNode. [type GskTextNode] Returns TRUE if the text node has color glyphs gsk_text_node_get_num_glyphs () gsk_text_node_get_num_glyphs guint gsk_text_node_get_num_glyphs (GskRenderNode *node); Retrieves the number of glyphs in the text node. Parameters node a text GskRenderNode. [type GskTextNode] Returns the number of glyphs gsk_text_node_get_offset () gsk_text_node_get_offset const graphene_point_t * gsk_text_node_get_offset (GskRenderNode *node); Retrieves the offset applied to the text. Parameters node a text GskRenderNode. [type GskTextNode] Returns a point with the horizontal and vertical offsets. [transfer none] gsk_blur_node_new () gsk_blur_node_new GskRenderNode * gsk_blur_node_new (GskRenderNode *child, float radius); Creates a render node that blurs the child. Parameters child the child node to blur radius the blur radius Returns a new GskRenderNode. [transfer full][type GskBlurNode] gsk_blur_node_get_child () gsk_blur_node_get_child GskRenderNode * gsk_blur_node_get_child (GskRenderNode *node); Retrieves the child GskRenderNode of the blur node . Parameters node a blur GskRenderNode. [type GskBlurNode] Returns the blurred child node. [transfer none] gsk_blur_node_get_radius () gsk_blur_node_get_radius float gsk_blur_node_get_radius (GskRenderNode *node); Retrieves the blur radius of the node . Parameters node a blur GskRenderNode. [type GskBlurNode] Returns the blur radius gsk_debug_node_new () gsk_debug_node_new GskRenderNode * gsk_debug_node_new (GskRenderNode *child, char *message); Creates a GskRenderNode that will add debug information about the given child . Adding this node has no visual effect. Parameters child The child to add debug info for message The debug message. [transfer full] Returns A new GskRenderNode. [transfer full][type GskDebugNode] gsk_debug_node_get_child () gsk_debug_node_get_child GskRenderNode * gsk_debug_node_get_child (GskRenderNode *node); Gets the child node that is getting drawn by the given node . Parameters node a debug GskRenderNode. [type GskDebugNode] Returns the child GskRenderNode. [transfer none] gsk_debug_node_get_message () gsk_debug_node_get_message const char * gsk_debug_node_get_message (GskRenderNode *node); Gets the debug message that was set on this node Parameters node a debug GskRenderNode. [type GskDebugNode] Returns The debug message. [transfer none] gsk_gl_shader_node_new () gsk_gl_shader_node_new GskRenderNode * gsk_gl_shader_node_new (GskGLShader *shader, const graphene_rect_t *bounds, GBytes *args, GskRenderNode **children, guint n_children); Creates a GskRenderNode that will render the given shader into the area given by bounds . The args is a block of data to use for uniform input, as per types and offsets defined by the shader . Normally this is generated by gsk_gl_shader_format_args() or GskGLShaderArgBuilder. See GskGLShader for details about how the shader should be written. All the children will be rendered into textures (if they aren't already GskTextureNodes, which will be used directly). These textures will be sent as input to the shader. If the renderer doesn't support GL shaders, or if there is any problem when compiling the shader, then the node will draw pink. You should use gsk_gl_shader_compile() to ensure the shader will work for the renderer before using it. Parameters shader the GskGLShader bounds the rectangle to render the shader into args Arguments for the uniforms children array of child nodes, these will be rendered to textures and used as input. [array length=n_children] n_children Length of children (currenly the GL backend supports up to 4 children) Returns A new GskRenderNode. [transfer full][type GskGLShaderNode] gsk_gl_shader_node_get_n_children () gsk_gl_shader_node_get_n_children guint gsk_gl_shader_node_get_n_children (GskRenderNode *node); Returns the number of children Parameters node a GskRenderNode for a gl shader. [type GskGLShaderNode] Returns The number of children gsk_gl_shader_node_get_child () gsk_gl_shader_node_get_child GskRenderNode * gsk_gl_shader_node_get_child (GskRenderNode *node, guint idx); Gets one of the children. Parameters node a GskRenderNode for a gl shader. [type GskGLShaderNode] idx the position of the child to get Returns the idx 'th child of node . [transfer none] gsk_gl_shader_node_get_args () gsk_gl_shader_node_get_args GBytes * gsk_gl_shader_node_get_args (GskRenderNode *node); Gets args for the node. Parameters node a GskRenderNode for a gl shader. [type GskGLShaderNode] Returns A GBytes with the uniform arguments. [transfer none] gsk_gl_shader_node_get_shader () gsk_gl_shader_node_get_shader GskGLShader * gsk_gl_shader_node_get_shader (GskRenderNode *node); Gets shader code for the node. Parameters node a GskRenderNode for a gl shader. [type GskGLShaderNode] Returns the GskGLShader shader. [transfer none] Types and Values GskRenderNode GskRenderNode typedef struct _GskRenderNode GskRenderNode; A node in the render tree. GskBlendNode GskBlendNode typedef struct _GskBlendNode GskBlendNode; A render node applying a blending function between its two child nodes. GskBlurNode GskBlurNode typedef struct _GskBlurNode GskBlurNode; A render node applying a blur effect to its single child. GskBorderNode GskBorderNode typedef struct _GskBorderNode GskBorderNode; A render node for a border. GskCairoNode GskCairoNode typedef struct _GskCairoNode GskCairoNode; A render node for a Cairo surface. GskClipNode GskClipNode typedef struct _GskClipNode GskClipNode; A render node applying a rectangular clip to its single child node. GskColorMatrixNode GskColorMatrixNode typedef struct _GskColorMatrixNode GskColorMatrixNode; A render node controlling the color matrix of its single child node. GskColorNode GskColorNode typedef struct _GskColorNode GskColorNode; A render node for a solid color. GskConicGradientNode GskConicGradientNode typedef struct _GskConicGradientNode GskConicGradientNode; A render node for a conic gradient. GskContainerNode GskContainerNode typedef struct _GskContainerNode GskContainerNode; A render node that can contain other render nodes. GskCrossFadeNode GskCrossFadeNode typedef struct _GskCrossFadeNode GskCrossFadeNode; A render node cross fading between two child nodes. GskDebugNode GskDebugNode typedef struct _GskDebugNode GskDebugNode; A render node that emits a debugging message when drawing its child node. GskInsetShadowNode GskInsetShadowNode typedef struct _GskInsetShadowNode GskInsetShadowNode; A render node for an inset shadow. GskLinearGradientNode GskLinearGradientNode typedef struct _GskLinearGradientNode GskLinearGradientNode; A render node for a linear gradient. GskRadialGradientNode GskRadialGradientNode typedef struct _GskRadialGradientNode GskRadialGradientNode; A render node for a radial gradient. GskOpacityNode GskOpacityNode typedef struct _GskOpacityNode GskOpacityNode; A render node controlling the opacity of its single child node. GskOutsetShadowNode GskOutsetShadowNode typedef struct _GskOutsetShadowNode GskOutsetShadowNode; A render node for an outset shadow. GskRepeatingLinearGradientNode GskRepeatingLinearGradientNode typedef struct _GskRepeatingLinearGradientNode GskRepeatingLinearGradientNode; A render node for a repeating linear gradient. GskRepeatingRadialGradientNode GskRepeatingRadialGradientNode typedef struct _GskRepeatingRadialGradientNode GskRepeatingRadialGradientNode; A render node for a repeating radial gradient. GskRepeatNode GskRepeatNode typedef struct _GskRepeatNode GskRepeatNode; A render node repeating its single child node. GskRoundedClipNode GskRoundedClipNode typedef struct _GskRoundedClipNode GskRoundedClipNode; A render node applying a rounded rectangle clip to its single child. GskShadowNode GskShadowNode typedef struct _GskShadowNode GskShadowNode; A render node drawing one or more shadows behind its single child node. GskTextNode GskTextNode typedef struct _GskTextNode GskTextNode; A render node drawing a set of glyphs. GskTextureNode GskTextureNode typedef struct _GskTextureNode GskTextureNode; A render node for a GdkTexture. GskTransformNode GskTransformNode typedef struct _GskTransformNode GskTransformNode; A render node applying a GskTransform to its single child node. GskGLShaderNode GskGLShaderNode typedef struct _GskGLShaderNode GskGLShaderNode; A render node using a GL shader when drawing its children nodes. enum GskRenderNodeType GskRenderNodeType The type of a node determines what the node is rendering. Members GSK_NOT_A_RENDER_NODE Error type. No node will ever have this type. GSK_CONTAINER_NODE A node containing a stack of children GSK_CAIRO_NODE A node drawing a cairo_surface_t GSK_COLOR_NODE A node drawing a single color rectangle GSK_LINEAR_GRADIENT_NODE A node drawing a linear gradient GSK_REPEATING_LINEAR_GRADIENT_NODE A node drawing a repeating linear gradient GSK_RADIAL_GRADIENT_NODE A node drawing a radial gradient GSK_REPEATING_RADIAL_GRADIENT_NODE A node drawing a repeating radial gradient GSK_CONIC_GRADIENT_NODE A node drawing a conic gradient GSK_BORDER_NODE A node stroking a border around an area GSK_TEXTURE_NODE A node drawing a GdkTexture GSK_INSET_SHADOW_NODE A node drawing an inset shadow GSK_OUTSET_SHADOW_NODE A node drawing an outset shadow GSK_TRANSFORM_NODE A node that renders its child after applying a matrix transform GSK_OPACITY_NODE A node that changes the opacity of its child GSK_COLOR_MATRIX_NODE A node that applies a color matrix to every pixel GSK_REPEAT_NODE A node that repeats the child's contents GSK_CLIP_NODE A node that clips its child to a rectangular area GSK_ROUNDED_CLIP_NODE A node that clips its child to a rounded rectangle GSK_SHADOW_NODE A node that draws a shadow below its child GSK_BLEND_NODE A node that blends two children together GSK_CROSS_FADE_NODE A node that cross-fades between two children GSK_TEXT_NODE A node containing a glyph string GSK_BLUR_NODE A node that applies a blur GSK_DEBUG_NODE Debug information that does not affect the rendering GSK_GL_SHADER_NODE A node that uses OpenGL fragment shaders to render enum GskSerializationError GskSerializationError Errors that can happen during (de)serialization. Members GSK_SERIALIZATION_UNSUPPORTED_FORMAT The format can not be identified GSK_SERIALIZATION_UNSUPPORTED_VERSION The version of the data is not understood GSK_SERIALIZATION_INVALID_DATA The given data may not exist in a proper serialization struct GskParseLocation GskParseLocation struct GskParseLocation { gsize bytes; gsize chars; gsize lines; gsize line_bytes; gsize line_chars; }; A location in a parse buffer. Members gsize bytes; the offset of the location in the parse buffer, as bytes gsize chars; the offset of the location in the parse buffer, as characters gsize lines; the line of the location in the parse buffer gsize line_bytes; the position in the line, as bytes gsize line_chars; the position in the line, as characters enum GskScalingFilter GskScalingFilter The filters used when scaling texture data. The actual implementation of each filter is deferred to the rendering pipeline. Members GSK_SCALING_FILTER_LINEAR linear interpolation filter GSK_SCALING_FILTER_NEAREST nearest neighbor interpolation filter GSK_SCALING_FILTER_TRILINEAR linear interpolation along each axis, plus mipmap generation, with linear interpolation along the mipmap levels struct GskColorStop GskColorStop struct GskColorStop { float offset; GdkRGBA color; }; A color stop in a gradient node. Members float offset; the offset of the color stop GdkRGBA color; the color at the given offset struct GskShadow GskShadow struct GskShadow { GdkRGBA color; float dx; float dy; float radius; }; The shadow parameters in a shadow node. Members GdkRGBA color; the color of the shadow float dx; the horizontal offset of the shadow float dy; the vertical offset of the shadow float radius; the radius of the shadow enum GskBlendMode GskBlendMode The blend modes available for render nodes. The implementation of each blend mode is deferred to the rendering pipeline. See https://www.w3.org/TR/compositing-1/blending for more information on blending and blend modes. Members GSK_BLEND_MODE_DEFAULT The default blend mode, which specifies no blending GSK_BLEND_MODE_MULTIPLY The source color is multiplied by the destination and replaces the destination GSK_BLEND_MODE_SCREEN Multiplies the complements of the destination and source color values, then complements the result. GSK_BLEND_MODE_OVERLAY Multiplies or screens the colors, depending on the destination color value. This is the inverse of hard-list GSK_BLEND_MODE_DARKEN Selects the darker of the destination and source colors GSK_BLEND_MODE_LIGHTEN Selects the lighter of the destination and source colors GSK_BLEND_MODE_COLOR_DODGE Brightens the destination color to reflect the source color GSK_BLEND_MODE_COLOR_BURN Darkens the destination color to reflect the source color GSK_BLEND_MODE_HARD_LIGHT Multiplies or screens the colors, depending on the source color value GSK_BLEND_MODE_SOFT_LIGHT Darkens or lightens the colors, depending on the source color value GSK_BLEND_MODE_DIFFERENCE Subtracts the darker of the two constituent colors from the lighter color GSK_BLEND_MODE_EXCLUSION Produces an effect similar to that of the difference mode but lower in contrast GSK_BLEND_MODE_COLOR Creates a color with the hue and saturation of the source color and the luminosity of the destination color GSK_BLEND_MODE_HUE Creates a color with the hue of the source color and the saturation and luminosity of the destination color GSK_BLEND_MODE_SATURATION Creates a color with the saturation of the source color and the hue and luminosity of the destination color GSK_BLEND_MODE_LUMINOSITY Creates a color with the luminosity of the source color and the hue and saturation of the destination color docs/reference/gsk/xml/GskRoundedRect.xml0000664000175000017500000010014313766440675020606 0ustar mclasenmclasen ]> GskRoundedRect 3 GSK4 Library GskRoundedRect A rounded rectangle Functions #defineGSK_ROUNDED_RECT_INIT() GskRoundedRect * gsk_rounded_rect_init () GskRoundedRect * gsk_rounded_rect_init_copy () GskRoundedRect * gsk_rounded_rect_init_from_rect () GskRoundedRect * gsk_rounded_rect_normalize () GskRoundedRect * gsk_rounded_rect_offset () GskRoundedRect * gsk_rounded_rect_shrink () gboolean gsk_rounded_rect_is_rectilinear () gboolean gsk_rounded_rect_contains_point () gboolean gsk_rounded_rect_contains_rect () gboolean gsk_rounded_rect_intersects_rect () Types and Values enumGskCorner structGskRoundedRect Description GskRoundedRect defines a rectangle with rounded corners, as is commonly used in drawing. Operations on a GskRoundedRect will normalize the rectangle, to ensure that the bounds are normalized and that the corner sizes don't exceed the size of the rectangle. The algorithm used for normalizing corner sizes is described in the CSS specification. Functions GSK_ROUNDED_RECT_INIT() GSK_ROUNDED_RECT_INIT #define GSK_ROUNDED_RECT_INIT(_x,_y,_w,_h) Initializes a GskRoundedRect when declaring it. All corner sizes will be initialized to 0. Parameters _x the X coordinate of the origin _y the Y coordinate of the origin _w the width _h the height gsk_rounded_rect_init () gsk_rounded_rect_init GskRoundedRect * gsk_rounded_rect_init (GskRoundedRect *self, const graphene_rect_t *bounds, const graphene_size_t *top_left, const graphene_size_t *top_right, const graphene_size_t *bottom_right, const graphene_size_t *bottom_left); Initializes the given GskRoundedRect with the given values. This function will implicitly normalize the GskRoundedRect before returning. Parameters self The GskRoundedRect to initialize bounds a graphene_rect_t describing the bounds top_left the rounding radius of the top left corner top_right the rounding radius of the top right corner bottom_right the rounding radius of the bottom right corner bottom_left the rounding radius of the bottom left corner Returns the initialized rectangle. [transfer none] gsk_rounded_rect_init_copy () gsk_rounded_rect_init_copy GskRoundedRect * gsk_rounded_rect_init_copy (GskRoundedRect *self, const GskRoundedRect *src); Initializes self using the given src rectangle. This function will not normalize the GskRoundedRect, so make sure the source is normalized. Parameters self a GskRoundedRect src a GskRoundedRect Returns the initialized rectangle. [transfer none] gsk_rounded_rect_init_from_rect () gsk_rounded_rect_init_from_rect GskRoundedRect * gsk_rounded_rect_init_from_rect (GskRoundedRect *self, const graphene_rect_t *bounds, float radius); Initializes self to the given bounds and sets the radius of all four corners to radius . Parameters self a GskRoundedRect bounds a graphene_rect_t radius the border radius Returns the initialized rectangle. [transfer none] gsk_rounded_rect_normalize () gsk_rounded_rect_normalize GskRoundedRect * gsk_rounded_rect_normalize (GskRoundedRect *self); Normalizes the passed rectangle. this function will ensure that the bounds of the rectangle are normalized and ensure that the corner values are positive and the corners do not overlap. Parameters self a GskRoundedRect Returns the normalized rectangle. [transfer none] gsk_rounded_rect_offset () gsk_rounded_rect_offset GskRoundedRect * gsk_rounded_rect_offset (GskRoundedRect *self, float dx, float dy); Offsets the bound's origin by dx and dy . The size and corners of the rectangle are unchanged. Parameters self a GskRoundedRect dx the horizontal offset dy the vertical offset Returns the offset rectangle. [transfer none] gsk_rounded_rect_shrink () gsk_rounded_rect_shrink GskRoundedRect * gsk_rounded_rect_shrink (GskRoundedRect *self, float top, float right, float bottom, float left); Shrinks (or grows) the given rectangle by moving the 4 sides according to the offsets given. The corner radii will be changed in a way that tries to keep the center of the corner circle intact. This emulates CSS behavior. This function also works for growing rectangles if you pass negative values for the top , right , bottom or left . Parameters self The GskRoundedRect to shrink or grow top How far to move the top side downwards right How far to move the right side to the left bottom How far to move the bottom side upwards left How far to move the left side to the right Returns the resized GskRoundedRect. [transfer none] gsk_rounded_rect_is_rectilinear () gsk_rounded_rect_is_rectilinear gboolean gsk_rounded_rect_is_rectilinear (const GskRoundedRect *self); Checks if all corners of self are right angles and the rectangle covers all of its bounds. This information can be used to decide if gsk_clip_node_new() or gsk_rounded_clip_node_new() should be called. Parameters self the GskRoundedRect to check Returns TRUE if the rectangle is rectilinear gsk_rounded_rect_contains_point () gsk_rounded_rect_contains_point gboolean gsk_rounded_rect_contains_point (const GskRoundedRect *self, const graphene_point_t *point); Checks if the given point is inside the rounded rectangle. This function returns FALSE if the point is in the rounded corner areas. Parameters self a GskRoundedRect point the point to check Returns TRUE if the point is inside the rounded rectangle gsk_rounded_rect_contains_rect () gsk_rounded_rect_contains_rect gboolean gsk_rounded_rect_contains_rect (const GskRoundedRect *self, const graphene_rect_t *rect); Checks if the given rect is contained inside the rounded rectangle. This function returns FALSE if rect extends into one of the rounded corner areas. Parameters self a GskRoundedRect rect the rectangle to check Returns TRUE if the rect is fully contained inside the rounded rectangle gsk_rounded_rect_intersects_rect () gsk_rounded_rect_intersects_rect gboolean gsk_rounded_rect_intersects_rect (const GskRoundedRect *self, const graphene_rect_t *rect); Checks if part of the given rect is contained inside the rounded rectangle. This function returns FALSE if rect only extends into one of the rounded corner areas but not into the rounded rectangle itself. Parameters self a GskRoundedRect rect the rectangle to check Returns TRUE if the rect intersects with the rounded rectangle Types and Values enum GskCorner GskCorner The corner indices used by GskRoundedRect. Members GSK_CORNER_TOP_LEFT The top left corner GSK_CORNER_TOP_RIGHT The top right corner GSK_CORNER_BOTTOM_RIGHT The bottom right corner GSK_CORNER_BOTTOM_LEFT The bottom left corner struct GskRoundedRect GskRoundedRect struct GskRoundedRect { graphene_rect_t bounds; graphene_size_t corner[4]; }; A rectangular region with rounded corners. Application code should normalize rectangles using gsk_rounded_rect_normalize(); this function will ensure that the bounds of the rectangle are normalized and ensure that the corner values are positive and the corners do not overlap. All functions taking a GskRoundedRect as an argument will internally operate on a normalized copy; all functions returning a GskRoundedRect will always return a normalized one. Members graphene_rect_t bounds; the bounds of the rectangle graphene_size_t corner[4]; the size of the 4 rounded corners docs/reference/gsk/xml/GskTransform.xml0000664000175000017500000016255413766440675020361 0ustar mclasenmclasen ]> GskTransform 3 GSK4 Library GskTransform A description for transform operations Functions GskTransform * gsk_transform_ref () void gsk_transform_unref () GskTransformCategory gsk_transform_get_category () void gsk_transform_print () char * gsk_transform_to_string () gboolean gsk_transform_parse () void gsk_transform_to_matrix () void gsk_transform_to_2d () void gsk_transform_to_affine () void gsk_transform_to_translate () GskTransform * gsk_transform_transform () GskTransform * gsk_transform_invert () GskTransform * gsk_transform_matrix () GskTransform * gsk_transform_translate () GskTransform * gsk_transform_translate_3d () GskTransform * gsk_transform_rotate () GskTransform * gsk_transform_rotate_3d () GskTransform * gsk_transform_scale () GskTransform * gsk_transform_scale_3d () GskTransform * gsk_transform_perspective () gboolean gsk_transform_equal () void gsk_transform_transform_bounds () void gsk_transform_transform_point () Types and Values GskTransform enumGskTransformCategory Description GskTransform is an object to describe transform matrices. Unlike graphene_matrix_t, GskTransform retains the steps in how a transform was constructed, and allows inspecting them. It is modeled after the way CSS describes transforms. GskTransform objects are immutable and cannot be changed after creation. This means code can safely expose them as properties of objects without having to worry about others changing them. Functions gsk_transform_ref () gsk_transform_ref GskTransform * gsk_transform_ref (GskTransform *self); Acquires a reference on the given GskTransform. Parameters self a GskTransform. [allow-none] Returns the GskTransform with an additional reference. [transfer none] gsk_transform_unref () gsk_transform_unref void gsk_transform_unref (GskTransform *self); Releases a reference on the given GskTransform. If the reference was the last, the resources associated to the self are freed. Parameters self a GskTransform. [allow-none] gsk_transform_get_category () gsk_transform_get_category GskTransformCategory gsk_transform_get_category (GskTransform *self); Returns the category this transform belongs to. Parameters self A GskTransform. [allow-none] Returns The category of the transform gsk_transform_print () gsk_transform_print void gsk_transform_print (GskTransform *self, GString *string); Converts self into a human-readable string representation suitable for printing that can later be parsed with gsk_transform_parse(). Parameters self a GskTransform. [allow-none] string The string to print into gsk_transform_to_string () gsk_transform_to_string char * gsk_transform_to_string (GskTransform *self); Converts a matrix into a string that is suitable for printing and can later be parsed with gsk_transform_parse(). This is a wrapper around gsk_transform_print(), see that function for details. Parameters self a GskTransform. [allow-none] Returns A new string for self gsk_transform_parse () gsk_transform_parse gboolean gsk_transform_parse (const char *string, GskTransform **out_transform); Parses the given string into a transform and puts it in out_transform . Strings printed via gsk_transform_to_string() can be read in again successfully using this function. If string does not describe a valid transform, FALSE is returned and NULL is put in out_transform . Parameters string the string to parse out_transform The location to put the transform in. [out] Returns TRUE if string described a valid transform. gsk_transform_to_matrix () gsk_transform_to_matrix void gsk_transform_to_matrix (GskTransform *self, graphene_matrix_t *out_matrix); Computes the actual value of self and stores it in out_matrix . The previous value of out_matrix will be ignored. Parameters self a GskTransform. [allow-none] out_matrix The matrix to set. [out caller-allocates] gsk_transform_to_2d () gsk_transform_to_2d void gsk_transform_to_2d (GskTransform *self, float *out_xx, float *out_yx, float *out_xy, float *out_yy, float *out_dx, float *out_dy); Converts a GskTransform to a 2D transformation matrix. self must be a 2D transformation. If you are not sure, use gsk_transform_get_category() >= GSK_TRANSFORM_CATEGORY_2D to check. The returned values have the following layout: This function can be used to convert between a GskTransform and a matrix type from other 2D drawing libraries, in particular Cairo. Parameters self a 2D GskTransform out_xx return location for the xx member. [out] out_yx return location for the yx member. [out] out_xy return location for the xy member. [out] out_yy return location for the yy member. [out] out_dx return location for the x0 member. [out] out_dy return location for the y0 member. [out] gsk_transform_to_affine () gsk_transform_to_affine void gsk_transform_to_affine (GskTransform *self, float *out_scale_x, float *out_scale_y, float *out_dx, float *out_dy); Converts a GskTransform to 2D affine transformation factors. self must be a 2D transformation. If you are not sure, use gsk_transform_get_category() >= GSK_TRANSFORM_CATEGORY_2D_AFFINE to check. Parameters self a GskTransform out_scale_x return location for the scale factor in the x direction. [out] out_scale_y return location for the scale factor in the y direction. [out] out_dx return location for the translation in the x direction. [out] out_dy return location for the translation in the y direction. [out] gsk_transform_to_translate () gsk_transform_to_translate void gsk_transform_to_translate (GskTransform *self, float *out_dx, float *out_dy); Converts a GskTransform to a translation operation. self must be a 2D transformation. If you are not sure, use gsk_transform_get_category() >= GSK_TRANSFORM_CATEGORY_2D_TRANSLATE to check. Parameters self a GskTransform out_dx return location for the translation in the x direction. [out] out_dy return location for the translation in the y direction. [out] gsk_transform_transform () gsk_transform_transform GskTransform * gsk_transform_transform (GskTransform *next, GskTransform *other); Applies all the operations from other to next . Parameters next Transform to apply other to. [allow-none][transfer full] other Transform to apply. [allow-none] Returns The new transform gsk_transform_invert () gsk_transform_invert GskTransform * gsk_transform_invert (GskTransform *self); Inverts the given transform. If self is not invertible, NULL is returned. Note that inverting NULL also returns NULL, which is the correct inverse of NULL. If you need to differentiate between those cases, you should check self is not NULL before calling this function. Parameters self Transform to invert. [allow-none][transfer full] Returns The inverted transform or NULL if the transform cannot be inverted. [nullable] gsk_transform_matrix () gsk_transform_matrix GskTransform * gsk_transform_matrix (GskTransform *next, const graphene_matrix_t *matrix); Multiplies next with the given matrix . Parameters next the next transform. [allow-none][transfer full] matrix the matrix to multiply next with Returns The new transform gsk_transform_translate () gsk_transform_translate GskTransform * gsk_transform_translate (GskTransform *next, const graphene_point_t *point); Translates next in 2dimensional space by point . Parameters next the next transform. [allow-none][transfer full] point the point to translate the transform by Returns The new transform gsk_transform_translate_3d () gsk_transform_translate_3d GskTransform * gsk_transform_translate_3d (GskTransform *next, const graphene_point3d_t *point); Translates next by point . Parameters next the next transform. [allow-none][transfer full] point the point to translate the transform by Returns The new transform gsk_transform_rotate () gsk_transform_rotate GskTransform * gsk_transform_rotate (GskTransform *next, float angle); Rotates next angle degrees in 2D - or in 3Dspeak, around the z axis. Parameters next the next transform. [allow-none][transfer full] angle the rotation angle, in degrees (clockwise) Returns The new transform gsk_transform_rotate_3d () gsk_transform_rotate_3d GskTransform * gsk_transform_rotate_3d (GskTransform *next, float angle, const graphene_vec3_t *axis); Rotates next angle degrees around axis . For a rotation in 2D space, use gsk_transform_rotate(). Parameters next the next transform. [allow-none][transfer full] angle the rotation angle, in degrees (clockwise) axis The rotation axis Returns The new transform gsk_transform_scale () gsk_transform_scale GskTransform * gsk_transform_scale (GskTransform *next, float factor_x, float factor_y); Scales next in 2-dimensional space by the given factors. Use gsk_transform_scale_3d() to scale in all 3 dimensions. Parameters next the next transform. [allow-none][transfer full] factor_x scaling factor on the X axis factor_y scaling factor on the Y axis Returns The new transform gsk_transform_scale_3d () gsk_transform_scale_3d GskTransform * gsk_transform_scale_3d (GskTransform *next, float factor_x, float factor_y, float factor_z); Scales next by the given factors. Parameters next the next transform. [allow-none][transfer full] factor_x scaling factor on the X axis factor_y scaling factor on the Y axis factor_z scaling factor on the Z axis Returns The new transform gsk_transform_perspective () gsk_transform_perspective GskTransform * gsk_transform_perspective (GskTransform *next, float depth); Applies a perspective projection transform. This transform scales points in X and Y based on their Z value, scaling points with positive Z values away from the origin, and those with negative Z values towards the origin. Points on the z=0 plane are unchanged. Parameters next the next transform. [allow-none][transfer full] depth distance of the z=0 plane. Lower values give a more flattened pyramid and therefore a more pronounced perspective effect. Returns The new transform gsk_transform_equal () gsk_transform_equal gboolean gsk_transform_equal (GskTransform *first, GskTransform *second); Checks two transforms for equality. Parameters first the first transform second the second transform Returns TRUE if the two transforms perform the same operation. gsk_transform_transform_bounds () gsk_transform_transform_bounds void gsk_transform_transform_bounds (GskTransform *self, const graphene_rect_t *rect, graphene_rect_t *out_rect); Transforms a graphene_rect_t using the given transform self . The result is the bounding box containing the coplanar quad. Parameters self a GskTransform rect a graphene_rect_t out_rect return location for the bounds of the transformed rectangle. [out caller-allocates] gsk_transform_transform_point () gsk_transform_transform_point void gsk_transform_transform_point (GskTransform *self, const graphene_point_t *point, graphene_point_t *out_point); Transforms a graphene_point_t using the given transform self . Parameters self a GskTransform point a graphene_point_t out_point return location for the transformed point. [out caller-allocates] Types and Values GskTransform GskTransform typedef struct _GskTransform GskTransform; The GskTransform structure contains only private data. enum GskTransformCategory GskTransformCategory The categories of matrices relevant for GSK and GTK. Note that any category includes matrices of all later categories. So if you want to for example check if a matrix is a 2D matrix, category &gt;= GSK_TRANSFORM_CATEGORY_2D is the way to do this. Also keep in mind that rounding errors may cause matrices to not conform to their categories. Otherwise, matrix operations done via mutliplication will not worsen categories. So for the matrix multiplication C = A * B, category(C) = MIN (category(A), category(B)). Members GSK_TRANSFORM_CATEGORY_UNKNOWN The category of the matrix has not been determined. GSK_TRANSFORM_CATEGORY_ANY Analyzing the matrix concluded that it does not fit in any other category. GSK_TRANSFORM_CATEGORY_3D The matrix is a 3D matrix. This means that the w column (the last column) has the values (0, 0, 0, 1). GSK_TRANSFORM_CATEGORY_2D The matrix is a 2D matrix. This is equivalent to graphene_matrix_is_2d() returning TRUE. In particular, this means that Cairo can deal with the matrix. GSK_TRANSFORM_CATEGORY_2D_AFFINE The matrix is a combination of 2D scale and 2D translation operations. In particular, this means that any rectangle can be transformed exactly using this matrix. GSK_TRANSFORM_CATEGORY_2D_TRANSLATE The matrix is a 2D translation. GSK_TRANSFORM_CATEGORY_IDENTITY The matrix is the identity matrix. docs/reference/gsk/xml/GskGLShader.xml0000664000175000017500000024267113766440675020036 0ustar mclasenmclasen ]> GskGLShader 3 GSK4 Library GskGLShader Fragment shaders for GSK Functions GskGLShader * gsk_gl_shader_new_from_bytes () GskGLShader * gsk_gl_shader_new_from_resource () gboolean gsk_gl_shader_compile () GBytes * gsk_gl_shader_get_source () const char * gsk_gl_shader_get_resource () int gsk_gl_shader_get_n_textures () int gsk_gl_shader_get_n_uniforms () const char * gsk_gl_shader_get_uniform_name () int gsk_gl_shader_find_uniform_by_name () GskGLUniformType gsk_gl_shader_get_uniform_type () int gsk_gl_shader_get_uniform_offset () gsize gsk_gl_shader_get_args_size () float gsk_gl_shader_get_arg_float () gint32 gsk_gl_shader_get_arg_int () guint32 gsk_gl_shader_get_arg_uint () gboolean gsk_gl_shader_get_arg_bool () void gsk_gl_shader_get_arg_vec2 () void gsk_gl_shader_get_arg_vec3 () void gsk_gl_shader_get_arg_vec4 () GBytes * gsk_gl_shader_format_args_va () GBytes * gsk_gl_shader_format_args () GskShaderArgsBuilder * gsk_shader_args_builder_new () GBytes * gsk_shader_args_builder_to_args () GBytes * gsk_shader_args_builder_free_to_args () void gsk_shader_args_builder_unref () GskShaderArgsBuilder * gsk_shader_args_builder_ref () void gsk_shader_args_builder_set_float () void gsk_shader_args_builder_set_int () void gsk_shader_args_builder_set_uint () void gsk_shader_args_builder_set_bool () void gsk_shader_args_builder_set_vec2 () void gsk_shader_args_builder_set_vec3 () void gsk_shader_args_builder_set_vec4 () Properties char *resourceRead / Write / Construct Only GBytes *sourceRead / Write / Construct Only Types and Values GskGLShader enumGskGLUniformType GskShaderArgsBuilder Object Hierarchy GObject ╰── GskGLShader Description A GskGLShader is a snippet of GLSL that is meant to run in the fragment shader of the rendering pipeline. A fragment shader gets the coordinates being rendered as input and produces the pixel values for that particular pixel. Additionally, the shader can declare a set of other input arguments, called uniforms (as they are uniform over all the calls to your shader in each instance of use). A shader can also receive up to 4 textures that it can use as input when producing the pixel data. GskGLShader is usually used with gtk_snapshot_push_gl_shader() to produce a GskGLShaderNode in the rendering hierarchy, and then its input textures are constructed by rendering the child nodes to textures before rendering the shader node itself. (You can pass texture nodes as children if you want to directly use a texture as input). The actual shader code is GLSL code that gets combined with some other code into the fragment shader. Since the exact capabilities of the GPU driver differs between different OpenGL drivers and hardware, GTK adds some defines that you can use to ensure your GLSL code runs on as many drivers as it can. If the OpenGL driver is GLES, then the shader language version is set to 100, and GSK_GLES will be defined in the shader. Otherwise, if the OpenGL driver does not support the 3.2 core profile, then the shader will run with language version 110 for GL2 and 130 for GL3, and GSK_LEGACY will be defined in the shader. If the OpenGL driver supports the 3.2 code profile, it will be used, the shader language version is set to 150, and GSK_GL3 will be defined in the shader. The main function the shader must implement is: Where the input fragCoord is the coordinate of the pixel we're currently rendering, relative to the boundary rectangle that was specified in the GskGLShaderNode, and resolution is the width and height of that rectangle. This is in the typical GTK coordinate system with the origin in the top left. uv contains the u and v coordinates that can be used to index a texture at the corresponding point. These coordinates are in the [0..1]x[0..1] region, with 0, 0 being in the lower left corder (which is typical for OpenGL). The output fragColor should be a RGBA color (with premultiplied alpha) that will be used as the output for the specified pixel location. Note that this output will be automatically clipped to the clip region of the glshader node. In addition to the function arguments the shader can define up to 4 uniforms for textures which must be called u_textureN (i.e. u_texture1 to u_texture4) as well as any custom uniforms you want of types int, uint, bool, float, vec2, vec3 or vec4. All textures sources contain premultiplied alpha colors, but if some there are outer sources of colors there is a gsk_premultiply() helper to compute premultiplication when needed. Note that GTK parses the uniform declarations, so each uniform has to be on a line by itself with no other code, like so: GTK uses the the "gsk" namespace in the symbols it uses in the shader, so your code should not use any symbols with the prefix gsk or GSK. There are some helper functions declared that you can use: This samples a texture (e.g. u_texture1) at the specified coordinates, and containes some helper ifdefs to ensure that it works on all OpenGL versions. You can compile the shader yourself using gsk_gl_shader_compile(), otherwise the GSK renderer will do it when it handling the glshader node. If errors occurs, the returned error will include the glsl sources, so you can see what GSK was passing to the compiler. You can also set GSK_DEBUG=shaders in the environment to see the sources and other relevant information about all shaders that GSK is handling. An example shader Functions gsk_gl_shader_new_from_bytes () gsk_gl_shader_new_from_bytes GskGLShader * gsk_gl_shader_new_from_bytes (GBytes *sourcecode); Creates a GskGLShader that will render pixels using the specified code. Parameters sourcecode GLSL sourcecode for the shader, as a GBytes Returns A new GskGLShader. [transfer full] gsk_gl_shader_new_from_resource () gsk_gl_shader_new_from_resource GskGLShader * gsk_gl_shader_new_from_resource (const char *resource_path); Creates a GskGLShader that will render pixels using the specified code. Parameters resource_path path to a resource that contains the GLSL sourcecode for the shader Returns A new GskGLShader. [transfer full] gsk_gl_shader_compile () gsk_gl_shader_compile gboolean gsk_gl_shader_compile (GskGLShader *shader, GskRenderer *renderer, GError **error); Tries to compile the shader for the given renderer , and reports FALSE with an error if there is a problem. You should use this function before relying on the shader for rendering and use a fallback with a simpler shader or without shaders if it fails. Note that this will modify the rendering state (for example change the current GL context) and requires the renderer to be set up. This means that the widget has to be realized. Commonly you want to call this from the realize signal of a widget, or during widget snapshot. Parameters shader a GskGLShader renderer a GskRenderer error location to store error in Returns TRUE on success, FALSE if an error occurred gsk_gl_shader_get_source () gsk_gl_shader_get_source GBytes * gsk_gl_shader_get_source (GskGLShader *shader); Gets the GLSL sourcecode being used to render this shader. Parameters shader a GskGLShader Returns The source code for the shader. [transfer none] gsk_gl_shader_get_resource () gsk_gl_shader_get_resource const char * gsk_gl_shader_get_resource (GskGLShader *shader); Gets the resource path for the GLSL sourcecode being used to render this shader. Parameters shader a GskGLShader Returns The resource path for the shader, or NULL if none. [transfer none] gsk_gl_shader_get_n_textures () gsk_gl_shader_get_n_textures int gsk_gl_shader_get_n_textures (GskGLShader *shader); Returns the number of textures that the shader requires. This can be used to check that the a passed shader works in your usecase. It is determined by looking at the highest u_textureN value that the shader defines. Parameters shader a GskGLShader Returns The number of texture inputs required by shader gsk_gl_shader_get_n_uniforms () gsk_gl_shader_get_n_uniforms int gsk_gl_shader_get_n_uniforms (GskGLShader *shader); Get the number of declared uniforms for this shader. Parameters shader a GskGLShader Returns The number of declared uniforms gsk_gl_shader_get_uniform_name () gsk_gl_shader_get_uniform_name const char * gsk_gl_shader_get_uniform_name (GskGLShader *shader, int idx); Get the name of the declared uniform for this shader at index idx . Parameters shader a GskGLShader idx index of the uniform Returns The name of the declared uniform. [transfer none] gsk_gl_shader_find_uniform_by_name () gsk_gl_shader_find_uniform_by_name int gsk_gl_shader_find_uniform_by_name (GskGLShader *shader, const char *name); Looks for a uniform by the name name , and returns the index of the uniform, or -1 if it was not found. Parameters shader a GskGLShader name uniform name Returns The index of the uniform, or -1 gsk_gl_shader_get_uniform_type () gsk_gl_shader_get_uniform_type GskGLUniformType gsk_gl_shader_get_uniform_type (GskGLShader *shader, int idx); Get the type of the declared uniform for this shader at index idx . Parameters shader a GskGLShader idx index of the uniform Returns The type of the declared uniform gsk_gl_shader_get_uniform_offset () gsk_gl_shader_get_uniform_offset int gsk_gl_shader_get_uniform_offset (GskGLShader *shader, int idx); Get the offset into the data block where data for this uniforms is stored. Parameters shader a GskGLShader idx index of the uniform Returns The data offset gsk_gl_shader_get_args_size () gsk_gl_shader_get_args_size gsize gsk_gl_shader_get_args_size (GskGLShader *shader); Get the size of the data block used to specify arguments for this shader. Parameters shader a GskGLShader Returns The size of the data block gsk_gl_shader_get_arg_float () gsk_gl_shader_get_arg_float float gsk_gl_shader_get_arg_float (GskGLShader *shader, GBytes *args, int idx); Gets the value of the uniform idx in the args block. The uniform must be of float type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform Returns The value gsk_gl_shader_get_arg_int () gsk_gl_shader_get_arg_int gint32 gsk_gl_shader_get_arg_int (GskGLShader *shader, GBytes *args, int idx); Gets the value of the uniform idx in the args block. The uniform must be of int type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform Returns The value gsk_gl_shader_get_arg_uint () gsk_gl_shader_get_arg_uint guint32 gsk_gl_shader_get_arg_uint (GskGLShader *shader, GBytes *args, int idx); Gets the value of the uniform idx in the args block. The uniform must be of uint type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform Returns The value gsk_gl_shader_get_arg_bool () gsk_gl_shader_get_arg_bool gboolean gsk_gl_shader_get_arg_bool (GskGLShader *shader, GBytes *args, int idx); Gets the value of the uniform idx in the args block. The uniform must be of bool type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform Returns The value gsk_gl_shader_get_arg_vec2 () gsk_gl_shader_get_arg_vec2 void gsk_gl_shader_get_arg_vec2 (GskGLShader *shader, GBytes *args, int idx, graphene_vec2_t *out_value); Gets the value of the uniform idx in the args block. The uniform must be of vec2 type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform out_value location to store the uniform value in gsk_gl_shader_get_arg_vec3 () gsk_gl_shader_get_arg_vec3 void gsk_gl_shader_get_arg_vec3 (GskGLShader *shader, GBytes *args, int idx, graphene_vec3_t *out_value); Gets the value of the uniform idx in the args block. The uniform must be of vec3 type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform out_value location to store the uniform value in gsk_gl_shader_get_arg_vec4 () gsk_gl_shader_get_arg_vec4 void gsk_gl_shader_get_arg_vec4 (GskGLShader *shader, GBytes *args, int idx, graphene_vec4_t *out_value); Gets the value of the uniform idx in the args block. The uniform must be of vec4 type. Parameters shader a GskGLShader args uniform arguments idx index of the uniform out_value location to store set the uniform value in gsk_gl_shader_format_args_va () gsk_gl_shader_format_args_va GBytes * gsk_gl_shader_format_args_va (GskGLShader *shader, va_list uniforms); Formats the uniform data as needed for feeding the named uniforms values into the shader. The argument list is a list of pairs of names, and values for the types that match the declared uniforms (i.e. double/int/guint/gboolean for primitive values and graphene_vecN_t * for vecN uniforms). It is an error to pass a uniform name that is not declared by the shader. Any uniforms of the shader that are not included in the argument list are zero-initialized. Parameters shader a GskGLShader uniforms name-Value pairs for the uniforms of shader , ending with a NULL name Returns A newly allocated block of data which can be passed to gsk_gl_shader_node_new(). [transfer full] gsk_gl_shader_format_args () gsk_gl_shader_format_args GBytes * gsk_gl_shader_format_args (GskGLShader *shader, ...); Formats the uniform data as needed for feeding the named uniforms values into the shader. The argument list is a list of pairs of names, and values for the types that match the declared uniforms (i.e. double/int/guint/gboolean for primitive values and graphene_vecN_t * for vecN uniforms). Any uniforms of the shader that are not included in the argument list are zero-initialized. Parameters shader a GskGLShader ... name-Value pairs for the uniforms of shader , ending with a NULL name Returns A newly allocated block of data which can be passed to gsk_gl_shader_node_new(). [transfer full] gsk_shader_args_builder_new () gsk_shader_args_builder_new GskShaderArgsBuilder * gsk_shader_args_builder_new (GskGLShader *shader, GBytes *initial_values); Allocates a builder that can be used to construct a new uniform data chunk. Parameters shader a GskGLShader initial_values optional Bytes with initial values. [nullable] Returns The newly allocated builder, free with gsk_shader_args_builder_unref(). [transfer full] gsk_shader_args_builder_to_args () gsk_shader_args_builder_to_args GBytes * gsk_shader_args_builder_to_args (GskShaderArgsBuilder *builder); Creates a new GBytes args from the current state of the given builder . Any uniforms of the shader that have not been explicitly set on the builder are zero-initialized. The given GskShaderArgsBuilder is reset once this function returns; you cannot call this function multiple times on the same builder instance. This function is intended primarily for bindings. C code should use gsk_shader_args_builder_free_to_args(). Parameters builder a GskShaderArgsBuilder Returns the newly allocated builder, free with gsk_shader_args_builder_free(). [transfer full] gsk_shader_args_builder_free_to_args () gsk_shader_args_builder_free_to_args GBytes * gsk_shader_args_builder_free_to_args (GskShaderArgsBuilder *builder); Creates a new GBytes args from the current state of the given builder , and frees the builder instance. Any uniforms of the shader that have not been explicitly set on the builder are zero-initialized. [skip] Parameters builder a GskShaderArgsBuilder Returns the newly created GBytes with all the args added to builder . [transfer full] gsk_shader_args_builder_unref () gsk_shader_args_builder_unref void gsk_shader_args_builder_unref (GskShaderArgsBuilder *builder); Decreases the reference count of a GskShaderArgBuilder by one. If the resulting reference count is zero, frees the builder. Parameters builder a GskShaderArgsBuilder gsk_shader_args_builder_ref () gsk_shader_args_builder_ref GskShaderArgsBuilder * gsk_shader_args_builder_ref (GskShaderArgsBuilder *builder); Increases the reference count of a GskShaderArgsBuilder by one. Parameters builder a GskShaderArgsBuilder Returns the passed in GskShaderArgsBuilder gsk_shader_args_builder_set_float () gsk_shader_args_builder_set_float void gsk_shader_args_builder_set_float (GskShaderArgsBuilder *builder, int idx, float value); Sets the value of the uniform idx . The uniform must be of float type. Parameters builder a GskShaderArgsBuilder idx index of the uniform value value to set the uniform to gsk_shader_args_builder_set_int () gsk_shader_args_builder_set_int void gsk_shader_args_builder_set_int (GskShaderArgsBuilder *builder, int idx, gint32 value); Sets the value of the uniform idx . The uniform must be of int type. Parameters builder a GskShaderArgsBuilder idx index of the uniform value value to set the uniform to gsk_shader_args_builder_set_uint () gsk_shader_args_builder_set_uint void gsk_shader_args_builder_set_uint (GskShaderArgsBuilder *builder, int idx, guint32 value); Sets the value of the uniform idx . The uniform must be of uint type. Parameters builder a GskShaderArgsBuilder idx index of the uniform value value to set the uniform to gsk_shader_args_builder_set_bool () gsk_shader_args_builder_set_bool void gsk_shader_args_builder_set_bool (GskShaderArgsBuilder *builder, int idx, gboolean value); Sets the value of the uniform idx . The uniform must be of bool type. Parameters builder a GskShaderArgsBuilder idx index of the uniform value value to set the uniform to gsk_shader_args_builder_set_vec2 () gsk_shader_args_builder_set_vec2 void gsk_shader_args_builder_set_vec2 (GskShaderArgsBuilder *builder, int idx, const graphene_vec2_t *value); Sets the value of the uniform idx . The uniform must be of vec2 type. Parameters builder A GskShaderArgsBuilder idx index of the uniform value value to set the uniform too gsk_shader_args_builder_set_vec3 () gsk_shader_args_builder_set_vec3 void gsk_shader_args_builder_set_vec3 (GskShaderArgsBuilder *builder, int idx, const graphene_vec3_t *value); Sets the value of the uniform idx . The uniform must be of vec3 type. Parameters builder a GskShaderArgsBuilder idx index of the uniform value value to set the uniform too gsk_shader_args_builder_set_vec4 () gsk_shader_args_builder_set_vec4 void gsk_shader_args_builder_set_vec4 (GskShaderArgsBuilder *builder, int idx, const graphene_vec4_t *value); Sets the value of the uniform idx . The uniform must be of vec4 type. Parameters builder a GskShaderArgsBuilder idx index of the uniform value value to set the uniform too Types and Values GskGLShader GskGLShader typedef struct _GskGLShader GskGLShader; An object representing a GL shader program. enum GskGLUniformType GskGLUniformType This defines the types of the uniforms that GskGLShaders declare. It defines both what the type is called in the GLSL shader code, and what the corresponding C type is on the Gtk side. Members GSK_GL_UNIFORM_TYPE_NONE No type, used for uninitialized or unspecified values. GSK_GL_UNIFORM_TYPE_FLOAT A float uniform GSK_GL_UNIFORM_TYPE_INT A GLSL int / gint32 uniform GSK_GL_UNIFORM_TYPE_UINT A GLSL uint / guint32 uniform GSK_GL_UNIFORM_TYPE_BOOL A GLSL bool / gboolean uniform GSK_GL_UNIFORM_TYPE_VEC2 A GLSL vec2 / graphene_vec2_t uniform GSK_GL_UNIFORM_TYPE_VEC3 A GLSL vec3 / graphene_vec3_t uniform GSK_GL_UNIFORM_TYPE_VEC4 A GLSL vec4 / graphene_vec4_t uniform GskShaderArgsBuilder GskShaderArgsBuilder typedef struct _GskShaderArgsBuilder GskShaderArgsBuilder; An object to build the uniforms data for a GskGLShader. Property Details The <literal>“resource”</literal> property GskGLShader:resource “resource” char * Resource containing the source code for the shader. If the shader source is not coming from a resource, this will be NULL. Owner: GskGLShader Flags: Read / Write / Construct Only Default value: NULL The <literal>“source”</literal> property GskGLShader:source “source” GBytes * The sourcecode for the shader.Owner: GskGLShader Flags: Read / Write / Construct Only docs/reference/gsk/xml/gsk4-doc.top0000664000175000017500000000000013766440675017327 0ustar mclasenmclasendocs/reference/gsk/xml/gsk4-doc.bottom0000664000175000017500000000034713766440675020047 0ustar mclasenmclasen docs/reference/gsk/xml/tree_index.sgml0000664000175000017500000000115213766440675020213 0ustar mclasenmclasen ]> GObject ├── GskRenderer ╰── GskGLShader GskRenderNode docs/reference/gsk/xml/object_index.sgml0000664000175000017500000000134713766440675020530 0ustar mclasenmclasen ]> GObject GskGLShader GskRenderNode GskRenderer docs/reference/gsk/xml/api-index-full.xml0000664000175000017500000014543313766440675020554 0ustar mclasenmclasen ]> B GskBlendMode, enum in GskRenderNode GskBlendNode, struct in GskRenderNode gsk_blend_node_get_blend_mode, function in GskRenderNode gsk_blend_node_get_bottom_child, function in GskRenderNode gsk_blend_node_get_top_child, function in GskRenderNode gsk_blend_node_new, function in GskRenderNode GskBlurNode, struct in GskRenderNode gsk_blur_node_get_child, function in GskRenderNode gsk_blur_node_get_radius, function in GskRenderNode gsk_blur_node_new, function in GskRenderNode GskBorderNode, struct in GskRenderNode gsk_border_node_get_colors, function in GskRenderNode gsk_border_node_get_outline, function in GskRenderNode gsk_border_node_get_widths, function in GskRenderNode gsk_border_node_new, function in GskRenderNode gsk_broadway_renderer_new, function in GskRenderer C GskCairoNode, struct in GskRenderNode gsk_cairo_node_get_draw_context, function in GskRenderNode gsk_cairo_node_get_surface, function in GskRenderNode gsk_cairo_node_new, function in GskRenderNode gsk_cairo_renderer_new, function in GskRenderer GskClipNode, struct in GskRenderNode gsk_clip_node_get_child, function in GskRenderNode gsk_clip_node_get_clip, function in GskRenderNode gsk_clip_node_new, function in GskRenderNode GskColorMatrixNode, struct in GskRenderNode GskColorNode, struct in GskRenderNode GskColorStop, struct in GskRenderNode gsk_color_matrix_node_get_child, function in GskRenderNode gsk_color_matrix_node_get_color_matrix, function in GskRenderNode gsk_color_matrix_node_get_color_offset, function in GskRenderNode gsk_color_matrix_node_new, function in GskRenderNode gsk_color_node_get_color, function in GskRenderNode gsk_color_node_new, function in GskRenderNode GskConicGradientNode, struct in GskRenderNode gsk_conic_gradient_node_get_center, function in GskRenderNode gsk_conic_gradient_node_get_color_stops, function in GskRenderNode gsk_conic_gradient_node_get_n_color_stops, function in GskRenderNode gsk_conic_gradient_node_get_rotation, function in GskRenderNode gsk_conic_gradient_node_new, function in GskRenderNode GskContainerNode, struct in GskRenderNode gsk_container_node_get_child, function in GskRenderNode gsk_container_node_get_n_children, function in GskRenderNode gsk_container_node_new, function in GskRenderNode GskCorner, enum in GskRoundedRect GskCrossFadeNode, struct in GskRenderNode gsk_cross_fade_node_get_end_child, function in GskRenderNode gsk_cross_fade_node_get_progress, function in GskRenderNode gsk_cross_fade_node_get_start_child, function in GskRenderNode gsk_cross_fade_node_new, function in GskRenderNode D GskDebugNode, struct in GskRenderNode gsk_debug_node_get_child, function in GskRenderNode gsk_debug_node_get_message, function in GskRenderNode gsk_debug_node_new, function in GskRenderNode G GskGLShader, struct in GskGLShader GskGLShader:resource, object property in GskGLShader GskGLShader:source, object property in GskGLShader GskGLShaderNode, struct in GskRenderNode GskGLUniformType, enum in GskGLShader gsk_gl_renderer_new, function in GskRenderer gsk_gl_shader_compile, function in GskGLShader gsk_gl_shader_find_uniform_by_name, function in GskGLShader gsk_gl_shader_format_args, function in GskGLShader gsk_gl_shader_format_args_va, function in GskGLShader gsk_gl_shader_get_args_size, function in GskGLShader gsk_gl_shader_get_arg_bool, function in GskGLShader gsk_gl_shader_get_arg_float, function in GskGLShader gsk_gl_shader_get_arg_int, function in GskGLShader gsk_gl_shader_get_arg_uint, function in GskGLShader gsk_gl_shader_get_arg_vec2, function in GskGLShader gsk_gl_shader_get_arg_vec3, function in GskGLShader gsk_gl_shader_get_arg_vec4, function in GskGLShader gsk_gl_shader_get_n_textures, function in GskGLShader gsk_gl_shader_get_n_uniforms, function in GskGLShader gsk_gl_shader_get_resource, function in GskGLShader gsk_gl_shader_get_source, function in GskGLShader gsk_gl_shader_get_uniform_name, function in GskGLShader gsk_gl_shader_get_uniform_offset, function in GskGLShader gsk_gl_shader_get_uniform_type, function in GskGLShader gsk_gl_shader_new_from_bytes, function in GskGLShader gsk_gl_shader_new_from_resource, function in GskGLShader gsk_gl_shader_node_get_args, function in GskRenderNode gsk_gl_shader_node_get_child, function in GskRenderNode gsk_gl_shader_node_get_n_children, function in GskRenderNode gsk_gl_shader_node_get_shader, function in GskRenderNode gsk_gl_shader_node_new, function in GskRenderNode I GskInsetShadowNode, struct in GskRenderNode gsk_inset_shadow_node_get_blur_radius, function in GskRenderNode gsk_inset_shadow_node_get_color, function in GskRenderNode gsk_inset_shadow_node_get_dx, function in GskRenderNode gsk_inset_shadow_node_get_dy, function in GskRenderNode gsk_inset_shadow_node_get_outline, function in GskRenderNode gsk_inset_shadow_node_get_spread, function in GskRenderNode gsk_inset_shadow_node_new, function in GskRenderNode L GskLinearGradientNode, struct in GskRenderNode gsk_linear_gradient_node_get_color_stops, function in GskRenderNode gsk_linear_gradient_node_get_end, function in GskRenderNode gsk_linear_gradient_node_get_n_color_stops, function in GskRenderNode gsk_linear_gradient_node_get_start, function in GskRenderNode gsk_linear_gradient_node_new, function in GskRenderNode O GskOpacityNode, struct in GskRenderNode gsk_opacity_node_get_child, function in GskRenderNode gsk_opacity_node_get_opacity, function in GskRenderNode gsk_opacity_node_new, function in GskRenderNode GskOutsetShadowNode, struct in GskRenderNode gsk_outset_shadow_node_get_blur_radius, function in GskRenderNode gsk_outset_shadow_node_get_color, function in GskRenderNode gsk_outset_shadow_node_get_dx, function in GskRenderNode gsk_outset_shadow_node_get_dy, function in GskRenderNode gsk_outset_shadow_node_get_outline, function in GskRenderNode gsk_outset_shadow_node_get_spread, function in GskRenderNode gsk_outset_shadow_node_new, function in GskRenderNode P GskParseErrorFunc, user_function in GskRenderNode GskParseLocation, struct in GskRenderNode R GskRadialGradientNode, struct in GskRenderNode gsk_radial_gradient_node_get_center, function in GskRenderNode gsk_radial_gradient_node_get_color_stops, function in GskRenderNode gsk_radial_gradient_node_get_end, function in GskRenderNode gsk_radial_gradient_node_get_hradius, function in GskRenderNode gsk_radial_gradient_node_get_n_color_stops, function in GskRenderNode gsk_radial_gradient_node_get_start, function in GskRenderNode gsk_radial_gradient_node_get_vradius, function in GskRenderNode gsk_radial_gradient_node_new, function in GskRenderNode GskRenderer, struct in GskRenderer GskRenderer:realized, object property in GskRenderer GskRenderer:surface, object property in GskRenderer gsk_renderer_get_surface, function in GskRenderer gsk_renderer_is_realized, function in GskRenderer gsk_renderer_new_for_surface, function in GskRenderer gsk_renderer_realize, function in GskRenderer gsk_renderer_render, function in GskRenderer gsk_renderer_render_texture, function in GskRenderer gsk_renderer_unrealize, function in GskRenderer GskRenderNode, struct in GskRenderNode GskRenderNodeType, enum in GskRenderNode gsk_render_node_deserialize, function in GskRenderNode gsk_render_node_draw, function in GskRenderNode gsk_render_node_get_bounds, function in GskRenderNode gsk_render_node_get_node_type, function in GskRenderNode gsk_render_node_ref, function in GskRenderNode gsk_render_node_serialize, function in GskRenderNode gsk_render_node_unref, function in GskRenderNode gsk_render_node_write_to_file, function in GskRenderNode GskRepeatingLinearGradientNode, struct in GskRenderNode GskRepeatingRadialGradientNode, struct in GskRenderNode gsk_repeating_linear_gradient_node_new, function in GskRenderNode gsk_repeating_radial_gradient_node_new, function in GskRenderNode GskRepeatNode, struct in GskRenderNode gsk_repeat_node_get_child, function in GskRenderNode gsk_repeat_node_get_child_bounds, function in GskRenderNode gsk_repeat_node_new, function in GskRenderNode GskRoundedClipNode, struct in GskRenderNode GskRoundedRect, struct in GskRoundedRect gsk_rounded_clip_node_get_child, function in GskRenderNode gsk_rounded_clip_node_get_clip, function in GskRenderNode gsk_rounded_clip_node_new, function in GskRenderNode gsk_rounded_rect_contains_point, function in GskRoundedRect gsk_rounded_rect_contains_rect, function in GskRoundedRect GSK_ROUNDED_RECT_INIT, macro in GskRoundedRect gsk_rounded_rect_init, function in GskRoundedRect gsk_rounded_rect_init_copy, function in GskRoundedRect gsk_rounded_rect_init_from_rect, function in GskRoundedRect gsk_rounded_rect_intersects_rect, function in GskRoundedRect gsk_rounded_rect_is_rectilinear, function in GskRoundedRect gsk_rounded_rect_normalize, function in GskRoundedRect gsk_rounded_rect_offset, function in GskRoundedRect gsk_rounded_rect_shrink, function in GskRoundedRect S GskScalingFilter, enum in GskRenderNode GskSerializationError, enum in GskRenderNode GskShaderArgsBuilder, struct in GskGLShader gsk_shader_args_builder_free_to_args, function in GskGLShader gsk_shader_args_builder_new, function in GskGLShader gsk_shader_args_builder_ref, function in GskGLShader gsk_shader_args_builder_set_bool, function in GskGLShader gsk_shader_args_builder_set_float, function in GskGLShader gsk_shader_args_builder_set_int, function in GskGLShader gsk_shader_args_builder_set_uint, function in GskGLShader gsk_shader_args_builder_set_vec2, function in GskGLShader gsk_shader_args_builder_set_vec3, function in GskGLShader gsk_shader_args_builder_set_vec4, function in GskGLShader gsk_shader_args_builder_to_args, function in GskGLShader gsk_shader_args_builder_unref, function in GskGLShader GskShadow, struct in GskRenderNode GskShadowNode, struct in GskRenderNode gsk_shadow_node_get_child, function in GskRenderNode gsk_shadow_node_get_n_shadows, function in GskRenderNode gsk_shadow_node_get_shadow, function in GskRenderNode gsk_shadow_node_new, function in GskRenderNode T GskTextNode, struct in GskRenderNode GskTextureNode, struct in GskRenderNode gsk_texture_node_get_texture, function in GskRenderNode gsk_texture_node_new, function in GskRenderNode gsk_text_node_get_color, function in GskRenderNode gsk_text_node_get_font, function in GskRenderNode gsk_text_node_get_glyphs, function in GskRenderNode gsk_text_node_get_num_glyphs, function in GskRenderNode gsk_text_node_get_offset, function in GskRenderNode gsk_text_node_has_color_glyphs, function in GskRenderNode gsk_text_node_new, function in GskRenderNode GskTransform, struct in GskTransform GskTransformCategory, enum in GskTransform GskTransformNode, struct in GskRenderNode gsk_transform_equal, function in GskTransform gsk_transform_get_category, function in GskTransform gsk_transform_invert, function in GskTransform gsk_transform_matrix, function in GskTransform gsk_transform_node_get_child, function in GskRenderNode gsk_transform_node_get_transform, function in GskRenderNode gsk_transform_node_new, function in GskRenderNode gsk_transform_parse, function in GskTransform gsk_transform_perspective, function in GskTransform gsk_transform_print, function in GskTransform gsk_transform_ref, function in GskTransform gsk_transform_rotate, function in GskTransform gsk_transform_rotate_3d, function in GskTransform gsk_transform_scale, function in GskTransform gsk_transform_scale_3d, function in GskTransform gsk_transform_to_2d, function in GskTransform gsk_transform_to_affine, function in GskTransform gsk_transform_to_matrix, function in GskTransform gsk_transform_to_string, function in GskTransform gsk_transform_to_translate, function in GskTransform gsk_transform_transform, function in GskTransform gsk_transform_transform_bounds, function in GskTransform gsk_transform_transform_point, function in GskTransform gsk_transform_translate, function in GskTransform gsk_transform_translate_3d, function in GskTransform gsk_transform_unref, function in GskTransform V gsk_vulkan_renderer_new, function in GskRenderer docs/reference/gsk/xml/api-index-deprecated.xml0000664000175000017500000000052613766440675021703 0ustar mclasenmclasen ]> docs/reference/gsk/xml/annotation-glossary.xml0000664000175000017500000000645313766440675021747 0ustar mclasenmclasen ]> Annotation Glossary A allow-none NULL is OK, both for passing and for returning. array Parameter points to an array of items. C closure This parameter is a 'user_data', for callbacks; many bindings can pass NULL here. N nullable NULL may be passed as the value in, out, in-out; or as a return value. O optional NULL may be passed instead of a pointer to a location. out Parameter for returning results. Default is transfer full. out caller-allocates Out parameter, where caller must allocate storage. S scope call The callback is valid only during the call to the method. skip Exposed in C code, not necessarily available in other languages. T transfer full Free data after the code is done. transfer none Don't free data after the code is done. type Override the parsed C type with given type. docs/reference/gsk/gsk4-undocumented.txt0000664000175000017500000000013313766440675020500 0ustar mclasenmclasen100% symbol docs coverage. 241 symbols documented. 0 symbols incomplete. 0 not documented. docs/reference/gsk/gsk4-undeclared.txt0000664000175000017500000000000013766440675020105 0ustar mclasenmclasendocs/reference/gsk/gsk4-unused.txt0000664000175000017500000000000013766440675017302 0ustar mclasenmclasendocs/reference/gsk/sgml.stamp0000664000175000017500000000001113766440675016402 0ustar mclasenmclasentimestampdocs/reference/gsk/html.stamp0000664000175000017500000000001113766440701016372 0ustar mclasenmclasentimestamp