[mythtv-users] Re: Custom Modeline

Cory Papenfuss papenfuss at juneau.me.vt.edu
Mon Jul 19 12:50:33 EDT 2004


 	I don't have a PVR-350, so I haven't looked into it.  I know the NVIDIA 
crowd talks about TVOverscan Options and such... if the PVR-350 has that, it'd 
be a better way to go.

 	Unless it's got some weird div/16 requirements (some cards have modes 
that won't go because they must be evenly divisible by 8 or 16, or have nice 
dotclocks, etc), you should be able to change visual resolutions without 
changing the raster size resolution.  I more or less mentioned that a few posts 
back.

Your original line:
ModeLine "720x480" 34.563 720 752 840 928 480 484 488 504 -HSync -VSync
(difference between numbers) 32  88  88      4   4   16

... can be set to underscan to 624x440 (96 less H, 40 less v... take 48 off 
each side, and 20 off both top and bottom):

ModeLine "624x440" 34.563 624 704 792 928 440 464 468 504 -HSync -VSync
                              80  88  136     24  4   36

The raster specs:
34.563 dotclock,
Hsync width of 88 pixels, total of 928 dots
Vsync width of 4  lines,  total of 504 lines

stay the same... just "letterboxing" the picture to a smaller size.  It's 
crude, but it's practically guaranteed to work (unless the card can't be 
programmed to that line for above mentioned or other reasons).

-Cory

*************************************************************************
* The prime directive of Linux:  					*
* 	- learn what you don't know, 					*
* 	- teach what you do.						*
* 						(Just my 20 USm$)	*
*************************************************************************


On Mon, 19 Jul 2004, Jim Sager wrote:

> Cory,
>
> Excuse my ignorance with respect to modelines. I have read through the
> discussion here and I have a question regarding underscanning the PVR-350
> TV-Out - can it be done using the modeline settings? Basically this is the
> setting that I currently have (found in myth setup documentation):
>
> Section "Monitor"
>        Identifier  "NTSC Monitor"
>        HorizSync  30-68
>        VertRefresh 50-120
>        Mode "720x480"
>          # D: 34.563 MHz, H: 37.244 kHz, V: 73.897 Hz
>          DotClock 34.564
>          HTimings 720 752 840 928
>          VTimings 480 484 488 504
>          Flags    "-HSync" "-VSync"
>        EndMode
> EndSection
>
> I currently have myth set to reduce the display size to 624x440 in order to
> fit in the TV screen (also have it running in a window since the x and y
> offsets don't appear to work unless you do so). Can the modeline settings be
> used to reduce the size of the visible picture and produce the correct offset
> to center it on the screen? I am truly showing my ignorance here with respect
> to modeline settings as well as an understanding of the hardware that's
> involved.
>
> Thanks,
> Jim
>
> On Friday 16 July 2004 07:50 am, Cory Papenfuss wrote:
>>  	It's certainly not the fault of the modelines that the TV is
>> overscanned.  Rather, it's that historically TV pictures have always been
>> overscanned and the switch to HDTV apparently hasn't fixed that (?).  If
>> you raster the specified visual resolution with the standard timings, the
>> picture will be overscanned.  Since you (and I for that matter) are
>> essentially driving the TV directly from the VGA port, it's *REQUIRED* to
>> output an ATSC standard video signal raster with standard timings.  If
>> you're TV is tolerant of something other than that, great... but make sure
>> it is by the book or you can blow it up.
>>
>>  	With all that said, remember that although the spec might specify
>> visual size (e.g. 1920x1080) in addition to the raster size/speed, it's the
>> raster that must be correct to avoid TV damage.  Think of the raster as the
>> black canvas that's painted at a certain rate consisting of a certain
>> number of lines.  For illustrative purposes, I scoured the 'net and found a
>> 1080i modeline that does appear to have a 33.75kHz horizonal frequency
>> (that appears to the be correct standard rate for 1080i... 45kHz for 720p
>> BTW):
>>
>> Modeline "1080i" 74.250 1920 2008 2048 2200 1080 1084 1094 1125 interlace
>>
>>  	You could use the same modeline, but have a letterboxed 1024x768
>> *visual* (upper left hand corner) by modifying it as follows:
>> Modeline "test" 74.250 1024 2008 2048 2200 768 1084 1094 1125 interlace
>>
>>  	Or try to move it towards the center by 200 pixels H/V:
>> Modeline "test" 74.250 1024 1808 1848 2200 768 884 894 1125 interlace
>>
>>  	In all those cases, the oscillators in the TV won't change at all...
>> just when and for how long the video guns turn pixels on and off.
>>
>>  	So if you are trying to vertically "underscan" the mode and can live
>> with running a "standard" HDTV raster with a "nonstandard" HDTV
>> visual resolution,
>>
>> Modeline "test2" 74.250 1920 2008 2048 2200 980 1034 1044 1125 interlace
>>
>> will keep the TV happy, and you should have a 1920x980 resolution, with 50
>> additional black pixels on both the top and the bottom.  Although it's a
>> funky resolution, playing video on a linux box usually uses XV for scaling
>> anyway, so it usually scales to fit accordingly.  If you're trying to
>> actually play all 1080 lines of a bone-fide 1080i orginal source material
>> without losing any lines off the screen, you'll need more than a
>> modeline.... like a TV fancy enough to adjust the screen position, or
>> unfancy enough to take a screwdriver to it and adjust the raster.
>>
>> Cheers
>> -Cory
>>
>>
>> *************************************************************************
>> * The prime directive of Linux:  					*
>> * 	- learn what you don't know, 					*
>> * 	- teach what you do.						*
>> * 						(Just my 20 USm$)	*
>> *************************************************************************
>>
>> On Thu, 15 Jul 2004, Chris Vargas wrote:
>>> Cory: your initial reply to John caught my eye,
>>> because I'm in John's same boat. At first I thought
>>> I'd be able to correct it given your great explanation
>>> of modelines, but now I'm not so sure.
>>>
>>> I have a 9A60 transcoder (thanks yet again, Jarod!),
>>> and am trying to adjust the vertical dimension as
>>> well. My 480p modeline plays back anamorphic DVDs
>>> correctly, but my 540p and 1080i modelines (derived
>>> via Powerstrip) are all stretched too far vertically,
>>> so that an anamorphic test pattern displays circles as
>>> ovals.
>>>
>>> Wouldn't I need to add vertical lines to get this
>>> compression? I tried using one of your examples to add
>>> (say) 40 pixels vertically, but if it's not going to
>>> work and blow up my TV, maybe not. Then again, it's 3
>>> years old and doesn't do 720p, so maybe I should blow
>>> it up...
>
> --
> jim
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>


More information about the mythtv-users mailing list