You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like TVout to have the ability to call a hook during the vertical blanking
interval. I am using this capability to communicate with an I2C device.
Example implementation
TVout.h:
// declaration of set_vbi_hook function
void set_vbi_hook(void (*func)());
TVout.cpp:
// implementation of set_vbi_hook
void TVout::set_vbi_hook(void (*func)()) {
vbi_hook = func;
}
video_gen.h:
// extern declaration of vbi_hook function pointer
extern void (*vbi_hook)();
video_gen.cpp:
// declaration of vbi_hook function pointer and invocation of function at
beginning of VBI
void (*vbi_hook)();
// in active_line()...
if ((display.scanLine + 1) == display.stop_render) {
line_handler = &blank_line;
if (vbi_hook != 0) {
vbi_hook();
}
}
Let me know if you have any questions; this should be pretty self explanatory
for you.
Original issue reported on code.google.com by nootropi...@gmail.com on 15 Oct 2010 at 9:02
The text was updated successfully, but these errors were encountered:
Original issue reported on code.google.com by
nootropi...@gmail.com
on 15 Oct 2010 at 9:02The text was updated successfully, but these errors were encountered: