Store › Forums › Video Experimenter › General Discussion › Using PAL prevents rendering to lower 1/3rd of the screen
- This topic has 3 replies, 2 voices, and was last updated 10 years, 9 months ago by
Michael.
-
AuthorPosts
-
February 10, 2015 at 8:44 pm #751
experimenter
MemberHi,
I have a strange issue while using this design for overlay purpose. Setting mode to NTSC and everything seems normal. If i use PAL then for some reason I can not make use of the lower 1/3rd of the screen.say for example I set the resolution to 128×96 and I use a 4×6 font. If I overlay a message to line 90 it appears about two thirds down the screen. If I use a lower line then it doesnt appear at all since it’s clearly beyond the defined 96 resolution. This doesnt seem to be an issue with NTSC.
The problem is almost as if the line counting does not differentiate between NTSC and PAL even though the Vsync will occure 100 lines later on the PAL which I can’t take advantage of.
Thank you in advance for the help.
February 11, 2015 at 10:29 pm #2175Michael
KeymasterThat’s odd, because the logic is all the same except for timing parameters. I’m afraid I don’t know a solution. Have you tried different TVs and video sources?
February 12, 2015 at 12:08 am #2176experimenter
MemberI found a way to remedy by adding an offset to the sync line under video_gen.cpp
if (mode) {
display.start_render = _PAL_LINE_MID – ((display.vres * (display.vscale_const+1))/2)+40; // added the “40” to shift all lines lower.
display.output_delay = _PAL_CYCLES_OUTPUT_START;
display.vsync_end = _PAL_LINE_STOP_VSYNC;
display.lines_frame = _PAL_LINE_FRAME;
ICR1 = _PAL_CYCLES_SCANLINE;
OCR1A = _CYCLES_HORZ_SYNC;
}Another question michael. I would like to know which variable tracks how many sync lines where read before int0 is triggered with the vsync signal. It seems that “display.scanLine” only ramps up to 7 before getting the interrupt signal which I dont understand but it also means that this is not the correct line counter variable. Basically I would like to write a script that would distinguish PAL from NTSC on the fly via tracking how many lines came in before the vsync trigger.
Thanks again for the help.
February 12, 2015 at 2:27 am #2177Michael
KeymasterscanLine should be the right variable. I’m not sure why you see it only go up to 7. That’s the one.
(based on my fuzzy memory of 4 years ago when I developed this product). I’m not the author of TVout, so I had to learn it just by looking at the code. -
AuthorPosts
- You must be logged in to reply to this topic.