Re: [hatari-devel] TT emulation

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Hi,

On keskiviikko 11 heinäkuu 2012, Konador, Cyprian wrote:
> Attached you can find the TT emulation patch for Hatari 1.6.2.
> It contains following part:
> 
> -          Extend the ST palette registers ($ffff8240) from 9bit to 12bit
> for ST modes ($ffff8260);
> 
> -          Duochrome mode instead monochrome for ST High;
> 
> -          Implementation of TT SampleHold i TT Hypermono video mode;

In general it looks OK to me.  Here are couple of quick comments:

* bTTSampleHold is used in Videl drawing code, but it doesn't seem to
  be zeroed if user switches to Falcon emulation (which also uses videl
  code).  This the only real issue.

* Only bTTSampleHold seems need to be global, i.e. it seems that
  bTThypermono should be static...

* rest of videl.c code uses different brace ('{}') positioning convention[1]
  than your patch.

[1] Different files in Hatari sources use different  conventions depending
    on their originating project and who has written / maintains them.


> In additional, I attached test application for SampleHold and TT
> Hypermono mode.

That seems to work.  Are there any other demos using these modes?

There are actually already several other TT demos (from tscc) that don't
work properly in Hatari (as documented in compatibility list), for example:
* http://pouet.net/prod.php?which=52339
* http://pouet.net/prod.php?which=16426

 
> Please let me know if that path is ok for you.
>
> In meantime I found out that my code in file video.c (in function
> Video_UpdateTTPalette) can be a bit optimized:
> 
> ttcolor = ((stcolor&0x777) << 1) | ((stcolor&0x888) >> 3);
> 
> instead of:
> 
> ttcolor = ((stcolor&0x700) << 1) | ((stcolor&0x70) << 1) | ((stcolor&0x7)
> << 1)
> 
> | ((stcolor&0x800) >> 3) | ((stcolor&0x80) >> 3) | ((stcolor&0x8) >> 3);


	- Eero



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/