15 July 2018, 12:51 | #21 | ||
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Quote:
Video timings changed due to 3 (2pf) hires planes (so similar DMA usage as 6 lowres planes), changed also DDFSTRT/STOP but DIWSTRT/STOP in sync to copper COLOR00 changes. FSizzle please can you check if half pixel mismatch is visible in your A1200? (maybe there are different versions that have different behaviors?) Waiting real test from Master Wilen for a definitive response. -- Quote:
You write so many interesting things that it would take a secretary to collect everything and make an encyclopedia Well, when you have time it's an interesting change to increase AGA compatibility. |
||
15 July 2018, 19:28 | #22 | |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
Quote:
EDIT: I did some tests and it happens in hires too, same 1 hires pixel extra delay. Last edited by Toni Wilen; 15 July 2018 at 20:00. |
|
15 July 2018, 19:59 | #23 |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Cumulative EDIT:
Ok, thanks! A solution in a real Amiga, if a game use this feature, can be: Code:
if (AGA) { set a fixed delay, to all playfields, of half lores pixel for every BPLCON1's value set DIWHIGH accordingly } Last edited by ross; 15 July 2018 at 21:20. Reason: cumulative edit |
15 July 2018, 20:01 | #24 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
I just edited above post (first test case was not that good). It happens in lores and hires, same 1 hires pixel delay in both modes.
|
15 July 2018, 20:32 | #25 | |
Registered User
Join Date: Nov 2017
Location: Los Angeles
Posts: 49
|
Quote:
- 1 - every second pixel misaligned on left side. Right shows extra non-white pixel column - 2 - same as 1 - 3 - same as 1 - 4 - right side shows two non-white pixels (left side now matches) - 5 - same as 4 In hires mode, the mismatches seem to be one hi-res pixel, which is consistent with lowres (half a lowres pixel = one hires pixel after all ) I attached an image showing these 2 states, comparing left and right on real HW vs WinUAE |
|
15 July 2018, 20:36 | #26 |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
|
15 July 2018, 20:46 | #27 | |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Quote:
Actually states are 4, one was a mistake in my code due to an erroneous shift initialization Thanks for your time! |
|
17 July 2018, 10:14 | #28 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
winuae.7z now adds hires pixel delay to all color register writes if AGA which seems to "fix" this problem. It was very simple change and has nothing to do with BPLCON1 hires/shres missing feature.
But because this causes quite ugly mismatched borders in some games, it most likely looks like new UAE bug.. EDIT: I guess delay may come from BPLCON4 XOR operation. Because when BPLCON4 is modified, it isn't instant but adds another hires pixel delay (was lores previously in emulation but it is actually extra hires = 1 + 1 hires = 1 lores) before colors change after BPLCON4 modification. EDIT2: HAM and EHB needs testing, some HAM/EHB bits bypass BPLCON4 so in worst case there are 2 possible delays.. (http://eab.abime.net/showthread.php?t=85588) Last edited by Toni Wilen; 17 July 2018 at 10:28. |
17 July 2018, 12:14 | #29 | ||||
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Quote:
Quote:
Quote:
It is not better to leave as before and mask-out H1 in lores screens cases? At least as long as there is no full AGA shires/hires shift support. Quote:
Thanks as always! |
||||
17 July 2018, 20:57 | #30 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
I started implementing proper subpixel support, more information when/if it starts working... I'll probably enable hires pixel color delay emulation only when subpixel emulation is also enabled.
|
17 July 2018, 22:36 | #31 |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
|
18 July 2018, 07:33 | #32 | ||
Registered User
Join Date: Nov 2017
Location: Los Angeles
Posts: 49
|
Quote:
Quote:
|
||
18 July 2018, 08:47 | #33 | ||
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Quote:
Anyway you've to set DIWHIGH appropriately and there're two little drawback: - forced black at border with loss in that area of any graphic element (sprite or copper effects) - the lose of one half-pixel at the left edge (but this is really insignificant ) EDIT: thinking about it better, the former can be a not too little problem for AGA productions that use FMODE=3/7 and cover left edge with sprite(s) to compensate the bigger DDFSTRT and large 64bit scroll. Therefore the use of BRDRBLNK should be carefully weighed and the pros and cons evaluated. Quote:
Last edited by ross; 18 July 2018 at 09:13. |
||
19 July 2018, 03:54 | #34 | |
Registered User
Join Date: Nov 2017
Location: Los Angeles
Posts: 49
|
Quote:
My plan is to check if running on AGA and build the copperlist differently, so that for OCS I continue to change the background color in sync with DIWSTRT/STOP as I do now, but for AGA, I instead change the color only before the start of each display line and use BRDRBLNK to mask off the border. If I do this, I don't need to tweak DIWHIGH either. In my case I want the border black in all cases, as I think it looks nicer, so the effect of BRDRBLNK masking is desirable. I would use it for OCS if it was available instead of the explicit timing which burns a lot of copper cycles I believe BRDRBLNK is avilable on ECS as well, but it's simpler for me to keep it the same as OCS so I don't complicate the copper list construction code with a 3rd set of timings to handle (it's already complex enough with all the sprite multiplexing interleaved with palette changes and other display trickery Last edited by FSizzle; 19 July 2018 at 03:55. Reason: typo |
|
19 July 2018, 10:49 | #35 |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Yep, for your needs it's the best way to do
Unlucky my 'patch' habit for old demos/games require a different approach. Back to Lionheart's example: it has a hell of copper list (dynamic, synced, even a little illegal, full of tricks). To satisfy my need for perfection I did a complete (insane..) re-sourcing of the code. And from here i've fixed all BPLCON1 (OCS) illegal usage (distibuted in variuos code, tables, copper snippet..) that make all sort of glitches on AGA machines.. not even visible to an untrained eye. [Well, actually i've optimized MANY other thinghs (this is only a little fraction), but I do not even know if I will eventually get something finished out of it, as I often do..] Using BRDRBLNK would have solved only the 'edges' part of the video. And the 2nd possible (monster) AGA copper-list would've required a complete rewrite of the video routine. So changing H1 (on BPLCON1/DIWHIGH) it's to be considered only a side effect and with small impact on the whole process (and seem to work, I need a beta tester..) Always a pleasure that there is still someone who enjoys playing with these chipsets. Good job and fun! |
19 July 2018, 15:31 | #36 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,505
|
http://www.winuae.net/files/b/winuae.7z updated with experimental subpixel display emulation support.
- option in chipset panel - display panel resolution selects internally emulated resolution. - most speed optimization tricks are not implemented. - option also works in ocs/ecs modes (but does nothing visible, only slows down emulation, easier test case for me to confirm non-corrupted display) - 1 hires pixel AGA color delay is only emulated if subpixel emulation is enabled. Border blank feature was introduced in ECS Denise. (Which was part of new genlock features that probably no one used..) Last edited by Toni Wilen; 19 July 2018 at 20:13. |
19 July 2018, 18:56 | #37 | |
Code Kitten
Join Date: Aug 2015
Location: Montreal/Canadia
Age: 52
Posts: 1,178
|
Quote:
I have been harping for quite a while about how there is likely room for optimization in most commercial Amiga games because: they were built under time pressure, profiling and debugging tools were usually very primitive (especially compared with modern ones like VTune) and oftentimes teams included coders which were not necessarily super experienced. So I would be super interested in which kinds of avenues for optimization and rework you found in LionHeart. |
|
19 July 2018, 20:15 | #38 | |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
|
Quote:
Well, I've to make it working first, in this period I have very low rhythms Some unfinished changes: - optimized various generic code (too much to list), more pc-relative or base-relative code - changed memory manager (doesnt require anymore a patch that mess memory) - native support for whdload (yes, in main code!) - optimized some blitter routine (with faster blitter wait) and faster objects mirror routine - all the fix of the whdload version (and more..) - glitches free and full AGA support (see this thread) But do not expect significative performace change, this game is really a jewel in Amiga history (maybe less slowdown, which are indeed rare). Bye! |
|
20 July 2018, 00:59 | #39 |
Registered User
Join Date: Nov 2017
Location: Los Angeles
Posts: 49
|
I have discovered another interesting thing related to all this. On AGA the BRDRBLNK is applied a half pixel early on the left hand side on real hardware! Interestingly it is applied at the expected place on the right hand side.
I've attached an updated HalfPixelTest.exe. If you press and hold the right mouse button, the BRDRBLNK will be applied and you can see the third line is correctly cropped on the right, but is cropped a half pixel early on the left. Last edited by FSizzle; 20 July 2018 at 01:17. Reason: Updated HalfPixelTest.7z with source for reference |
20 July 2018, 01:05 | #40 | |
Registered User
Join Date: Nov 2017
Location: Los Angeles
Posts: 49
|
Quote:
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Alien Breed II title pixel by pixel logo removal | dex | project.Sprites | 17 | 06 May 2020 15:23 |
Needed: A1200 Delay Line & Bandpass Filter | PARALAX | support.Hardware | 0 | 04 December 2016 18:44 |
A1200 reset delay | Cobe | support.Hardware | 18 | 09 May 2016 18:31 |
Problem running copper master demo on A1200 | whitebird | support.Demos | 26 | 17 August 2014 17:41 |
Wanted - A1200 Tin Shield Bottom Half - NEW | Peter | MarketPlace | 0 | 15 September 2010 17:06 |
|
|