Class: Wx::GraphicsMatrix
- Inherits:
-
GraphicsObject
- Object
- Object
- GraphicsObject
- Wx::GraphicsMatrix
- Defined in:
- lib/wx/doc/gen/graphics_object.rb
Overview
A GraphicsMatrix is a native representation of an affine matrix.
The contents are specific and private to the respective renderer. Instances are ref counted and can therefore be assigned as usual. The only way to get a valid instance is via Wx::GraphicsContext#create_matrix or Wx::GraphicsRenderer#create_matrix.
Category: Graphics Device Interface (GDI)
Instance Method Summary collapse
-
#concat(t) ⇒ void
Concatenates the matrix passed with the current matrix.
-
#get ⇒ Array(Float,Float,Float,Float,Float,Float)
Returns the component values of the matrix via the argument pointers.
-
#invert ⇒ void
Inverts the matrix.
-
#is_equal(t) ⇒ Boolean
(also: #equal?)
Returns true if the elements of the transformation matrix are equal.
-
#is_identity ⇒ Boolean
(also: #identity?)
Return true if this is the identity matrix.
-
#rotate(angle) ⇒ void
Rotates this matrix clockwise (in radians).
-
#scale(xScale, yScale) ⇒ void
Scales this matrix.
-
#set(a = 1.0, b = 0.0, c = 0.0, d = 1.0, tx = 0.0, ty = 0.0) ⇒ void
Sets the matrix to the respective values (default values are the identity matrix).
-
#transform_distance ⇒ Array(Float,Float)
Applies this matrix to a distance (ie.
-
#transform_point ⇒ Array(Float,Float)
Applies this matrix to a point.
-
#translate(dx, dy) ⇒ void
Translates this matrix.
Methods inherited from GraphicsObject
Methods inherited from Object
#clone, #dup, #initialize, #is_same_as, #un_share
Constructor Details
This class inherits a constructor from Wx::Object
Instance Method Details
#concat(t) ⇒ void
This method returns an undefined value.
Concatenates the matrix passed with the current matrix.
The effect of the resulting transformation is to first apply the transformation in t to the coordinates and then apply the transformation in the current matrix to the coordinates.
// matrix = t x matrix
443 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 443 def concat(t) end |
#get ⇒ Array(Float,Float,Float,Float,Float,Float)
Returns the component values of the matrix via the argument pointers.
447 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 447 def get; end |
#invert ⇒ void
This method returns an undefined value.
Inverts the matrix.
451 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 451 def invert; end |
#is_equal(t) ⇒ Boolean Also known as: equal?
Returns true if the elements of the transformation matrix are equal.
456 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 456 def is_equal(t) end |
#is_identity ⇒ Boolean Also known as: identity?
Return true if this is the identity matrix.
461 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 461 def is_identity; end |
#rotate(angle) ⇒ void
This method returns an undefined value.
Rotates this matrix clockwise (in radians).
467 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 467 def rotate(angle) end |
#scale(xScale, yScale) ⇒ void
This method returns an undefined value.
Scales this matrix.
473 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 473 def scale(xScale, yScale) end |
#set(a = 1.0, b = 0.0, c = 0.0, d = 1.0, tx = 0.0, ty = 0.0) ⇒ void
This method returns an undefined value.
Sets the matrix to the respective values (default values are the identity matrix).
483 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 483 def set(a=1.0, b=0.0, c=0.0, d=1.0, tx=0.0, ty=0.0) end |
#transform_distance ⇒ Array(Float,Float)
Applies this matrix to a distance (ie.
performs all transforms except translations).
489 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 489 def transform_distance; end |
#transform_point ⇒ Array(Float,Float)
Applies this matrix to a point.
493 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 493 def transform_point; end |
#translate(dx, dy) ⇒ void
This method returns an undefined value.
Translates this matrix.
499 |
# File 'lib/wx/doc/gen/graphics_object.rb', line 499 def translate(dx, dy) end |