the solution i used to correct the steching is as follow.
`load the DLL if needed
Load Dll "user32.dll",1
`get the window screen format
Win_Width = Call Dll (USER32DLL,"GetSystemMetrics",0)
Win_Height = Call Dll (USER32DLL,"GetSystemMetrics",1)
`check the ratio of the screen
ScreenRatio = GetDesktopRatio(Win_Width,Win_Height)
Select ScreenRatio
Case RESOLUTION_TYPE_16_10:
Width = ((10.0/16.0)+1.0)*480.0
Endcase
Case Default:
Width = 640
Endcase
Endselect
Delete Dll 1
Function GetDesktopRatio(A As Integer,B As Integer)
Local Ratio
`Make first unknow Ratio
Ratio = RESOLUTION_TYPE_UNSUPPORTED
`Check for Ratio
If ((A*3)=(B*4)) Then Ratio = RESOLUTION_TYPE_4_3
If ((A*9)=(B*16)) Then Ratio = RESOLUTION_TYPE_16_9
If ((A*5)=(B*8)) Then Ratio = RESOLUTION_TYPE_16_10
If ((A*2)=(B*3)) Then Ratio =RESOLUTION_TYPE_3_2
If ((A*4)=(B*5)) Then Ratio =RESOLUTION_TYPE_5_4
If ((A*3)=(B*5)) Then Ratio =RESOLUTION_TYPE_5_3
If ((A*64)=(B*85)) Then Ratio =RESOLUTION_TYPE_85_64
If ((A*48)=(B*85)) Then Ratio =RESOLUTION_TYPE_85_48
If ((A*30)=(B*53)) Then Ratio =RESOLUTION_TYPE_53_30
If ((A*27)=(B*40)) Then Ratio =RESOLUTION_TYPE_40_27
Endfunction Ratio
this is a partly code i have.
Resolution types are constants numbered from 1 trough 10. So when the calculation is giving a match you got the number back.
KEEP IN MIND that you have do this before you call any kind of set dispay. Otherwise you get the screen you made as resolution.
this works for all kind of resolution in a 4:3 format.
From this point on you have to calculate where you put your piece of the screen. including black bands on the side (Or pick you owen color or picture)
Games is live so to live do the games