English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Asm / Hardware

 
 
Thread Tools
Old 11 June 2022, 07:22   #1
HornBeamSoft
Registered User
 
Join Date: Aug 2020
Location: Namestovo/Slovakia
Posts: 16
288 pixels horizontal resolution

Few days ago I play Agony.
I made screen shot under uae and get that screen is 288 pixels wide.
I was almost sure that Amiga resolution in lores is 320 pixels?
I found in some sites that 320 pixels horizontal resolution is often reduced to 288 pixels wide to provide the game more time to process sprites, color changes object blitting etc.
I don't found how to change Amiga horizontal resolution to 288 pixels.
How to do this?
HornBeamSoft is offline  
Old 11 June 2022, 10:26   #2
alexh
Thalion Webshrine
 
alexh's Avatar
 
Join Date: Jan 2004
Location: Oxford
Posts: 14,334
I don't think you can but I am far from an expert.

I think you use a lowres 320x256 buffer and render fewer pixels into it?
alexh is online now  
Old 11 June 2022, 10:36   #3
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Quote:
Originally Posted by HornBeamSoft View Post
I found in some sites that 320 pixels horizontal resolution is often reduced to 288 pixels wide to provide the game more time to process sprites, color changes object blitting etc.
In Amiga you cannot change the base pixel clock.
So it means that if you want to display less than 320 pixels you have to narrow the view (the pixel is the same size).
Basically less data fetched for the screen, more time for other stuff.
ross is online now  
Old 11 June 2022, 16:12   #4
Thomas Richter
Registered User
 
Join Date: Jan 2019
Location: Germany
Posts: 3,215
Quote:
Originally Posted by HornBeamSoft View Post
Few days ago I play Agony.
I made screen shot under uae and get that screen is 288 pixels wide.
I was almost sure that Amiga resolution in lores is 320 pixels?
The horizontal resolution is whatever you make it to be. The DIWSTART and DIWSTOP registers allow you to position and size the playfield window, the DDFSTART and DDFSTOP registers allow you to control the playfield DMA.


Quote:
Originally Posted by HornBeamSoft View Post
I found in some sites that 320 pixels horizontal resolution is often reduced to 288 pixels wide to provide the game more time to process sprites, color changes object blitting etc.
Indeed, you need to move DDFSTART to the right (i.e. the playfield to the right) to free more slots for sprite DMA.


Or, from the operating point of view, adjust the overscan preferences, which is pretty much doing the same, but in an Os-friendly way.


That it's 320 pixels is more a convention, one can change that within limits. You cannot change the pixel clock (i.e. the speed by which pixels are delivered), but you can adjust the width and height of the playfield.
Thomas Richter is offline  
Old 11 June 2022, 16:20   #5
Rock'n Roll
German Translator
 
Rock'n Roll's Avatar
 
Join Date: Aug 2018
Location: Drübeck / Germany
Age: 49
Posts: 183
Agony Level 1

0005e9ce: 008e 2d90 ; DIWSTRT := 0x2d90
0005e9d2: 0090 00a0 ; DIWSTOP := 0x00a0
0005e9d6: 0092 0038 ; DDFSTRT := 0x0038
0005e9da: 0094 00c8 ; DDFSTOP := 0x00c8
BPLCON0 6600 ; lowres, 6 bitplanes, dual playfield

That is:
DDFSTRT = 0x0038 DDFSTOP = 0x00B8 (calculated)
top left_y =002D (=45) , top left_x =0090 (=144)
bottom right_y =0100 (=256), bottom right_x =01A0 (=416)
width=272 height=211 screensize 7174 bytes
Rock'n Roll is offline  
Old 11 June 2022, 19:54   #6
Rotareneg
Registered User
 
Rotareneg's Avatar
 
Join Date: Sep 2017
Location: Kansas, USA
Posts: 324
You could get 160 pixel wide screen modes on AGA, but I'm not sure about ECS.
Rotareneg is offline  
Old 11 June 2022, 20:00   #7
HornBeamSoft
Registered User
 
Join Date: Aug 2020
Location: Namestovo/Slovakia
Posts: 16
Now is clear hot to do it to me. Thank You All.
HornBeamSoft is offline  
Old 11 June 2022, 20:06   #8
aros-sg
Registered User
 
Join Date: Nov 2015
Location: Italy
Posts: 191
Quote:
Originally Posted by Thomas Richter View Post
You cannot change the pixel clock

Btw, how do modes like "EURO72:160 x 200" (a standard mode/monitor coming with the OS) manage to get 160 horizontal pixel resolution (it really does, I remember trying it on Microvitec Monitor in the 90s) if there's only 35, 70, 140 ns pixel clocks?
aros-sg is offline  
Old 11 June 2022, 20:36   #9
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Quote:
Originally Posted by aros-sg View Post
Btw, how do modes like "EURO72:160 x 200" (a standard mode/monitor coming with the OS) manage to get 160 horizontal pixel resolution (it really does, I remember trying it on Microvitec Monitor in the 90s) if there's only 35, 70, 140 ns pixel clocks?
It just double the horizontal frequency (using 140ns pixel clock).
ross is online now  
Old 12 June 2022, 10:21   #10
aros-sg
Registered User
 
Join Date: Nov 2015
Location: Italy
Posts: 191
Quote:
Originally Posted by ross View Post
It just double the horizontal frequency (using 140ns pixel clock).

So could you have something like a ~ 256x250 (multiply 160 x 200 by 1.25) screenmode with not double but only ~ 1.25 higher horizontal frequency?
aros-sg is offline  
Old 12 June 2022, 11:07   #11
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Quote:
Originally Posted by aros-sg View Post
So could you have something like a ~ 256x250 (multiply 160 x 200 by 1.25) screenmode with not double but only ~ 1.25 higher horizontal frequency?
It's the opposite, you have to lower the frequency (both horizontal and vertical), if you are using EURO72.
But anyway yes, the concept is that

EDIT:
in fact in ECS and AGA you can vary the video frequencies as you like and create any resolution you want with the base clock of 35ns and multiples (x1, x2 and x4).
The problem is a devices that can support it.
Also with the clock of 35.24ns (in PAL machines) you can not reach very high resolutions, that is something more than the VGA which have a pixel clock of 39.72ns.

EDIT2:
an example with ECS/OSSC:
https://eab.abime.net/showpost.php?p...2&postcount=11


To tell the truth for some technical issues it would be better to use less pixels in x and the two lower lines have the 'mark' of central synchronism, but let's say that 400x300 works great. And the frequency is the pure standard PAL one.
No problem on AGA and you can also double or quadruple the x resolution without any particular restrictions.

Last edited by ross; 12 June 2022 at 11:42.
ross is online now  
Old 15 June 2022, 17:51   #12
Rock'n Roll
German Translator
 
Rock'n Roll's Avatar
 
Join Date: Aug 2018
Location: Drübeck / Germany
Age: 49
Posts: 183
Agony DIWSTRT is not optimal, or?
DIWSTRT: 0x2D90 is DDFSTRT 0x38, but
DIWSTRT: 0x2D91 would be DDFSTRT 0x40 (ok, one px lose)
or they could take DIWSTRT: 0x2d81 for a bigger view

if I make the screen narrower with diwstrt and diwstop and leave ddfstrt and ddfstop as it is,
do I lose cycles for the cpu or does it not matter?
(of course, optimal would be to calculate the values for ddfstrt and ddfstop, or?)

Last edited by Rock'n Roll; 15 June 2022 at 21:01.
Rock'n Roll is offline  
Old 17 June 2022, 07:54   #13
Rock'n Roll
German Translator
 
Rock'n Roll's Avatar
 
Join Date: Aug 2018
Location: Drübeck / Germany
Age: 49
Posts: 183
0005e9ce: 008e 2d90 ; DIWSTRT := 0x2d90
0005e9d2: 0090 00a0 ; DIWSTOP := 0x00a0
0005e9d6: 0092 0038 ; DDFSTRT := 0x0038
0005e9da: 0094 00c8 ; DDFSTOP := 0x00c8

in my opinion better would be:
DIWSTRT := 0x2d91 with DDFSTRT := 0x0040
DIWSTOP := 0x00a1 with DDFSTRT := 0x00C0
because alignment with DDF-borders
screenwidth is 272px (17*16Bit)
Rock'n Roll is offline  
Old 17 June 2022, 12:13   #14
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
But aren't Agony' video DIW values set that way due to fine scroll? You need a larger DDF for it...
ross is online now  
Old 17 June 2022, 13:56   #15
VladR
Registered User
 
Join Date: Dec 2019
Location: North Dakota
Posts: 741
Quote:
Originally Posted by Rotareneg View Post
You could get 160 pixel wide screen modes on AGA, but I'm not sure about ECS.
Would that be a native mode ? This is very interesting!
I always thought 160x200 would be very practical for a SW rasterizer on Amiga, and not just 3D flatshading, but racing games in particular would really benefit from this.

Like, you could have a really nice racing game at 160x200 and EHB. This resolution would halve the amount of bitplane fetches, so EHB there should be faster than 320x200x4 BPL, right ?

320x200x4 BPL : 8,000 (40 x 200) x 4 = 32,000
160x200x6 BPL : 4,000 (20 x 200) x 6 = 24,000

This also means there's enough time for Copper to switch palette 2-3 times across the screen and allow for both additional 64 colors for the skybox and some additional shading (say, for fog into distance).
Lock the framerate to 20 fps (but do not allow for single framedrop, so must account for all spiked) and it's a very colorful game.
VladR is offline  
Old 17 June 2022, 14:10   #16
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Quote:
Originally Posted by VladR View Post
Would that be a native mode ?
http://eab.abime.net/showpost.php?p=1549622&postcount=9
ross is online now  
Old 17 June 2022, 14:30   #17
VladR
Registered User
 
Join Date: Dec 2019
Location: North Dakota
Posts: 741
Quote:
Originally Posted by ross View Post
EDIT:
in fact in ECS and AGA you can vary the video frequencies as you like and create any resolution you want with the base clock of 35ns and multiples (x1, x2 and x4).
Do I get that right that ECS is the lowest config capable of native 160x200 then ? Meaning, you can't adjust the frequencies same way on OCS ?
VladR is offline  
Old 17 June 2022, 15:35   #18
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Quote:
Originally Posted by VladR View Post
Do I get that right that ECS is the lowest config capable of native 160x200 then ? Meaning, you can't adjust the frequencies same way on OCS ?
Right.
And also there is the problem that a device that supports the frequency is required (no longer a PAL or NTSC standard).
ross is online now  
Old 17 June 2022, 16:11   #19
VladR
Registered User
 
Join Date: Dec 2019
Location: North Dakota
Posts: 741
Quote:
Originally Posted by ross View Post
Right.
And also there is the problem that a device that supports the frequency is required (no longer a PAL or NTSC standard).
Thanks.

I imagine CRT monitors to be finicky about the required frequency, that was quite fun back in the day...

But these days with LCD, this shouldn't be an issue, I reckon ?

160x200 on AGA would be probably quite ridiculed, but on ECS it just might be acceptable...
VladR is offline  
Old 17 June 2022, 17:26   #20
rothers
Registered User
 
Join Date: Apr 2018
Location: UK
Posts: 487
How would sprites behave in such a resolution?
rothers is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
WinUAE adjusting max visible horizontal resolution - is it possible ? BigT support.WinUAE 2 26 April 2020 15:43
Games - Best Resolution + Horizontal & Vertical + Position DamienD support.Games 0 27 December 2015 13:28
[Found: Resolution 101] "Scaled pixels" - "fly in a skyscraper city" Photon Looking for a game name ? 5 06 August 2007 15:26
REQ: Automatic resolution change ; automatic resolution detection Borg_Number_One request.UAE Wishlist 3 21 August 2004 14:16
Few games don't switch resolution from video card to native amiga resolution! digital support.WinUAE 12 14 March 2003 13:23

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 16:52.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.14189 seconds with 13 queries