Tsev > Xov xwm > Ntsiab lus

CMD_GAUGE - Kos Ib Daim Phiaj Xwm

Apr 27, 2019

image

C daim ntawv prototype

tsis muaj dabtsis cmd_gauge (int16_t x,

int16_t y,

int16_t r,

uint16_t xaiv,

uint16_t loj,

uint16_t me,

uint16_t val,

uint16_t ntau);

Cov lus qhia

x

X-ko taw ntawm gauge center, hauv pixels

y

Y-coordinate ntawm gauge chaw, hauv pixels

r

Radius ntawm cov koob ntsuas pa, hauv pixels

kev xaiv

Los ntawm vim tus hu gauge hu yog twv nrog 3D effect thiab cov nqi ntawm cov kev xaiv yog

xoom. OPT_FLAT tshem tawm cov nyhuv 3D. Nrog xaiv OPT_NOBACK, tus

tom qab tsis tuaj. Muaj kev xaiv OPT_NOTICKS, cov zuam cim tsis yog

kos. Nrog rau kev xaiv OPT_NOPOINTER, tus pointer yog tsis kos.

loj

Tus lej ntawm cov khoom loj loj ntawm tus xov tooj, 1-10

me me

Tus lej ntawm cov khoom me me ntawm tus xov tooj, 1-10

val

Gauge qhia tus nqi, ntawm 0 thiab ntau, suav nrog

ntau

Tus nqi siab tshaj plaws

Kev piav qhia

Cov ntsiab lus ntawm lub cev dimension yog

 Tick marks yog muab tso rau ntawm 270 degree arc, clockwise pib ntawm txoj haujlwm ntawm sab hnub poob

 Cov me zuam me yog cov kab ntawm r * (2/256), loj r * (6/256)

 Ticks raug kos nyob ze ntawm r * (190/256) mus r * (200/256)

 Tus pointer kos nrog cov kab ntawm dav r * (4/256), mus rau ib qho

r * (190/256) los ntawm qhov chaw

 Lwm qhov xaus ntawm kab yog txhua qhov chaw 90 degrees perpendicular rau

qhov kev taw qhia pointer, ntawm qhov kev khiav r * (3/256) los ntawm qhov chaw

Xa mus rau cov tshuab hluav taws xob cav cov voj voog ntawm lub cev kom paub ntxiv.

image

image

image

image

image

image

image

image

image

image

image