1GLCOPYCONVOLUTIONFIL(3G)         OpenGL Manual        GLCOPYCONVOLUTIONFIL(3G)
2
3
4

NAME

6       glCopyConvolutionFilter1D - copy pixels into a one-dimensional
7       convolution filter
8

C SPECIFICATION

10       void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat,
11                                      GLint x, GLint y, GLsizei width);
12

PARAMETERS

14       target
15           Must be GL_CONVOLUTION_1D.
16
17       internalformat
18           The internal format of the convolution filter kernel. The allowable
19           values are GL_ALPHA, GL_ALPHA4, GL_ALPHA8, GL_ALPHA12, GL_ALPHA16,
20           GL_LUMINANCE, GL_LUMINANCE4, GL_LUMINANCE8, GL_LUMINANCE12,
21           GL_LUMINANCE16, GL_LUMINANCE_ALPHA, GL_LUMINANCE4_ALPHA4,
22           GL_LUMINANCE6_ALPHA2, GL_LUMINANCE8_ALPHA8, GL_LUMINANCE12_ALPHA4,
23           GL_LUMINANCE12_ALPHA12, GL_LUMINANCE16_ALPHA16, GL_INTENSITY,
24           GL_INTENSITY4, GL_INTENSITY8, GL_INTENSITY12, GL_INTENSITY16,
25           GL_R3_G3_B2, GL_RGB, GL_RGB4, GL_RGB5, GL_RGB8, GL_RGB10, GL_RGB12,
26           GL_RGB16, GL_RGBA, GL_RGBA2, GL_RGBA4, GL_RGB5_A1, GL_RGBA8,
27           GL_RGB10_A2, GL_RGBA12, or GL_RGBA16.
28
29       x, y
30           The window space coordinates of the lower-left coordinate of the
31           pixel array to copy.
32
33       width
34           The width of the pixel array to copy.
35

DESCRIPTION

37       glCopyConvolutionFilter1D defines a one-dimensional convolution filter
38       kernel with pixels from the current GL_READ_BUFFER (rather than from
39       main memory, as is the case for glConvolutionFilter1D()).
40
41       The screen-aligned pixel rectangle with lower-left corner at (x,\ y),
42       width width and height 1 is used to define the convolution filter. If
43       any pixels within this region are outside the window that is associated
44       with the GL context, the values obtained for those pixels are
45       undefined.
46
47       The pixels in the rectangle are processed exactly as if glReadPixels()
48       had been called with format set to RGBA, but the process stops just
49       before final conversion. The R, G, B, and A components of each pixel
50       are next scaled by the four 1D GL_CONVOLUTION_FILTER_SCALE parameters
51       and biased by the four 1D GL_CONVOLUTION_FILTER_BIAS parameters. (The
52       scale and bias parameters are set by glConvolutionParameter() using the
53       GL_CONVOLUTION_1D target and the names GL_CONVOLUTION_FILTER_SCALE and
54       GL_CONVOLUTION_FILTER_BIAS. The parameters themselves are vectors of
55       four values that are applied to red, green, blue, and alpha, in that
56       order.) The R, G, B, and A values are not clamped to [0,1] at any time
57       during this process.
58
59       Each pixel is then converted to the internal format specified by
60       internalformat. This conversion simply maps the component values of the
61       pixel (R, G, B, and A) to the values included in the internal format
62       (red, green, blue, alpha, luminance, and intensity). The mapping is as
63       follows:
64
65       ┌─────────────────────────────────┬─────────────────────────────┬───────────────────────────────┬──────────────────────────────┬───────────────────────────────┬───────────────────────────────────┬───────────────────────────────────┐
66       │                                 │                             │                               │                              │                               │                                   │                                   │
67Internal Red Green Blue Alpha Luminance Intensity 
68Format                           │                             │                               │                              │                               │                                   │                                   │
69       │                                 │                             │                               │                              │                               │                                   │                                   │
70       ├─────────────────────────────────┼─────────────────────────────┼───────────────────────────────┼──────────────────────────────┼───────────────────────────────┼───────────────────────────────────┼───────────────────────────────────┤
71GL_ALPHA                         │                             │                               │                              │               A               │                                   │                                   │
72       ├─────────────────────────────────┼─────────────────────────────┼───────────────────────────────┼──────────────────────────────┼───────────────────────────────┼───────────────────────────────────┼───────────────────────────────────┤
73GL_LUMINANCE                     │                             │                               │                              │                               │                 R                 │                                   │
74       ├─────────────────────────────────┼─────────────────────────────┼───────────────────────────────┼──────────────────────────────┼───────────────────────────────┼───────────────────────────────────┼───────────────────────────────────┤
75GL_LUMINANCE_ALPHA               │                             │                               │                              │               A               │                 R                 │                                   │
76       ├─────────────────────────────────┼─────────────────────────────┼───────────────────────────────┼──────────────────────────────┼───────────────────────────────┼───────────────────────────────────┼───────────────────────────────────┤
77GL_INTENSITY                     │                             │                               │                              │                               │                                   │                 R                 │
78       ├─────────────────────────────────┼─────────────────────────────┼───────────────────────────────┼──────────────────────────────┼───────────────────────────────┼───────────────────────────────────┼───────────────────────────────────┤
79GL_RGB                           │              R              │               G               │              B               │                               │                                   │                                   │
80       ├─────────────────────────────────┼─────────────────────────────┼───────────────────────────────┼──────────────────────────────┼───────────────────────────────┼───────────────────────────────────┼───────────────────────────────────┤
81GL_RGBA                          │              R              │               G               │              B               │               A               │                                   │                                   │
82       └─────────────────────────────────┴─────────────────────────────┴───────────────────────────────┴──────────────────────────────┴───────────────────────────────┴───────────────────────────────────┴───────────────────────────────────┘
83
84       The red, green, blue, alpha, luminance, and/or intensity components of
85       the resulting pixels are stored in floating-point rather than integer
86       format.
87
88       Pixel ordering is such that lower x screen coordinates correspond to
89       lower i filter image coordinates.
90
91       Note that after a convolution is performed, the resulting color
92       components are also scaled by their corresponding
93       GL_POST_CONVOLUTION_c_SCALE parameters and biased by their
94       corresponding GL_POST_CONVOLUTION_c_BIAS parameters (where c takes on
95       the values RED, GREEN, BLUE, and ALPHA). These parameters are set by
96       glPixelTransfer().
97

NOTES

99       glCopyConvolutionFilter1D is present only if ARB_imaging is returned
100       when glGetString() is called with an argument of GL_EXTENSIONS.
101

ERRORS

103       GL_INVALID_ENUM is generated if target is not GL_CONVOLUTION_1D.
104
105       GL_INVALID_ENUM is generated if internalformat is not one of the
106       allowable values.
107
108       GL_INVALID_VALUE is generated if width is less than zero or greater
109       than the maximum supported value. This value may be queried with
110       glGetConvolutionParameter() using target GL_CONVOLUTION_1D and name
111       GL_MAX_CONVOLUTION_WIDTH.
112
113       GL_INVALID_OPERATION is generated if glCopyConvolutionFilter1D is
114       executed between the execution of glBegin() and the corresponding
115       execution of glEnd().
116

ASSOCIATED GETS

118       glGetConvolutionParameter(), glGetConvolutionFilter()
119

SEE ALSO

121       glConvolutionFilter1D(), glConvolutionParameter(), glPixelTransfer()
122
124       Copyright © 1991-2006 Silicon Graphics, Inc. This document is licensed
125       under the SGI Free Software B License. For details, see
126       http://oss.sgi.com/projects/FreeB/.
127

AUTHORS

129       opengl.org
130
131
132
133opengl.org                        06/10/2014          GLCOPYCONVOLUTIONFIL(3G)
Impressum