~gnome3-team/mutter/trunk

« back to all changes in this revision

Viewing changes to cogl/cogl/driver/nop/cogl-texture-2d-nop-private.h

  • Committer: Rui Matos
  • Date: 2016-04-27 16:36:25 UTC
  • mfrom: (0.87.3184)
  • Revision ID: git-v1:3fcbe1d3ec5c9208dde080f7e9dac24e4c379bc0
Merge cogl's cogl-1.22 branch into mutter

https://bugzilla.gnome.org/show_bug.cgi?id=760439

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * Cogl
 
3
 *
 
4
 * A Low Level GPU Graphics and Utilities API
 
5
 *
 
6
 * Copyright (C) 2012 Intel Corporation.
 
7
 *
 
8
 * Permission is hereby granted, free of charge, to any person
 
9
 * obtaining a copy of this software and associated documentation
 
10
 * files (the "Software"), to deal in the Software without
 
11
 * restriction, including without limitation the rights to use, copy,
 
12
 * modify, merge, publish, distribute, sublicense, and/or sell copies
 
13
 * of the Software, and to permit persons to whom the Software is
 
14
 * furnished to do so, subject to the following conditions:
 
15
 *
 
16
 * The above copyright notice and this permission notice shall be
 
17
 * included in all copies or substantial portions of the Software.
 
18
 *
 
19
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 
20
 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 
21
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
 
22
 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
 
23
 * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 
24
 * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 
25
 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 
26
 * SOFTWARE.
 
27
 *
 
28
 *
 
29
 *
 
30
 * Authors:
 
31
 *   Robert Bragg <robert@linux.intel.com>
 
32
 */
 
33
 
 
34
#ifndef _COGL_TEXTURE_2D_NOP_PRIVATE_H_
 
35
#define _COGL_TEXTURE_2D_NOP_PRIVATE_H_
 
36
 
 
37
#include "cogl-types.h"
 
38
#include "cogl-context-private.h"
 
39
#include "cogl-texture.h"
 
40
 
 
41
void
 
42
_cogl_texture_2d_nop_free (CoglTexture2D *tex_2d);
 
43
 
 
44
CoglBool
 
45
_cogl_texture_2d_nop_can_create (CoglContext *ctx,
 
46
                                 int width,
 
47
                                 int height,
 
48
                                 CoglPixelFormat internal_format);
 
49
 
 
50
void
 
51
_cogl_texture_2d_nop_init (CoglTexture2D *tex_2d);
 
52
 
 
53
CoglBool
 
54
_cogl_texture_2d_nop_allocate (CoglTexture *tex,
 
55
                               CoglError **error);
 
56
 
 
57
void
 
58
_cogl_texture_2d_nop_flush_legacy_texobj_filters (CoglTexture *tex,
 
59
                                                  GLenum min_filter,
 
60
                                                  GLenum mag_filter);
 
61
 
 
62
void
 
63
_cogl_texture_2d_nop_flush_legacy_texobj_wrap_modes (CoglTexture *tex,
 
64
                                                     GLenum wrap_mode_s,
 
65
                                                     GLenum wrap_mode_t,
 
66
                                                     GLenum wrap_mode_p);
 
67
 
 
68
void
 
69
_cogl_texture_2d_nop_copy_from_framebuffer (CoglTexture2D *tex_2d,
 
70
                                            int src_x,
 
71
                                            int src_y,
 
72
                                            int width,
 
73
                                            int height,
 
74
                                            CoglFramebuffer *src_fb,
 
75
                                            int dst_x,
 
76
                                            int dst_y,
 
77
                                            int level);
 
78
 
 
79
unsigned int
 
80
_cogl_texture_2d_nop_get_gl_handle (CoglTexture2D *tex_2d);
 
81
 
 
82
void
 
83
_cogl_texture_2d_nop_generate_mipmap (CoglTexture2D *tex_2d);
 
84
 
 
85
CoglBool
 
86
_cogl_texture_2d_nop_copy_from_bitmap (CoglTexture2D *tex_2d,
 
87
                                       int src_x,
 
88
                                       int src_y,
 
89
                                       int width,
 
90
                                       int height,
 
91
                                       CoglBitmap *bitmap,
 
92
                                       int dst_x,
 
93
                                       int dst_y,
 
94
                                       int level,
 
95
                                       CoglError **error);
 
96
 
 
97
void
 
98
_cogl_texture_2d_nop_get_data (CoglTexture2D *tex_2d,
 
99
                               CoglPixelFormat format,
 
100
                               size_t rowstride,
 
101
                               uint8_t *data);
 
102
 
 
103
#endif /* _COGL_TEXTURE_2D_NOP_PRIVATE_H_ */