tftdrawthickcircle

ivanmason/tft-lcd-touch/tftdrawthickcircle

No description
tftdrawthickcircle
@/tftdrawthickcircle
DEV@/tftlcd-device
Xnumber
Start X
Ynumber
Start Y
RADnumber
THKnumber
Thickness of line
COLnumber
UPDpulse
tftdrawthickcircle
DEV
X
Y
RAD
THK
COL
UPD
DONE
DONEpulse
To use the node in your project you should have the ivanmason/tft-lcd-touch library installed. Use the “File → Add Library” menu item in XOD IDE if you don’t have it yet. See Using libraries for more info.

C++ implementation

struct State {
};

{{ GENERATED_CODE }}

void evaluate(Context ctx) {
    if (!isInputDirty<input_UPD>(ctx))
        return;
   
    auto tft = getValue<input_DEV>(ctx);
    int16_t x0 = getValue<input_X>(ctx);
    int16_t y0 = getValue<input_Y>(ctx);
    int16_t r = getValue<input_RAD>(ctx);
    auto thick = getValue<input_THK>(ctx);
    uint16_t color = getValue<input_COL>(ctx);

    for(int i = 0;i <= thick;i++){
        tft->drawCircle(x0, y0, r + i, color);
    }
    emitValue<output_DONE>(ctx, 1);
}