You must continue sending properly timed horizontal and vertical sync pulses during the vertical and horizontal blanking intervals.
That's right!
Sync pulse is generated by timer1.
It's hard ware but you must change data when vertical sync start and end.
And there ia a little technique.
Even if interlaced, you must count over 255 for H-line.
But ATmega 328 is 8bit core.
I struggled and tried.
Please compare "INT_ICF1_BAP_A0.cpp" and "INT_ICF1_BAP_A1.cpp".
They are written in C langauge.
Because I have not masterd AVR assembly language.
Poccesing time
A1[(unsigned char)UB_h_line ] < A0 [(unsigned short)UH_h_line ]
So thinking and doing is interesting.