Jump to content

Photo

Stella 3.6 released


144 replies to this topic

#26 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Tue May 1, 2012 10:06 AM

The following is the code structure from the Blargg implementation I'm using, showing the different aspects that can (eventually) be tweaked. I don't know if I'll have all of them 'tweakable' for 3.7, since I'm not sure what some of them even mean. Don't worry if the code itself doesn't make sense; I think the comments should suffice.

typedef struct atari_ntsc_setup_t
{
  /* Basic parameters */
  double hue;	    /* -1 = -180 degrees	 +1 = +180 degrees */
  double saturation; /* -1 = grayscale (0.0)  +1 = oversaturated colors (2.0) */
  double contrast;   /* -1 = dark (0.5)	   +1 = light (1.5) */
  double brightness; /* -1 = dark (0.5)	   +1 = light (1.5) */
  double sharpness;  /* edge contrast enhancement/blurring */
  /* Advanced parameters */
  double gamma;	  /* -1 = dark (1.5)	   +1 = light (0.5) */
  double resolution; /* image resolution */
  double artifacts;  /* artifacts caused by color changes */
  double fringing;   /* color artifacts caused by brightness changes */
  double bleed;	  /* color bleed (color resolution reduction) */
  float const* decoder_matrix; /* optional RGB decoder matrix, 6 elements */
 
  /* You can replace the standard TI color generation with an RGB palette. */
  unsigned char const* palette;/* optional RGB palette in, 3 bytes per color */
  unsigned char* palette_out;  /* optional RGB palette out, 3 bytes per color */
  /* Atari change: additional setup fields */
  double burst_phase; /* Phase at which colorburst signal is turned on;
						 this defines colors of artifacts.
		    In radians; -1.0 = -180 degrees, 1.0 = +180 degrees */
  double* yiq_palette;
} atari_ntsc_setup_t;

The scanline stuff I still need to look into. But I think it's very easy to do, since all this stuff will require OpenGL, and creating a scanline pattern in OpenGL is extremely easy. And bilinear filtering is easy too; in fact, it's already in Stella, and named 'Linear'.

#27 Trebor OFFLINE  

Trebor

    River Patroller

  • 2,928 posts

Posted Tue May 1, 2012 10:34 AM

Awesome. Thanks for sharing the code details and the additional information.

Edited by Trebor, Tue May 1, 2012 10:34 AM.


#28 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Tue May 1, 2012 12:21 PM

looking great! - I can't wait

#29 israelg OFFLINE  

israelg

    Moonsweeper

  • 308 posts

Posted Wed May 2, 2012 6:55 AM

Looking much better now...!

Waiting for the release...

I am willing to be used as a tester if you need help...

I.G

#30 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Wed May 2, 2012 8:17 AM

Looking much better now...!

Waiting for the release...

I am willing to be used as a tester if you need help...

I.G


Let me know which system you need a build for (Windows 32/64, Linux 32/64, OSX). In the interests of time, I can only do one build for one platform.

#31 israelg OFFLINE  

israelg

    Moonsweeper

  • 308 posts

Posted Wed May 2, 2012 8:39 AM


Looking much better now...!

Waiting for the release...

I am willing to be used as a tester if you need help...

I.G


Let me know which system you need a build for (Windows 32/64, Linux 32/64, OSX). In the interests of time, I can only do one build for one platform.


Windows 64

Thanks,

I.G

#32 israelg OFFLINE  

israelg

    Moonsweeper

  • 308 posts

Posted Wed May 2, 2012 8:51 AM

I can connect my REAL Atari 2600 with a Sony CRT TV and make some side by side comparing with my computer & Stella using Blargg...

I have the CRT TV and my computer on the same room...

#33 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Mon May 7, 2012 3:33 PM

OK, here's the first releasable version of Stella with Blargg TV effects. Some quick notes about what doesn't work/isn't finished:
  • This isn't close to the final release, so there may be other things broken
  • Blargg 'custom' mode isn't actually customizable :)
  • There's no GUI whatsoever, so no knobs can be tweaked
  • The scanlines don't have interpolation
  • Phosphor mode doesn't work in TV modes
And now for what does work:
  • Alt-1 to Alt-6 set TV mode to off/composite/svideo/rgb/bad/custom (right now, custom is simply a copy of composite)
  • Alt-7 increases scanline intensity, and Shift-Alt-7 decreases it (currently 20% - 100%)
These effects require an OpenGL video card and supported drivers (see your video card manufacturer website for more info). I've tested on several Linux and OSX systems (real) and Windows (virtual), and things are working reasonably well. I don't know how it will perform on lower-end systems, and I'd be interested in any feedback you can provide. I recommend turning on GL v'sync in OpenGL modes anyway, but particularly for the TV effects (to eliminate 'tearing' in the images).

Finally, I'd hoped to get this released by May 15 (and I still may make that date), but I'd also like to fix problem 5 above, and that's probably going to take some more time.

Anyway, here's a build for Windows 32/64-bit.

#34 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Mon May 7, 2012 4:32 PM

This is looking great as expected :) - Thanks for making the test build available.....

I think there may be an issue when running with a zoom setting different than 2x - I get some weird artifacts that don't look like they belong, I'm guessing it might be using the 2x hardcoded somewhere by accident?

Edit: actually 4x zoom looks fine to, just 3x has the problem - let me know if you want screenshots

Edited by eshu, Mon May 7, 2012 4:33 PM.


#35 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Mon May 7, 2012 5:30 PM

Yes, provide snapshots indicating what doesn't look quite correct to you. Since this is all visual anyway, the only way to really describe it is with snapshots. Also, make sure to try windowed vs. fullscreen modes (toggle with Alt-Enter) and see if the problems you mention appear in one but not the other.

#36 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Mon May 7, 2012 6:02 PM

long005.bin_1.png

The effect is most pronounced on the left hand side about 2/3 down from the top of the screen. It only shows up when 3x is selected for zoom and effects all roms I've tested, and effects all options except filter off, in both windowed and full-screen mode.

#37 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Tue May 8, 2012 3:47 AM

long005.bin_1.png

The effect is most pronounced on the left hand side about 2/3 down from the top of the screen. It only shows up when 3x is selected for zoom and effects all roms I've tested, and effects all options except filter off, in both windowed and full-screen mode.


It would also be helpful if you could either provide this ROM, or we both do testing on some other agreed-upon ROM. Also, what type of video card do you have?

#38 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Tue May 8, 2012 3:58 AM

Here's the issue on a more standard ROM.

Chopper Command (1982) (Activision).png

My videocard is a Nvidia NVS 4200M

#39 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Tue May 8, 2012 4:04 AM

Try turning scanlines down as far as possible with Shift-Alt-7. Currently, the lowest it can go is 20%, but I'll do another build later this evening where it can be 0% (effectively turning off scanlines). If the problem starts to go away, then it's the scanline emulation, not the Blargg stuff (in Stella, these two things are done separately).

#40 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Tue May 8, 2012 4:15 AM

That last snapshot was at 20%, but the effect becomes much more pronounced if I turn scanlines up, so I think that's the culprit. Once again just have to say how awesome this is - can't wait for the final build of 3.7!

Scanlines at 100%:

Chopper Command (1982) (Activision)_1.png

Edit to add snapshot

Edited by eshu, Tue May 8, 2012 4:16 AM.


#41 israelg OFFLINE  

israelg

    Moonsweeper

  • 308 posts

Posted Tue May 8, 2012 7:30 AM

I am very happy with the visuals but I have vSync problem,

I turned the vSync on but I still have tearing problems in games like barnstorming...

Update: It was force off in my video card settings and after changing it to the application settings everything is OK...!

I hope will have the time this weekend and do some side by side comparing real CRT vs CRT simulation...

Thanks,

I.G

#42 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Tue May 8, 2012 8:11 AM

I'll try to find some time today or this evening to look into the scanlines issue. BTW, I also recommend setting GL aspect (NTSC) to 90 or so, which makes the pixels more square and hence more authentic.

#43 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Tue May 8, 2012 11:34 AM

I've realised PAL roms are differently effected - thought that might help you get to the bottom of the issue:

Chopper Command (SuperVision) (PAL).png

#44 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Tue May 8, 2012 1:54 PM

Unfortunately something has come up this evening, so I won't get to the scanline issue until tomorrow. However, here's a new test build with the following improvements:
  • the range for scanline intensity is now 0-100%. So pressing Shift-Alt-7 will lower intensity down to 0, which essentially makes the scanlines invisible
  • added scanline interpolation option, which can be toggled with Alt-8, and defaults to on (this allows blending of scanlines into the scene, making them less sharp and pronounced)
I'd like to confirm that the above graphical glitches are from the scanlines. Please test by turning scanline intensity to 0 and confirm if the issues disappear.

#45 eshu OFFLINE  

eshu

    Chopper Commander

  • 249 posts

Posted Tue May 8, 2012 2:15 PM

The issue didn't appear again until I disabled scanline interpolation - and disappears with intensity 0.

#46 PFL OFFLINE  

PFL

    Dragonstomper

  • 745 posts
  • Location:Advanced Tech and Research Institute

Posted Tue May 8, 2012 3:46 PM

Running the test build on my Dell Mini 9 with 32 bit Windows XP seems to work fine though it feels a little slower than the previous couple of releases. That may be a little psychological as I've been playing a lot on the real hardware of late so I'll continue playing around and let you know how I get on with a low end machine (Open GL 1.2). :)

#47 Keatah ONLINE  

Keatah

    Quadrunner

  • 8,073 posts

Posted Tue May 8, 2012 4:27 PM

I don't think this will work with openGL 1.2
It isn't working on 1.3, so...

#48 Keatah ONLINE  

Keatah

    Quadrunner

  • 8,073 posts

Posted Tue May 8, 2012 4:36 PM

I don't think this will work with openGL 1.2
It isn't working on 1.3, so...




My bad. So that's how you turn it on. Must read the instructions.
It is working with openGL 1.2

#49 stephena OFFLINE  

stephena

    River Patroller

  • Topic Starter
  • 2,539 posts
  • Stella maintainer
  • Location:Newfoundland, Canada

Posted Tue May 8, 2012 4:57 PM

This is designed to work with OpenGLES, which is many ways is simply OpenGL 1.3 or so. I don't really use many advanced OpenGL features, mostly just 2D texture scaling, filtering and blending. Also keep in mind that these extra features are going to be slower; there's no way around that. I would guess that it uses probably 30% more resources than before. So if the old release took 10% of your CPU, these new TV effects would probably push it to 13-14% or so.

I'll try to test on the slowest system I have and see the results (800Mhz VIA CPU on an embedded board). But I suspect that any system from the past 5 years should be able to handle this.

EDIT: Good news. I've been able to duplicate the scanline issues on my Macbook Pro, so that should make it much easier to fix the problem (it's always easier to fix something when I can personally see it happening).

#50 Keatah ONLINE  

Keatah

    Quadrunner

  • 8,073 posts

Posted Tue May 8, 2012 6:15 PM

I tested the speed on a 10 year old lappy with intel EXTREME graphics and a Dothan 1.7GHz cpu. It seems fine.

But, how do I view the FPS. According to the documentation I have to be in some sort of TIA mode? And use ALT + 1 ?? That doesn't work. Either that, or I don't know what TIA mode is..?




0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users