AP_OSD: skip backend drawing for boards without font backends
this saves a lot of flash space on boards that want the MSP OSD system but not the MAX7456 backend
This commit is contained in:
parent
25746ef27e
commit
0e55a63be2
@ -253,7 +253,13 @@ void AP_OSD::update_osd()
|
|||||||
update_current_screen();
|
update_current_screen();
|
||||||
|
|
||||||
screen[current_screen].set_backend(backend);
|
screen[current_screen].set_backend(backend);
|
||||||
|
|
||||||
|
// skip the drawing if we are not using a font based backend. This saves a lot of flash space when
|
||||||
|
// using the MSP OSD system on boards that don't have a MAX7456
|
||||||
|
#if defined(WITH_SITL_OSD) || defined(HAL_WITH_SPI_OSD)
|
||||||
screen[current_screen].draw();
|
screen[current_screen].draw();
|
||||||
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
backend->flush();
|
backend->flush();
|
||||||
|
Loading…
Reference in New Issue
Block a user