ruby-gr 0.0.16 → 0.0.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d1884c5391124334045320390f35efd167865a6f1f063e6b763228c707cad400
4
- data.tar.gz: '07929d47c8a49344fb625526b34f170b1fd0da2cfbddf538bef39f29ef122ec8'
3
+ metadata.gz: 20591722440c58b4cea29effed6bd13debcdc2c0383b40163d5b2fbc3f517f3e
4
+ data.tar.gz: 635fa83b40177e1c80936ca7fd949e2f2880c50710565db24e6e049f168d18ea
5
5
  SHA512:
6
- metadata.gz: 132db88979be43ca20834522630d5970442a3565b7b14d6dafb5d970b7706b39112f56b83ab223c804e129ec9fcc612812ee691fa181d0dcdf7a86643ab7ba4b
7
- data.tar.gz: 7bc7e311d1c22d81afada8611c1775b93a477c80d52b545c665975a8736a4fdb25dfcbde2c44604eb616c8018ab918148ba5b280166d228fae6205aa98b31322
6
+ metadata.gz: b30985a6bc12803fd2aabc590ffaccf4a4b931a5d00bb1c8c443fec90fd60f799560edbe3454532650871a578222c3aafb6d949204fb74b4efc22b3ddc5b197e
7
+ data.tar.gz: 61e34d2541e1821f739d5c12be8524b9fbc7e0332223c2c89cda40b0f38fc2eaa3ad695e5dca2fd5c955ee1bc04f07d0c235a7ce6a59f11b093ea7707f68e31f
data/README.md CHANGED
@@ -6,32 +6,38 @@
6
6
  [![Gitter Chat](https://badges.gitter.im/red-data-tools/en.svg)](https://gitter.im/red-data-tools/en)
7
7
  [![Docs Latest](https://img.shields.io/badge/docs-latest-blue.svg)](https://rubydoc.info/gems/ruby-gr)
8
8
 
9
- <p align="center">
10
- <img src="https://user-images.githubusercontent.com/5798442/70857099-13d57600-1f2c-11ea-8f3c-7d81065f13a5.png">
11
- </p>
12
-
13
- :bar_chart: [GR framework](https://github.com/sciapp/gr) - the graphics library for visualization - for Ruby
9
+ [![rdatasets-1](https://i.imgur.com/XEQ6wKs.png)](examples/rdatasets.rb)
10
+ [![stem](https://i.imgur.com/3w0Ejrm.png)](examples/fast_plots.rb)
11
+ [![histogram](https://i.imgur.com/xUdoA2s.png)](examples/fast_plots.rb)
12
+ [![barplot](https://i.imgur.com/52bOFKE.png)](examples/fast_plots.rb)
13
+ [![scatter3](https://i.imgur.com/yTTVetQ.png)](examples/fast_plots.rb)
14
+ [![volume](https://i.imgur.com/CuRN6oC.png)](examples/fast_plots.rb)
15
+ [![griddata](https://i.imgur.com/58HdYDo.png)](examples/griddata.rb)
16
+ [![2darray](https://i.imgur.com/aKR2FJG.png)](examples/2darray.rb)
17
+ [![2dpolararray](https://i.imgur.com/cmSrxvS.png)](examples/2dpolararray.rb)
18
+ [![hexbin](https://i.imgur.com/unWhQHr.png)](examples/hexbin.rb)
19
+ [![rdatasets-2](https://i.imgur.com/ZPit2F5.png)](examples/rdatasets.rb)
20
+ [![rdatasets-3](https://i.imgur.com/TbNoxwy.png)](examples/rdatasets.rb)
21
+ [![surface](https://i.imgur.com/sWdaHme.png)](examples/kws2.rb)
22
+ [![face](https://i.imgur.com/uLCKi2r.png)](examples/face.rb)
23
+ [![shade](https://i.imgur.com/VJmS3EQ.png)](examples/shade_ex.rb)
24
+
25
+ :bar_chart: [GR framework](https://github.com/sciapp/gr) - powerful visualization library - for Ruby
14
26
 
15
27
  ## Installation
16
28
 
17
- GR.rb supports Ruby 2.4+.
18
-
19
- [Install GR](#gr-installation).
29
+ GR.rb supports Ruby 2.5+.
20
30
 
21
- Set environment variable GRDIR, if you have not already done.
31
+ First, [install GR](#gr-installation). Next, set environment variable `GRDIR`.
22
32
 
23
33
  ```sh
24
34
  export GRDIR="/your/path/to/gr"
25
35
  ```
26
36
 
27
- Add this line to your application's Gemfile:
28
-
29
37
  ```sh
30
- gem 'ruby-gr'
38
+ gem install ruby-gr
31
39
  ```
32
40
 
33
- GR3 and GR::Plot require [numo-narray](https://github.com/ruby-numo/numo-narray).
34
-
35
41
  ## Quick Start
36
42
 
37
43
  <p align="center">
@@ -47,42 +53,103 @@ y = [0.3, 0.5, 0.4, 0.2, 0.6, 0.7]
47
53
  GR.plot(x, y)
48
54
  ```
49
55
 
50
- ## Examples
56
+ <p align="center">
57
+ <img src="https://user-images.githubusercontent.com/5798442/84570709-242ab880-adca-11ea-9099-3a6b3418bf19.png">
58
+ </p>
51
59
 
52
- Have a look in the [`examples`](https://github.com/red-data-tools/GR.rb/tree/master/examples) directory. Start with [`fast_plot`](https://github.com/red-data-tools/GR.rb/blob/master/examples/fast_plots.rb).
60
+ ```ruby
61
+ require 'gr/plot'
53
62
 
54
- ## Features
63
+ x = Numo::DFloat.linspace(0, 10, 101)
64
+ y1 = Numo::NMath.sin(x)
65
+ y2 = Numo::NMath.cos(x)
66
+
67
+ GR.plot(
68
+ [x, y1, 'bo'], [x, y2, 'g*'],
69
+ title: "Multiple plot example",
70
+ xlabel: "x",
71
+ ylabel: "y",
72
+ ylim: [-1.2, 1.2],
73
+ labels: ["sin(x)", "cos(x)"],
74
+ location: 11
75
+ )
76
+ ```
55
77
 
56
- #### GR::Plot
78
+ Save in PNG format.
57
79
 
58
- A simple, matlab-style API.
80
+ ```ruby
81
+ GR.savefig("figure.png")
82
+ ```
83
+
84
+ ## API Overview
85
+
86
+ There are two different approaches to plotting with GR.rb. One way is to call Matlab-like APIs. The other is to call GR/GR3 native functions. We are planning to prepare a [more object-oriented interface](https://github.com/kojix2/GRUtils.rb) based on [GRUtils.jl](https://github.com/heliosdrm/GRUtils.jl) in the future.
87
+
88
+ #### GR::Plot - A simple, matlab-style API.
59
89
 
60
90
  ```ruby
61
91
  require 'gr/plot'
92
+ GR.plot(x, y)
62
93
  ```
63
94
 
64
- `plot` `step` `scatter` `stem` `histogram` `contour` `contourf` `hexbin` `heatmap` `wireframe` `surface` `plot3` `scatter3` `imshow` `isosurface` `polar` `polarhist` `polarheatmap` `trisurf` `tricont` `shade` `volume`
65
-
66
- #### GR
95
+ List of vailable functions. See [GR.rb Wiki](https://github.com/red-data-tools/GR.rb/wiki) for details.
96
+
97
+ [`plot`](../../wiki/Plotting-functions#plot)
98
+ [`step`](../../wiki/Plotting-functions#step)
99
+ [`plot3`](../../wiki/Plotting-functions#plot3)
100
+ [`polar`](../../wiki/Plotting-functions#polar)
101
+ [`scatter`](../../wiki/Plotting-functions#scatter)
102
+ [`scatter3`](../../wiki/Plotting-functions#scatter3)
103
+ [`stem`](../../wiki/Plotting-functions#stem)
104
+ [`barplot`](../../wiki/Plotting-functions#barplot)
105
+ [`histogram`](../../wiki/Plotting-functions#histogram)
106
+ [`polarhistogram`](../../wiki/Plotting-functions#polarhistogram)
107
+ [`hexbin`](../../wiki/Plotting-functions#hexbin)
108
+ [`contour`](../../wiki/Plotting-functions#contour)
109
+ [`contourf`](../../wiki/Plotting-functions#contourf)
110
+ [`tricont`](../../wiki/Plotting-functions#tricont)
111
+ [`surface`](../../wiki/Plotting-functions#surface)
112
+ [`trisurf`](../../wiki/Plotting-functions#trisurf)
113
+ [`wireframe`](../../wiki/Plotting-functions#wireframe)
114
+ [`volume`](../../wiki/Plotting-functions#volume)
115
+ [`heatmap`](../../wiki/Plotting-functions#heatmap)
116
+ [`polarheatmap`](../../wiki/Plotting-functions#polarheatmap)
117
+ [`shade`](../../wiki/Plotting-functions#shade)
118
+ [`imshow`](../../wiki/Plotting-functions#imshow)
119
+ [`isosurface`](../../wiki/Plotting-functions#isosurface)
120
+
121
+ #### GR - A module for calling native GR functions.
122
+
123
+ 2-D Plots and common 3-D Plots.
67
124
 
68
125
  ```ruby
69
126
  require 'gr'
127
+
128
+ # For example
129
+ GR.setviewport(0.1, 0.9, 0.1, 0.9)
130
+ GR.setwindow(0.0, 20.0, 0.0, 20.0)
70
131
  ```
71
132
 
72
- #### GR3
133
+ #### GR3 - A module for calling native GR3 functions.
134
+
135
+ Complex 3D scenes.
73
136
 
74
137
  ```ruby
75
138
  require 'gr3'
139
+
140
+ # For example
141
+ GR3.cameralookat(-3, 2, -2, 0, 0, 0, 0, 0, -1)
76
142
  ```
77
143
 
78
144
  ## Documentation
79
145
 
146
+ - [GR.rb Wiki](https://github.com/red-data-tools/GR.rb/wiki)
80
147
  - [GR Framework](https://gr-framework.org/)
81
148
  - [GR.rb API Documentation](https://rubydoc.info/gems/ruby-gr)
82
149
 
83
150
  ## GR Installation
84
151
 
85
- ### Official binary release
152
+ ### Installing an official release (recommended)
86
153
 
87
154
  Download the [latest release](https://github.com/sciapp/gr/releases).
88
155
 
@@ -94,23 +161,30 @@ export GRDIR="your/path/to/gr"
94
161
 
95
162
  * macOS Catalina and macOS Mojave: See the "How to open an app that hasn’t been notarized or is from an unidentified developer" section of [Safely open apps on your Mac](https://support.apple.com/en-us/HT202491) in the Apple documentation.
96
163
 
97
- ### Homebrew
164
+ ### Using your package manager
165
+
166
+ * The third party GR packages for Mac, Linux and Windows are available (for advanced users).
167
+ * If you find any problem, please report the issue [here](https://github.com/red-data-tools/GR.rb/issues).
168
+
169
+ #### Mac - Homebrew
98
170
 
99
171
  ```sh
100
172
  brew install libgr
101
173
  ```
102
174
 
103
- Set environment variable GRDIR.
175
+ Set environment variable `GRDIR`.
104
176
 
105
177
  ```sh
106
178
  export GRDIR=$(brew --prefix libgr)
107
179
  ```
108
180
 
109
- If you fail to build libgr using homebrew, Please feel free to [send us your feedback](https://github.com/red-data-tools/GR.rb/issues).
181
+ #### Linux - APT Yum
182
+
183
+ [packages.red-data-tools.org](https://github.com/red-data-tools/packages.red-data-tools.org) provides `libgr-dev` and `libgr3-dev`.
110
184
 
111
- ### Red data tools repository
185
+ #### Windows - MSYS2
112
186
 
113
- Red data tools provides [packages](https://github.com/red-data-tools/packages.red-data-tools.org ) related to our project including `libgr-dev` and `libgr3-dev` for advanced users.
187
+ If you are using Rubyinstaller, pacman will automatically install [mingw-w64-gr](https://packages.msys2.org/base/mingw-w64-gr) when the gem is installed.
114
188
 
115
189
  ## Backend for Charty
116
190
 
data/lib/gr.rb CHANGED
@@ -2,39 +2,39 @@
2
2
 
3
3
  # OverView of GR.rb
4
4
  #
5
- # +--------------------+ +--------------------+
6
- # | GR module | | GR3 module |
7
- # | +----------------+ | | +----------------+ |
8
- # | | GR::FFI | | | | GR3::FFI | |
9
- # | | + libGR.so | | | | + libGR3.so | |
10
- # | +----------------+ | | +----------------+ |
11
- # | | define_method | | | define_method |
12
- # | +----------------+ | | +----------------+ |
13
- # | | | GR::GRBase | | | | | GR3::GR3Base | |
14
- # | | v (Pri^ate) | | | | v (Pri^ate) | |
15
- # | +++--------------+ | | +++--------------+ |
16
- # | | Extend | | | Extend |
17
- # | v | | v +-------+ |
18
- # | +-----------+ | | | Check | |
19
- # | | GR::Plot | | | <--+ Error | |
20
- # | +-----------+ | | +-------+ |
21
- # +--------------------+ +----------+---------+
22
- # ^ ^
23
- # | +------------------+ |
24
- # Extend | | GRCommons module | | Extend
25
- # | | +--------------+ | |
26
- # | | | Fiddley | | |
27
- # | | +--------------+ | |
28
- # | | +--------------+ | |
29
- # +----+ CommonUtils +----+
30
- # | | +--------------+ | |
31
- # | | +--------------+ | |
32
- # +----+ Version +----+
33
- # | | +--------------+ |
34
- # | | +--------------+ |
35
- # +----+JupyterSupport| |
36
- # | +--------------+ |
37
- # +------------------+
5
+ # +--------------------+ +--------------------+
6
+ # | GR module | | GR3 module |
7
+ # | +----------------+ | | +----------------+ |
8
+ # | | GR::FFI | | | | GR3::FFI | |
9
+ # | | + libGR.so | | | | + libGR3.so | |
10
+ # | +----------------+ | | +----------------+ |
11
+ # | | define_method | | | define_method |
12
+ # | +----------------+ | | +----------------+ |
13
+ # | | | GR::GRBase | | | | | GR3::GR3Base | |
14
+ # | | v (Pri^ate) | | | | v (Pri^ate) | |
15
+ # | +++--------------+ | | +++--------------+ |
16
+ # | | Extend | | | Extend |
17
+ # | v | | v +-------+ |
18
+ # | +-----------+ | | | Check | |
19
+ # | | GR::Plot | | | <--+ Error | |
20
+ # | +-----------+ | | +-------+ |
21
+ # +--------------------+ +----------+---------+
22
+ # ^ ^
23
+ # | +------------------+ |
24
+ # Extend | | GRCommons module | | Extend
25
+ # | | +--------------+ | |
26
+ # | | | Fiddley | | |
27
+ # | | +--------------+ | |
28
+ # | | +--------------+ | |
29
+ # +----+ CommonUtils +----+
30
+ # | | +--------------+ | |
31
+ # | | +--------------+ | |
32
+ # +----+ Version +----+
33
+ # | | +--------------+ |
34
+ # | | +--------------+ |
35
+ # +----+JupyterSupport| |
36
+ # | +--------------+ |
37
+ # +------------------+
38
38
  #
39
39
  # (You can edit the above AA diagram with http://asciiflow.com/))
40
40
  #
@@ -52,23 +52,20 @@ module GR
52
52
  attr_accessor :ffi_lib
53
53
  end
54
54
 
55
- raise Error, 'Please set env variable GRDIR' unless ENV['GRDIR']
55
+ require_relative 'gr_commons/gr_commons'
56
+ extend GRCommons::SearchSharedLibrary
56
57
 
57
58
  # Platforms | path
58
59
  # Windows | bin/libgr.dll
59
60
  # MacOSX | lib/libGR.so (NOT .dylib)
60
61
  # Ubuntu | lib/libGR.so
61
- if Object.const_defined?(:RubyInstaller)
62
- self.ffi_lib = File.expand_path('bin/libgr.dll', ENV['GRDIR'])
63
- RubyInstaller::Runtime.add_dll_directory(File.dirname(ffi_lib))
64
- else
65
- self.ffi_lib = File.expand_path('lib/libGR.so', ENV['GRDIR'])
66
- end
67
-
68
- # Change the default encoding to UTF-8.
69
- ENV['GKS_ENCODING'] ||= 'utf8'
62
+ self.ffi_lib = case RbConfig::CONFIG['host_os']
63
+ when /mswin|msys|mingw|cygwin|bccwin|wince|emc/
64
+ search_shared_library('libgr.dll')
65
+ else
66
+ search_shared_library('libGR.so')
67
+ end
70
68
 
71
- require_relative 'gr_commons/gr_commons'
72
69
  require_relative 'gr/version'
73
70
  require_relative 'gr/ffi'
74
71
  require_relative 'gr/grbase'
@@ -239,6 +236,9 @@ module GR
239
236
  # @param dimx [Integer] X dimension of the color index array
240
237
  # @param dimy [Integer] Y dimension of the color index array
241
238
  # @param color [Array, NArray] Color index array
239
+ # The values for `x` and `y` are in world coordinates. `x` must contain
240
+ # `dimx` + 1 elements and `y` must contain `dimy` + 1 elements. The elements
241
+ # i and i+1 are respectively the edges of the i-th cell in X and Y direction.
242
242
  def nonuniformcellarray(x, y, dimx, dimy, color)
243
243
  raise ArgumentError unless x.length == dimx + 1 && y.length == dimy + 1
244
244
 
@@ -502,6 +502,8 @@ module GR
502
502
  # * 129 : FONT_PALATINO_BOLDITALIC
503
503
  # * 130 : FONT_ZAPFCHANCERY_MEDIUMITALIC
504
504
  # * 131 : FONT_ZAPFDINGBATS
505
+ # * 232 : FONT_COMPUTERMODERN
506
+ # * 233 : FONT_DEJAVUSANS
505
507
  # @param precision [Integer] Text precision
506
508
  # * 0 : TEXT_PRECISION_STRING
507
509
  # * String precision (higher quality)
@@ -509,6 +511,8 @@ module GR
509
511
  # * Character precision (medium quality)
510
512
  # * 2 : TEXT_PRECISION_STROKE
511
513
  # * Stroke precision (lower quality)
514
+ # * 3 : TEXT_PRECISION_OUTLINE
515
+ # * Outline precision (highest quality)
512
516
  # The appearance of a font depends on the text precision value specified.
513
517
  # STRING, CHARACTER or STROKE precision allows for a greater or lesser
514
518
  # realization of the text primitives, for efficiency. STRING is the default
@@ -554,6 +558,14 @@ module GR
554
558
  super
555
559
  end
556
560
 
561
+ # Gets the current character height.
562
+ # This function gets the height of text output primitives. Text height is
563
+ # defined as a percentage of the default window. GR uses the default text
564
+ # height of 0.027 (2.7% of the height of the default window).
565
+ def inqcharheight
566
+ inquiry_double { |pt| super(pt) }
567
+ end
568
+
557
569
  # Set the current character text angle up vector.
558
570
  # @param ux [Numeric] Text up vector
559
571
  # @param uy [Numeric] Text up vector
@@ -1588,10 +1600,10 @@ module GR
1588
1600
  super(npoints, x, y, ntri, triangles.ref)
1589
1601
  end
1590
1602
  if n_tri > 0
1591
- tri = triangles.to_str(3 * n_tri * Fiddle::SIZEOF_INT).unpack('l*') # Int32
1603
+ tri = triangles.to_str(dim * n_tri * Fiddle::SIZEOF_INT).unpack('l*') # Int32
1592
1604
  # Ruby : 0-based indexing
1593
1605
  # Julia : 1-based indexing
1594
- tri = tri.each_slice(3).to_a
1606
+ tri = tri.each_slice(dim).to_a
1595
1607
  [n_tri, tri]
1596
1608
  else
1597
1609
  0
@@ -1798,31 +1810,32 @@ module GR
1798
1810
  end
1799
1811
  end
1800
1812
 
1801
- # Draw paths using given vertices and path codes.
1813
+ # Draw paths using the given vertices and path codes.
1802
1814
  # @param x [Array, NArray] A list containing the X coordinates
1803
1815
  # @param y [Array, NArray] A list containing the Y coordinates
1804
- # @param codes [String] Path codes
1816
+ # @param codes [String] A list containing the path codes
1805
1817
  # The following path codes are recognized:
1806
1818
  # * M, m
1807
- # * moveto x, y
1819
+ # * moveto x, y
1808
1820
  # * L, l
1809
- # * lineto x, y
1821
+ # * lineto x, y
1810
1822
  # * Q, q
1811
- # * quadratic Bézier x1, y1 x2, y2
1823
+ # * quadratic Bézier x1, x2 y1, y2
1812
1824
  # * C, c
1813
- # * cubic Bézier x1, y1 x2, y2 x3, y3
1814
- # * R, r
1815
- # * rectangle w, h
1825
+ # * cubic Bézier x1, x2, x3 y1, y2, y3
1816
1826
  # * A, a
1817
- # * arc w, h a1, a2
1827
+ # * arc rx, a1, reserved ry, a2, reserved
1818
1828
  # * Z
1819
- # * closepath -
1829
+ # * close path -
1830
+ # * s
1831
+ # * stroke -
1820
1832
  # * s
1821
- # * stroke -
1833
+ # * close path and stroke -
1822
1834
  # * f
1823
- # * fill -
1824
- # The values for `x` and `y` are in normalized device coordinates.
1825
- # The `codes` describe several patch primitives that can be used to create compound paths.
1835
+ # * close path and fill -
1836
+ # * F
1837
+ # * close path, fill and stroke -
1838
+ # See https://gr-framework.org/python-gr.html#gr.path for more details.
1826
1839
  def path(x, y, codes)
1827
1840
  n = equal_length(x, y)
1828
1841
  super(n, x, y, codes)
@@ -1968,22 +1981,41 @@ module GR
1968
1981
  end
1969
1982
  end
1970
1983
 
1971
- # This is an interface for REPL based languages to enable an easier way to
1972
- # rotate around an object.
1984
+ # Set the camera for orthographic or perspective projection.
1973
1985
  # The center of the 3d window is used as the focus point and the camera is
1974
- # positioned relative to it, using spherical coordinates. This function can
1975
- # therefore also be used if the user prefers spherical coordinates to setting
1976
- # the direct camera position, but with reduced functionality in comparison
1977
- # to gr.settransformationparameters, gr.setperspectiveprojection and
1978
- # gr.setorthographicprojection.
1979
- # @param phi [Numeric] phi angle of the spherical coordinates
1980
- # @param theta [Numeric] theta angle of the spherical coordinates
1986
+ # positioned relative to it, using camera distance, rotation and tilt similar
1987
+ # to gr_setspace. This function can be used if the user prefers spherical
1988
+ # coordinates to setting the camera position directly, but has reduced
1989
+ # functionality in comparison to GR.settransformationparameters,
1990
+ # GR.setperspectiveprojection and GR.setorthographicprojection.
1991
+ # @param phi [Numeric] azimuthal angle of the spherical coordinates
1992
+ # @param theta [Numeric] polar angle of the spherical coordinates
1981
1993
  # @param fov [Numeric] vertical field of view (0 or NaN for orthographic projection)
1982
- # @param radius [Numeric] distance between the camera and the focus point
1994
+ # @param camera_distance [Numeric] distance between the camera and the focus point
1983
1995
  # (0 or NaN for the radius of the object's smallest bounding sphere)
1984
- def transformationinterfaceforrepl(*)
1996
+ def setspace3d(*)
1997
+ super
1998
+ end
1999
+
2000
+ def text3d(*)
1985
2001
  super
1986
2002
  end
2003
+
2004
+ def inqtext3d(x, y, z, string, axis)
2005
+ inquiry [{ double: 16 }, { double: 16 }] do |tbx, tby|
2006
+ super(x, y, z, string, axis, tbx, tby)
2007
+ end
2008
+ end
2009
+
2010
+ def settextencoding(*)
2011
+ super
2012
+ end
2013
+
2014
+ def inqtextencoding
2015
+ inquiry_int do |encoding|
2016
+ super(encoding)
2017
+ end
2018
+ end
1987
2019
  end
1988
2020
 
1989
2021
  ASF_BUNDLED = 0
@@ -2202,6 +2234,9 @@ module GR
2202
2234
  XFORM_CUBIC = 4
2203
2235
  XFORM_EQUALIZED = 5
2204
2236
 
2237
+ ENCODING_LATIN1 = 300
2238
+ ENCODING_UTF8 = 301
2239
+
2205
2240
  UPSAMPLE_VERTICAL_DEFAULT = 0x00000000
2206
2241
  UPSAMPLE_HORIZONTAL_DEFAULT = 0x00000000
2207
2242
  DOWNSAMPLE_VERTICAL_DEFAULT = 0x00000000