procedure TFT_Set_Brush(...);

General discussion on mikroPascal PRO for ARM.
Post Reply
Author
Message
DanilinS
Posts: 16
Joined: 15 Feb 2015 21:30

procedure TFT_Set_Brush(...);

#1 Post by DanilinS » 09 Jan 2017 17:51

brush_enabled := true
and
gradient_enabled := true

Is this right? Will be brushed or gradient?

User avatar
danilo.milovic
mikroElektronika team
Posts: 501
Joined: 05 Dec 2016 14:59

Re: procedure TFT_Set_Brush(...);

#2 Post by danilo.milovic » 10 Jan 2017 13:03

Hi,

here's the link for example how to use TFT_Set_Brush();

http://download.mikroe.com/documents/co ... _set_brush

Your command needs to look like this:

Code: Select all

	
// Enable gradient from black to white color, left-right orientation
TFT_Set_Brush(0, 0, 1, LEFT_TO_RIGHT, CL_BLACK, CL_WHITE);
Regards,

Danilo

DanilinS
Posts: 16
Joined: 15 Feb 2015 21:30

Re: procedure TFT_Set_Brush(...);

#3 Post by DanilinS » 10 Jan 2017 18:22

I know the correct command format.
Now I want to rewrite the standard libraries for use in your project (SSD1963 + FSMC). To rewrite the Feature I need to more accurately know the behavior of functions.

If I do brush_enabled: = true and gradient_enabled = three - how to behave in a function?

Do you understand Russian? Google translator is often translated incorrectly.

User avatar
danilo.milovic
mikroElektronika team
Posts: 501
Joined: 05 Dec 2016 14:59

Re: procedure TFT_Set_Brush(...);

#4 Post by danilo.milovic » 11 Jan 2017 12:08

Hi,

if you use following code:

Code: Select all

TFT_Set_Brush(1, CL_BLACK, 1, LEFT_TO_RIGHT, CL_BLACK, CL_WHITE);
TFT_Rectangle(0, 0, 320, 240);
so both brush_enabled : 1 and gradient_enabled : 1

picture of TFT is in attach, there you will see what you get, gradient goes from left to right from black to white color.

Regards,

Danilo
Attachments
tftphoto.zip
(1.07 MiB) Downloaded 182 times

DanilinS
Posts: 16
Joined: 15 Feb 2015 21:30

Re: procedure TFT_Set_Brush(...);

#5 Post by DanilinS » 11 Jan 2017 18:39

Thank you.

Post Reply

Return to “mikroPascal PRO for ARM General”