Image/Pixel-Color Operations

<< Click to Display Table of Contents >>

Navigation:  3. Script Language > Image/Pixel-Color Operations > ANA. - Imageworks > Flip IR's >

Image/Pixel-Color Operations

ANA.VFlip - Flip IR vertically

Previous Top Next


MiniRobotLanguage (MRL)

 

ANA.VFlip

Flip an Image-Register (IR) vertically

 

 

Intention

 

This command will flip the Content of IR 1 vertically.

 

1. Just Flip IR P1 vertically

 

'This simple Script shows the Use of ANA.VFlip.

ANA.New|0|800|400

ANA.vgradient|0|&H000000|&HFFFFFF

ANA.New|1|800|400

ANA.hgradient|1|&H0000FF|&HFF0000

ANA.blendTo|0|1|2|160

ANA.Show|2!

' Make Resolution from P2 to the resolution from P1.

ANA.VFlip|2

DMP.6

ANA.Show|2!

ENR.

 

 

2. Flip P1 to P2

In this case, P1 will be H-Flipped to P2.

 

ANA.New|0|800|400

ANA.vgradient|0|&H000000|&HFFFFFF

ANA.New|1|800|400

ANA.hgradient|1|&H0000FF|&HFF0000

ANA.blendTo|0|1|2|160

ANA.Show|2!

ANA.VFlip|2|1

DMP.6

ANA.Show|1!

ENR.

 

 

' One more Sample with Output pictures see below

ANA.New|0|800|400

ANA.vgradient|0|&HFF0000|&H00FFFF

ANA.Show|0!

ANA.New|1|800|400

ANA.hgradient|1|&H00FFFF|&HFF0000

ANA.Show|1!

ANA.blendTo|0|1|2|160

ANA.Show|2!

ANA.VFlip|2

DMP.6

ANA.Show|2!

ENR.

 

 

 

 

 

  Effect of VFlip:

 

            VFlip_01    + VFlip_02   = VFlip_03  

 

Now we do the VFLIP:

 

            VFlip_04

 

 

 

 

Syntax

 

ANA.VFlip|P1][|P2]

 

Parameter Explanation

 

P1 - Image-Register number, this IR contains the Image that is to be H-Flipped.

P2 - opt. Destination Image-Register number, if omitted, P1 will be used as Destination.

 

The Command will leave a 0/1 on the TOS. As always, a 0 means Error, while a 1 means "all fine".

 

 

Example

 

'***********************************

' ANA.VFlip-Sample

'***********************************

ANA.New|0|800|400

ANA.vgradient|0|&H000000|&HFFFFFF

ANA.New|1|800|400

ANA.hgradient|1|&H0000FF|&HFF0000

ANA.blendTo|0|1|2|160

ANA.Show|2!

' Make Resolution from P2 to the resolution from P1.

ANA.VFlip|2

DMP.6

ANA.Show|2!

ENR.

 

 

 

Remarks

 

-

 

 

 

Limitations:

 

-

 

 

See also: