mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-27 14:10:30 +00:00
Trivial formatting fixes
This commit is contained in:
parent
a74c5a1f39
commit
706a7064a0
11
gdk/gdkgl.c
11
gdk/gdkgl.c
@ -38,11 +38,12 @@ gdk_cairo_surface_mark_as_direct (cairo_surface_t *surface,
|
|||||||
/* x,y,width,height describes a rectangle in the gl render buffer
|
/* x,y,width,height describes a rectangle in the gl render buffer
|
||||||
coordinate space, and its top left corner is drawn at the current
|
coordinate space, and its top left corner is drawn at the current
|
||||||
position according to the cairo translation. */
|
position according to the cairo translation. */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* gdk_cairo_draw_from_gl
|
* gdk_cairo_draw_from_gl:
|
||||||
* @cr: a cairo context
|
* @cr: a cairo context
|
||||||
* @window: The window we're rendering for (not necessarily into)
|
* @window: The window we're rendering for (not necessarily into)
|
||||||
* @source: The GL id of the source buffer
|
* @source: The GL ID of the source buffer
|
||||||
* @source_type: The type of the @source
|
* @source_type: The type of the @source
|
||||||
* @buffer_scale: The scale-factor that the @source buffer is allocated for
|
* @buffer_scale: The scale-factor that the @source buffer is allocated for
|
||||||
* @x: The source x position in @source to start copying from in GL coordinates
|
* @x: The source x position in @source to start copying from in GL coordinates
|
||||||
@ -50,7 +51,7 @@ gdk_cairo_surface_mark_as_direct (cairo_surface_t *surface,
|
|||||||
* @width: The width of the region to draw
|
* @width: The width of the region to draw
|
||||||
* @height: The height of the region to draw
|
* @height: The height of the region to draw
|
||||||
*
|
*
|
||||||
* This is the main way to draw GL content in Gtk+. It takes a render buffer id
|
* This is the main way to draw GL content in GTK+. It takes a render buffer ID
|
||||||
* (@source_type == #GL_RENDERBUFFER) or a texture id (@source_type == #GL_TEXTURE)
|
* (@source_type == #GL_RENDERBUFFER) or a texture id (@source_type == #GL_TEXTURE)
|
||||||
* and draws it onto @cr with an OVER operation, respecting the current clip.
|
* and draws it onto @cr with an OVER operation, respecting the current clip.
|
||||||
*
|
*
|
||||||
@ -62,6 +63,8 @@ gdk_cairo_surface_mark_as_direct (cairo_surface_t *surface,
|
|||||||
*
|
*
|
||||||
* For #GL_RENDERBUFFER the code will always fall back to software for buffers
|
* For #GL_RENDERBUFFER the code will always fall back to software for buffers
|
||||||
* with alpha components, so make sure you use #GL_TEXTURE if using alpha.
|
* with alpha components, so make sure you use #GL_TEXTURE if using alpha.
|
||||||
|
*
|
||||||
|
* Since: 3.16
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
gdk_cairo_draw_from_gl (cairo_t *cr,
|
gdk_cairo_draw_from_gl (cairo_t *cr,
|
||||||
@ -374,7 +377,7 @@ gdk_cairo_draw_from_gl (cairo_t *cr,
|
|||||||
|
|
||||||
void
|
void
|
||||||
gdk_gl_texture_from_surface (cairo_surface_t *surface,
|
gdk_gl_texture_from_surface (cairo_surface_t *surface,
|
||||||
cairo_region_t *region)
|
cairo_region_t *region)
|
||||||
{
|
{
|
||||||
GdkGLContext *current;
|
GdkGLContext *current;
|
||||||
cairo_surface_t *image;
|
cairo_surface_t *image;
|
||||||
|
@ -26,19 +26,20 @@
|
|||||||
* #GdkGLContext is an object representing the platform-specific
|
* #GdkGLContext is an object representing the platform-specific
|
||||||
* OpenGL drawing context.
|
* OpenGL drawing context.
|
||||||
*
|
*
|
||||||
* #GdkGLContexts are created for a #GdkWindow using gdk_window_create_gl_context(), and
|
* #GdkGLContexts are created for a #GdkWindow using
|
||||||
* the context will match the GdkVisual of the window.
|
* gdk_window_create_gl_context(), and the context will match
|
||||||
|
* the #GdkVisual of the window.
|
||||||
*
|
*
|
||||||
* A #GdkGLContexts is not tied to any particulare normal
|
* A #GdkGLContexts is not tied to any particulare normal
|
||||||
* framebuffer. For instance, it cannot draw to the #GdkWindow back
|
* framebuffer. For instance, it cannot draw to the #GdkWindow back
|
||||||
* buffer. The gdk repaint system is in full control of the painting
|
* buffer. The GDK repaint system is in full control of the painting
|
||||||
* to that. Instead you can create render buffers or textures and use
|
* to that. Instead you can create render buffers or textures and use
|
||||||
* gdk_cairo_draw_from_gl() in the draw function of your widget to
|
* gdk_cairo_draw_from_gl() in the draw function of your widget to
|
||||||
* draw them. Then Gdk will handle the integration of your rendering
|
* draw them. Then GDK will handle the integration of your rendering
|
||||||
* with that of other widgets.
|
* with that of other widgets.
|
||||||
*
|
*
|
||||||
* Support for #GdkGLContext is platform specific, context creation can fail, returning
|
* Support for #GdkGLContext is platform-specific, context creation
|
||||||
* a %NULL context.
|
* can fail, returning %NULL context.
|
||||||
*
|
*
|
||||||
* A #GdkGLContext has to be made "current" in order to start using
|
* A #GdkGLContext has to be made "current" in order to start using
|
||||||
* it, otherwise any OpenGL call will be ignored.
|
* it, otherwise any OpenGL call will be ignored.
|
||||||
@ -46,7 +47,8 @@
|
|||||||
* ## Creating a new OpenGL context ##
|
* ## Creating a new OpenGL context ##
|
||||||
*
|
*
|
||||||
* In order to create a new #GdkGLContext instance you need a
|
* In order to create a new #GdkGLContext instance you need a
|
||||||
* #GdkWindow, which you typically get during the realize call of a widget.
|
* #GdkWindow, which you typically get during the realize call
|
||||||
|
* of a widget.
|
||||||
*
|
*
|
||||||
* ## Using a GdkGLContext ##
|
* ## Using a GdkGLContext ##
|
||||||
*
|
*
|
||||||
@ -255,7 +257,7 @@ gdk_gl_context_get_visual (GdkGLContext *context)
|
|||||||
* Since: 3.16
|
* Since: 3.16
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
gdk_gl_context_flush_buffer (GdkGLContext *context,
|
gdk_gl_context_flush_buffer (GdkGLContext *context,
|
||||||
cairo_region_t *painted,
|
cairo_region_t *painted,
|
||||||
cairo_region_t *damage)
|
cairo_region_t *damage)
|
||||||
{
|
{
|
||||||
|
@ -882,12 +882,12 @@ gdk_x11_display_make_gl_context_current (GdkDisplay *display,
|
|||||||
*
|
*
|
||||||
* Returns: %TRUE if GLX is available
|
* Returns: %TRUE if GLX is available
|
||||||
*
|
*
|
||||||
* Since: 3.14
|
* Since: 3.16
|
||||||
*/
|
*/
|
||||||
gboolean
|
gboolean
|
||||||
gdk_x11_display_get_glx_version (GdkDisplay *display,
|
gdk_x11_display_get_glx_version (GdkDisplay *display,
|
||||||
int *major,
|
gint *major,
|
||||||
int *minor)
|
gint *minor)
|
||||||
{
|
{
|
||||||
g_return_val_if_fail (GDK_IS_DISPLAY (display), FALSE);
|
g_return_val_if_fail (GDK_IS_DISPLAY (display), FALSE);
|
||||||
|
|
||||||
|
@ -41,8 +41,8 @@ GType gdk_x11_gl_context_get_type (void) G_GNUC_CONST;
|
|||||||
|
|
||||||
GDK_AVAILABLE_IN_3_16
|
GDK_AVAILABLE_IN_3_16
|
||||||
gboolean gdk_x11_display_get_glx_version (GdkDisplay *display,
|
gboolean gdk_x11_display_get_glx_version (GdkDisplay *display,
|
||||||
int *major,
|
gint *major,
|
||||||
int *minor);
|
gint *minor);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user