1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-24 16:55:36 +03:00

OSD: Move crosshair to active elements and not background

This commit is contained in:
Miguel Angel Mulero Martinez 2020-06-25 13:50:16 +02:00
parent d85b372ae7
commit 10a67e3a1a

View file

@ -702,7 +702,7 @@ static void osdElementCrashFlipArrow(osdElementParms_t *element)
}
#endif // USE_ACC
static void osdBackgroundCrosshairs(osdElementParms_t *element)
static void osdElementCrosshairs(osdElementParms_t *element)
{
element->buff[0] = SYM_AH_CENTER_LINE;
element->buff[1] = SYM_AH_CENTER;
@ -1619,7 +1619,7 @@ const osdElementDrawFn osdElementDrawFunction[OSD_ITEM_COUNT] = {
[OSD_CAMERA_FRAME] = NULL, // only has background. Added first so it's the lowest "layer" and doesn't cover other elements
[OSD_RSSI_VALUE] = osdElementRssi,
[OSD_MAIN_BATT_VOLTAGE] = osdElementMainBatteryVoltage,
[OSD_CROSSHAIRS] = NULL, // only has background
[OSD_CROSSHAIRS] = osdElementCrosshairs, // only has background, but needs to be over other elements (like artificial horizon)
#ifdef USE_ACC
[OSD_ARTIFICIAL_HORIZON] = osdElementArtificialHorizon,
#endif
@ -1728,7 +1728,6 @@ const osdElementDrawFn osdElementDrawFunction[OSD_ITEM_COUNT] = {
const osdElementDrawFn osdElementBackgroundFunction[OSD_ITEM_COUNT] = {
[OSD_CAMERA_FRAME] = osdBackgroundCameraFrame,
[OSD_CROSSHAIRS] = osdBackgroundCrosshairs,
[OSD_HORIZON_SIDEBARS] = osdBackgroundHorizonSidebars,
[OSD_CRAFT_NAME] = osdBackgroundCraftName,
#ifdef USE_OSD_STICK_OVERLAY