touchgfx::HAL::setFrameRefreshStrategy() method
@fn bool HAL::setFrameRefreshStrategy(FrameRefreshStrategy s) Set a specific strategy for handling timing and mechanism of frame buffer drawing. By setting a different frame refresh strategy, the internals of how TouchGFX interacts with the frame buffer can be modified. Currently there are two strategies available. This will increase over time. - REFRESH_STRATEGY_OPTIM_SINGLE_BUFFER_TFT_CTRL: this strategy is available on targets that use single buffering on a TFT controller based system. It requires an implementation of the getTFTCurrentLine() function as well as a task delay function being registered. The implementation of this strategy is that TouchGFX will carefully track the progress of the TFT controller, and draw parts of the frame buffer whenever possible. The effect is that the risk of tearing is much reduced compared to the default single buffer strategy of only drawing in porch areas. It does have a drawback of slightly increased MCU load. But in many cases employing this strategy will make it possible to avoid external RAM, by using just a single frame buffer in internal RAM and still avoid tearing. - REFRESH_STRATEGY_DEFAULT: This is a general strategy that works for all target configurations. Recommendation: Try using REFRESH_STRATEGY_OPTIM_SINGLE_BUFFER_TFT_CTRL if you're on a TFT controller based system (ie. non-8080) and you have a desire to avoid external RAM. Otherwise stick to REFRESH_STRATEGY_DEFAULT.
Arguments
s
The desired strategy to use.
Return value
true if the desired strategy will be used, false otherwise.
Functions called by touchgfx::HAL::setFrameRefreshStrategy()
touchgfx::HAL::setFrameRefreshStrategy()
Data read by touchgfx::HAL::setFrameRefreshStrategy()
Data written by touchgfx::HAL::setFrameRefreshStrategy()
touchgfx::HAL::setFrameRefreshStrategy()