Jump to content

Photo

Altirra 3.10 released

altirra emulation

410 replies to this topic

#301 MrFish ONLINE  

MrFish

  • 5,364 posts

Posted Fri Dec 28, 2018 8:20 AM

http://www.virtualdu...3.20-test10.zip

http://www.virtualdu...-test10-src.zip

 

Initial support for hardware accelerated screen effects:

 

attachicon.giffake-tv.jpg

 

Very nice. I've been hoping for options like these to appear for some time now.

 

Altirra is really offering a great array of display controls.

 

One thing that might be useful to add in the future, given so many display options,

is some sort of display profile saving.


Edited by MrFish, Fri Dec 28, 2018 8:24 AM.


#302 Mclaneinc ONLINE  

Mclaneinc

    Retro Madman

  • 6,364 posts
  • Location:Northolt, UK

Posted Fri Dec 28, 2018 8:55 AM

I'm pretty sure that's covered with one of the choices in the profile maker.....Possibly the environment one, not sure if it currently saves the new items, not tested as yet..   No, not saved .....as yet?

 

Also mixed up the colour and environment there, things like if you use artifacting get saved in that category..


Edited by Mclaneinc, Fri Dec 28, 2018 9:02 AM.


#303 MrFish ONLINE  

MrFish

  • 5,364 posts

Posted Fri Dec 28, 2018 10:18 AM

http://www.virtualdu...3.20-test10.zip

http://www.virtualdu...-test10-src.zip

 

Initial support for hardware accelerated screen effects:

 

attachicon.giffake-tv.jpg

 

This is an early version, so there are still some bugs, but these are the changes:

 

BTW, how feasible would it be to add the ability to tweak the different facets of high-artifacting mode?

I like it much better than standard artifacting, but it's just a bit strong in some of it's effects.



#304 phaeron OFFLINE  

phaeron

    River Patroller

  • Topic Starter
  • 2,674 posts
  • Location:Bay Area, CA, USA

Posted Fri Dec 28, 2018 3:01 PM

Avery, with the addition of the effects in a big way would it be a pain to move the effect load tab out of Tools / Options and maybe have it in View?

 

Just seems so out of place now these things are more in action..

 

It's not a commonly used item, so no on moving it to the top-level View menu. It might move to Configure System as I consolidate, since the division between that and Options is now weird.

 

Not sure about the future of the custom display effects, since it's underused and right now DX9 only. Shader compatibility with other software is very difficult due to how hard it is to accommodate shader language differences and the majority of shaders being built in GLSL. The internal shader effects are written completely differently than the way that the external custom effects are written.

 

I'm pretty sure that's covered with one of the choices in the profile maker.....Possibly the environment one, not sure if it currently saves the new items, not tested as yet..   No, not saved .....as yet?

 

Also mixed up the colour and environment there, things like if you use artifacting get saved in that category..

 

They are saved under View.

 

BTW, how feasible would it be to add the ability to tweak the different facets of high-artifacting mode?

I like it much better than standard artifacting, but it's just a bit strong in some of it's effects.

 

The algorithm has some internal knobs, but they're finicky and not very intuitive. For instance, the sharpness of the luminance filter also affects artifact hue due to phase shift effects.

 

It depends on what kind of adjustment you're looking for. The filter doesn't work by adding artifacts, it works by actually forming a composite signal and doing luma/chroma separation. This means that it is not accommodating of "cheats", like if you want an unrealistically sharp luma output while still having artifacting -- it'll start giving you jailbars like on actual hardware.



#305 Mclaneinc ONLINE  

Mclaneinc

    Retro Madman

  • 6,364 posts
  • Location:Northolt, UK

Posted Fri Dec 28, 2018 4:13 PM

Cheers Avery...



#306 Keatah OFFLINE  

Keatah

    Missile Commander

  • 21,848 posts

Posted Fri Dec 28, 2018 5:40 PM

Minor usability/feature req: Display the name of the current palette somewhere in the "adjust color" menu, or perhaps a simple checkmark in the palette dropdown. And if any sliders are moved away from default, indicate "custom". Maybe even put a tick-mark by the sliders indicating default position for the specified palette.



#307 MrFish ONLINE  

MrFish

  • 5,364 posts

Posted Fri Dec 28, 2018 5:49 PM

They are saved under View.

 

Great.

 

 

The algorithm has some internal knobs, but they're finicky and not very intuitive. For instance, the sharpness of the luminance filter also affects artifact hue due to phase shift effects.

 

It depends on what kind of adjustment you're looking for. The filter doesn't work by adding artifacts, it works by actually forming a composite signal and doing luma/chroma separation. This means that it is not accommodating of "cheats", like if you want an unrealistically sharp luma output while still having artifacting -- it'll start giving you jailbars like on actual hardware.

 

Overall, the high artifacting mode for NTSC is really nice. It's producing a lot of what is typically seen on a real set.

Really, I'm just looking to clean up the signal a bit, in order to get something a little closer to what I'm seeing on the

hardware I have -- and some hardware I've had in the past. Maybe an unrealistic idea, though, in the case of trying 

to modify the parameters available in the algorithm.



#308 mono OFFLINE  

mono

    Chopper Commander

  • 102 posts

Posted Sat Dec 29, 2018 6:00 PM

Altirra 3.20-test10 65C816 @ 3MHz configured. Following code

sync1 LDA VCOUNT  ;$D40B
sync2 CMP VCOUNT
      BEQ sync2
      BCC sync1

loops to infinity. It works correctly for all CPU configurations except of this one.

 

Edit: C flag isn't set when A=$9B and VCOUNT is $00.


Edited by mono, Sat Dec 29, 2018 6:03 PM.


#309 mono OFFLINE  

mono

    Chopper Commander

  • 102 posts

Posted Sat Dec 29, 2018 7:55 PM

Altirra 3.20-test10 65C816 @ 3MHz configured. Following code

sync1 LDA VCOUNT  ;$D40B
sync2 CMP VCOUNT
      BEQ sync2
      BCC sync1

loops to infinity. It works correctly for all CPU configurations except of this one.

 

Edit: C flag isn't set when A=$9B and VCOUNT is $00.

 

Is it possible that VCOUNT has value $9C on CMP, but $00 later on LDA?

Simius has described any time ago that it's possible for few cycles.

Lazy translation:

I've done one thing more. I've added one instruction:

loop: LDA VCOUNT
      LDX VCOUNT  ;added instruction
      CMP #$9C
      BNE loop
      RTS

As I thought, X always returns 0. That means 156 appears for the time shorter that 4 clock cycles.

I forgot to mention I have PAL configured during my tests.

 

Edit: Second comparation before BCC fixes the issue.

sync1 LDA VCOUNT ;$D40B
sync2 CMP VCOUNT
      BEQ sync2
      CMP VCOUNT
      BCC sync1

I apologise for unnecessary alarm.


Edited by mono, Sat Dec 29, 2018 8:17 PM.


#310 phaeron OFFLINE  

phaeron

    River Patroller

  • Topic Starter
  • 2,674 posts
  • Location:Bay Area, CA, USA

Posted Sun Dec 30, 2018 1:11 AM

 

Is it possible that VCOUNT has value $9C on CMP, but $00 later on LDA?

Simius has described any time ago that it's possible for few cycles.

Lazy translation:

I forgot to mention I have PAL configured during my tests.

 

Yes, there is a one-machine cycle glitch in VCOUNT before it rolls over to $00, yes. What is probably happening is that your frame timing is causing this to just happen consistently on 3.58MHz (2x). The root of the problem is resetting the baseline by jumping back to the LDA VCOUNT, which introduces a race condition. The revised code should work, but if what you're trying to detect is the rollover, you could poll for the sign change:

sync1   bit vcount
        bpl sync1
sync2   bit vcount
        bmi sync2


#311 mono OFFLINE  

mono

    Chopper Commander

  • 102 posts

Posted Sun Dec 30, 2018 8:19 AM

Yes, there is a one-machine cycle glitch in VCOUNT before it rolls over to $00, yes. What is probably happening is that your frame timing is causing this to just happen consistently on 3.58MHz (2x). The root of the problem is resetting the baseline by jumping back to the LDA VCOUNT, which introduces a race condition. The revised code should work, but if what you're trying to detect is the rollover, you could poll for the sign change:

sync1   bit vcount
        bpl sync1
sync2   bit vcount
        bmi sync2

Hah, KISS. Your method is simpler and much better - thanks a lot. I've changed only BIT to LDA in sync2 for my purposes.



#312 Mclaneinc ONLINE  

Mclaneinc

    Retro Madman

  • 6,364 posts
  • Location:Northolt, UK

Posted Sun Dec 30, 2018 8:39 AM

He knows his stuff you know...Always makes me smile when he dives in and does the full on tech stuff that fixes 99.9% of stuff as if its totally nothing while others have been sweating a little about it...

 

Always nice to know he's on the case with helping folks as well as updating and improving Altirra....



#313 phaeron OFFLINE  

phaeron

    River Patroller

  • Topic Starter
  • 2,674 posts
  • Location:Bay Area, CA, USA

Posted Thu Jan 3, 2019 11:23 PM

http://www.virtualdu...3.20-test11.zip

http://www.virtualdu...-test11-src.zip

  • Accelerated screen effects are now implemented for Direct3D 9.
  • Some work to reduce border artifacts with some of the accelerated effects.
  • Fixed quarter-line offset when using distortion and accelerated scanlines together.
  • Fixed stripes appearing in NTSC standard artifacting due to output correction being run twice on some of the scanlines.
  • Fixed debugger deferring symbol loads even after being opened because it didn't auto-switch to the 'when enabled' setting properly.

The baseline requirement for accelerated effects is now any shader model 2+ capable graphics card, though performance may vary. The heaviest effect is the distortion effect (fishbowl), which on my ancient Intel 865 raises system load up by about 40%. Any reasonably modern graphics card shouldn't have a problem, though.



#314 Mclaneinc ONLINE  

Mclaneinc

    Retro Madman

  • 6,364 posts
  • Location:Northolt, UK

Posted Fri Jan 4, 2019 11:17 AM

Anyone got a good selection of shaders they have used on Altirra?

 

I've tried loads but there's almost always a parsing error in the most tiny writing I've seen :)

 

Just interested to see how they look but its more to have a play with this newish feature... :)

 

I've looked at the Vintage TV one just a little too much :)



#315 baktra ONLINE  

baktra

    Dragonstomper

  • 598 posts
  • Location:Czech republic

Posted Fri Jan 4, 2019 11:42 AM

The horizontal and vertical distortion settings in the View/Adjust Screen Effects Dialog are a nice touch.

I remember these box-art images with "screen shots" using the same distortion to feel more like TV screen. Now one can press Print Screen and use distorted view for screen shots.

Not that GFX editors couldn't do the same, of course.



#316 JAC! OFFLINE  

JAC!

    Stargunner

  • 1,811 posts
  • Always looking for GFX and MSX for my demos
  • Location:Lebach, Germany

Posted Sat Jan 5, 2019 9:33 AM

I find it really kind of funny that for 40 years we have been trying to improve the video output quality of the original machine with SCART, S-Video MODs, UAV, VBXE and in parallel we a trying to make the emulation output as "bad" as our childhood memories look like ;-)



#317 VladR OFFLINE  

VladR

    Stargunner

  • 1,564 posts
  • Location:Montana

Posted Sat Jan 5, 2019 10:05 AM

I find it really kind of funny that for 40 years we have been trying to improve the video output quality of the original machine with SCART, S-Video MODs, UAV, VBXE and in parallel we a trying to make the emulation output as "bad" as our childhood memories look like ;-)

NostalgiaBW.gif



#318 snicklin OFFLINE  

snicklin

    River Patroller

  • 2,191 posts
  • Location:Australia

Posted Sat Jan 5, 2019 10:20 AM

I find it really kind of funny that for 40 years we have been trying to improve the video output quality of the original machine with SCART, S-Video MODs, UAV, VBXE and in parallel we a trying to make the emulation output as "bad" as our childhood memories look like ;-)

 

I remember my TV that I used with my Atari used to get distorted whenever the bathroom light was switched on or off.

 

Avery, is this next on your list to emulate? :)



#319 Heaven/TQA OFFLINE  

Heaven/TQA

    Quadrunner

  • 11,163 posts
  • Location:Baden-Württemberg, Germany

Posted Sat Jan 5, 2019 12:06 PM

Haha

#320 baktra ONLINE  

baktra

    Dragonstomper

  • 598 posts
  • Location:Czech republic

Posted Sat Jan 5, 2019 1:01 PM

Power supply emulation is the next step.

But seriously, effects of the old TV can be considered a trinquet, however as a developer relying heavily on emulation, I can test if my software will look acceptably on those old TVs that I don't have but some users do.

#321 flashjazzcat ONLINE  

flashjazzcat

    Quadrunner

  • 14,325 posts
  • Location:United Kingdom

Posted Sat Jan 5, 2019 1:04 PM

Dead MT DRAM emulation would be interesting. :)

#322 atx4us OFFLINE  

atx4us

    Moonsweeper

  • 437 posts
  • Location:Michigan, USA

Posted Sat Jan 5, 2019 3:48 PM

 

I remember my TV that I used with my Atari used to get distorted whenever the bathroom light was switched on or off.

 

Avery, is this next on your list to emulate? :)

Happy New Year to everyone!

And don't think that he won't.  He'll do it just for kicks and a last laugh :)

Avery does have a very good sense of humor.



#323 Nezgar ONLINE  

Nezgar

    Stargunner

  • 1,577 posts
  • Location:Regina SK Canada

Posted Sat Jan 5, 2019 4:27 PM

Please don't add weak RF signal noise emulation... or the startling white snow/noise when turning the computer off/on

;-)

#324 phaeron OFFLINE  

phaeron

    River Patroller

  • Topic Starter
  • 2,674 posts
  • Location:Bay Area, CA, USA

Posted Sat Jan 5, 2019 4:32 PM

 

I remember my TV that I used with my Atari used to get distorted whenever the bathroom light was switched on or off.

 

Avery, is this next on your list to emulate? :)

 

Never had that problem. Mixer in the kitchen, on the other hand, gave a nice light show....

 

Modern equipment can produce a cleaner display but it isn't always better. Different colors and lack of artifacting means that games don't really look the same as they're meant to. Displaying NTSC output with square pixels or worse stretching to widescreen is awful. Where this gets really bad is when people think this is the way the original computer was, and then begin writing code that looks or runs incorrectly on the original hardware. Gotta put a stop to that.

 

Originally there was the excuse that host computers weren't up to accurate emulation, but that's less of an excuse now (though there are still constrained platforms like the RPi). Emulating the way that old computers and CRT displays rendered is actually rather complex, which is why I'm annoyed when programmers going for a retro look think that retro just means point sampling (which just looks like garbage, not retro):

 

ugh.png

 

As for what I plan to do, well, first priority is to stabilize the new stuff, make sure it works nicely with other features like light pen emulation and get good defaults in place. I'm probably going to do some work on the color settings as it's clear that some people are still stuck on old Altirra color presets and need a nudge to get updated to the new ones. Refresh bars and the luma 7/8 gap are two things I might look more into as they were kind of notorious XE artifacts that you still only see on the actual hardware.



#325 R0ger OFFLINE  

R0ger

    Moonsweeper

  • 374 posts
  • Location:Olomouc, Czech Republic

Posted Sat Jan 5, 2019 11:03 PM

Wow, the new effects are amazing. The bloom especially. With scanlines on, lowest possible intensity, and some 1clk bloom the output has that nice round blobby pixels I so love on CRTs. 







Also tagged with one or more of these keywords: altirra, emulation

1 user(s) are browsing this forum

0 members, 1 guests, 0 anonymous users