Facebook Pixel

AN-00043 General 4DGL Colour CONSTANTS

Description This application note is dedicated to providing an easy reference to various Colour CONSTANTS available within the 4DGL language.
Supported Processor PICASO
Supported Environment Designer, ViSi, ViSi-Genie, Serial
Difficulty Easy

 

File Downloads
Files

Description

This application note is dedicated to providing an easy reference to various Colour CONSTANTS available within the 4DGL language.

Before getting started, the following are required:

 

Workshop 4 IDE (installed according to the installation document)

 Application Overview

Throughout 4D documentation, there are listings of various specialised internal functions for given processors. This application note is designed to assist the user, by presenting them with the various Colour Constant values possible. This will allow the user to get the most out of their module when creating graphics requiring a vibrant display of colours.

Setup Procedure

Locating Colour Constant Values

In addition to using this reference Manual Application Note, it should be noted where these Colour CONSTANTS are sourced from. In any given 4DGL program, there may be one or more include files that are inherited into the code. This is because these files contain critical values and functions needed to successfully run certain applications. The Colour CONSTANTS are sourced from the following include file and is inherited at the beginning of the application;

           

            #inherit "4DGL_16bitColours.fnc"

 

When 4DWorkshop4 IDE is installed, this include file is installed as an fnc file. To access the file, right click on the fnc file as seen above, from within 4DWorkshop4 IDE. A dropdown list will appear. Select the first option; ‘Open file at Cursor’. The following snapshots illustrate this point.

Once the Colour constants file is included in the application, User can use the colour constants in the program, such as,

gfx_circle(x, y, rad, colr);

gfx_circle(50, 50, 10, RED);

Colour Constants

Listed below is a list of all Colour CONSTANTS available for use within the 4DGL language.

 

Share: