Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
16 user(s) are online (8 user(s) are browsing Forums)

Members: 0
Guests: 16

more...

Support us!

Headlines

 
  Register To Post  

PTDS (formerly PED81C) - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
PTDS (Pixel Tetrads Dots / Speed) is a video system for AGA Amigas that provides pseudo-native chunky screens, i.e. screens where each byte in CHIP RAM corresponds to a dot on the display - in other words, it offers chunky screens without chunky-to-planar conversion.

Download: https://www.retream.com/PTDS

Some examples:
* https://www.youtube.com/watch?v=0xunQ6ldVKU
* https://www.youtube.com/watch?v=4eikEo45v1I
* https://www.youtube.com/watch?v=eVzTIyg_MeE
* https://www.youtube.com/watch?v=ebxwKm9K4Os
* https://www.youtube.com/watch?v=tLtLhJXInOY
(Due to technical limitations, the video quality is lower than the actual one.)

For the details, please refer to the documentation included in the archive.


Edited by saimo on 2022/3/9 18:03:25
Edited by saimo on 2023/6/19 21:33:45
Edited by saimo on 2023/6/21 15:11:05
Edited by saimo on 2023/6/26 19:56:07
Edited by saimo on 2023/11/28 23:01:50
Edited by saimo on 2023/11/28 23:05:45
Edited by saimo on 2023/11/29 12:13:25
Edited by saimo on 2024/4/2 20:12:09
Edited by saimo on 2025/2/10 17:57:36
Edited by saimo on 2025/3/19 16:54:28
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Not too shy to talk
Not too shy to talk


See User information
Clever... is it sort of like subpixel font rendering to achieve the effect?

Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
@NinjaCyborg

I don't know how that works, so I can't answer. The best, most complete and shortest explanation I can give is the one in the CORE IDEA section of the documentation.

Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Just can't stay away
Just can't stay away


See User information
@NinjaCyborg

Quote:
Clever... is it sort of like subpixel font rendering to achieve the effect?
No. Visual results might be similar, but it's something completely different.
For subpixel font rendering you basically just quadruple or sixteenfold the resolution a B/W font is rendered to, then you scale the result down to the original resolution again but using grey scale colours (or matching alpha masks) instead of just B/W for the 2x2 or 4x4 pixels groups which have 1/4, 1/2, 3/4, or in case of sixteenfold rendering additionally 1/16, 2/16 ... 14/16, 15/16, black pixels.

Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Not too shy to talk
Not too shy to talk


See User information
@joerg no that's not sub pixel rendering that's what apple uses for retina display and such. sub pixel rendering anti aliases by splitting each full pixel into separate r g and b pixels and then setting boundary pixels to swatches that will blur the line between the white and the black.

Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Home away from home
Home away from home


See User information
@saimo

this is screaming for a kick arse horizontal shooter !

Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
@328gts

I guess you've been influenced by the video examples, but "native" chunky would be better used for other things (although, I did try to imagine if an interesting horizontal shooter could be done). To be honest, I feared I'd get a flock of Doom-like game requests/proposals :D


@all

Improved/corrected documentation.

Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
Uploaded an archive with updated documentation.
While at it, given that I was asked for a source code example, I whipped up an AMOS Professional program that shows how to set up a PTDS screen and to perform some basic operations on it - hopefully, this will be easy to understand and also open the door to AMOS programmers. The program source is included in the archive.


Edited by saimo on 2023/11/28 23:02:09
Edited by saimo on 2023/11/29 12:13:47
Edited by saimo on 2025/3/19 16:54:59
Edited by saimo on 2025/3/19 16:55:20
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
Really impressive.
Should be a definitive + to Amos Professional as an extension

All we have to decide is what to do with the time that is given to us.
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
@AmiDARK
Quote:
AmiDARK wrote:Really impressive.

Thanks!

Quote:
Should be a definitive + to Amos Professional as an extension

I wrote the example in AMOS to make it easier to understand by more people, but the system isn't intended for any specific language.
I decided to let programmers implement PTDS in the way that fits best their projects and in their language of choice, given that setting up PTDS screens is easy and given that general-purpose routines would perform worse than tailor-made ones.


Edited by saimo on 2025/3/19 16:55:43
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
@Saime :
I did never said that it should be "Amos Only" system ;)
But simply that it may be interesting to add support for it using extension format. The support should handle screen setup. User will create his/her own custom methods for required effects.

I must admit that I read doc and didn't understand how it works but I'll do another check and if I find time, I will maybe look to see if I can do something interesting with it using extension format.

EDIT :
From doc I read this :
RGBW
does this mean it is a 32 bit value ? Because after you talk about $ww using $wwwwww ..
I don't understand.
Ew... I think I understand you talk about RGB value for the ColorXX register used for the 4th pixel ? Same for others pixels. Right ?


Edited by AmiDARK on 2023/8/1 19:27:43
Edited by AmiDARK on 2023/8/1 19:29:31
Edited by AmiDARK on 2023/8/1 19:41:10
All we have to decide is what to do with the time that is given to us.
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
@AmiDARK
Quote:
I must admit that I read doc and didn't understand how it works but I'll do another check and if I find time, I will maybe look to see if I can do something interesting with it using extension format.

EDIT :
From doc I read this :
RGBW
does this mean it is a 32 bit value ? Because after you talk about $ww using $wwwwww ..
I don't understand.
Ew... I think I understand you talk about RGB value for the ColorXX register used for the 4th pixel ? Same for others pixels. Right ?

Key concepts:
* each dot is 8 bit;
* each dot is made of 4 SHRES pixels;
* each SHRES pixel is 2 bit (i.e. it can be assigned 4 different RGB values);
* the RGB values assigned to the SHRES pixels are 24 bit and can be chosen freely.

$wwwwww is a placeholder for any 24 bit value assigned to the W(hite) SHRES pixels in the RGBW mode (e.g. $333333 or $eeeeee).

I hope this helps.

RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
I have just released a little update, accompanied by the PTDS Voxel Engine (PVE), i.e. a new demo. If you can't be bothered trying it yourself, you can see it in this video - but beware: YouTube's video compression degraded the visual quality (especially the colors saturation and brightness).





About the update, I fixed some palette values in a table in the documentation, added the formulas for calculating DIWSTRT, DIWSTOP, DIWHIGH, DDFSTRT and DDFSTOP to the documentation and implemented them in the AMOS Professional source code example. This is the snippet relative to the register settings:
In generalgiven a raster which is RASTERWIDTH dots wide and RASTERHEIGHT dots
tall
the values to write to the chipset registers in order to create a centered
screen can be calculated 
as follows:
 * 
SCREENWIDTH  RASTERWIDTH 8
 
SCREENHEIGHT RASTERHEIGHT
 
DIWSTRTX     = $81 + (160 SCREENWIDTH 8)
 * 
DIWSTRTY     = $2c + (128 SCREENHEIGHT 2)
 * 
DIWSTRT      = ((DIWSTRTY $ff) << 8) | ((DIWSTRTX 1) & $ff)
 * 
DIWSTOPX     DIWSTRTX SCREENWIDTH 4
 
DIWSTOPY     DIWSTRTY SCREENHEIGHT
 
DIWSTOP      = ((DIWSTOPY $ff) << 8) | (DIWSTOPX $ff)
 * 
DIWHIGH      = ((DIWSTOPX & $100) << 5) | (DIWSTOPY & $700) |
                  ((
DIWSTRTX & $100) >> 3) | (DIWSTRTY >> 8)
 * 
DDFSTRT      = (DIWSTRTX 17) / 2
 
DDFSTOP      DDFSTRT+SCREENWIDTH 8


Edited by saimo on 2025/3/19 16:56:39
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
Just released a new version of PVE. Full changelog below. In short: it's faster and it's got a few little additions.

https://retream.itch.io/ptds

v1.1 (22.12.2023)
* Reworked screen buffering, so that the raster data is more efficiently written to CHIP RAM when bitplanes DMA is inactive.
* Improved 68030 caches handling.
* Added 68040 and 68060 caches handling.
* Added MMU handling to avoid that the MMU affects the speed negatively.
* Optimized rendering core by making it write the dots sequentially.
* Made a little 68060-specific code optimization.
* Ensured 68060 susperscalar dispatch is enabled.
* Added live-toggable staggered lines video filter, which helps see better colors on devices that do not support SHRES and reduces the jailbars effect on devices that support SHRES (to enable/disable: [F1]).
* Made fps indicator live-togglable (to enable/disable: [F2]).
* Made quitting from the voxel screen return to the splash screen.
* Replaced mouse controls with keyboard controls.
* Added benchmark function.
* Added command line switches to control the CPU caches.
* Fixed bug that caused a longword to be written to a random location when the fps indicator was on.
* Fixed an innocuous initialization bug.
* Made cleanup code more robust.
* Updated, extended and fixed documentation.


Edited by saimo on 2025/3/19 16:57:03
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
It was ages that I intended to dig up some 20+ years old code and use it to play with PTDS a little more. Finally I got around to do it and came up with a new test program called Zoomaniac.
Details in the video and in the manual excerpt below. Download available at https://retream.itch.io/ptds.





CHANGELOG

March 27, 2024
* Added the Zoomaniac demo.
* [PTDS Voxel Engine] Made a couple of minor changes.
* [PTDS Voxel Engine] Updated documentation.

January 1, 2024
* Rebuilt demos against latest custom framework.
* [PTDS Voxel Engine] Optimized slightly background rendering.
* [PTDS Voxel Engine] Corrected benchmark fps calculation (312 rasterlines were considered instead of 313).
* [PTDS Voxel Engine] Built against latest custom framework.
* [PTDS Voxel Engine] Updated, extended and fixed documentation.


Edited by saimo on 2024/3/29 13:51:16
Edited by saimo on 2025/3/19 16:57:47
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
In response to the feedback received, I have uploaded a new version of Zoomaniac that allows to enable/disable the fps limit by means of [F3].

The number shown in the top-left corner of the effects screen is the fps
  indicator
which reports the number of frames rendered in the last second.
  
It is limited to 999.
When the fps limit is onthe maximum number of frames rendered per second
  is 50 also on the most powerful machines
, as the display refresh rate is 50
  Hz
When the fps limit is offframes are rendered without pausing when the
  previously rendered frame
/frames has/have not (completelydisplayed yetOn
  machines which cannot run the program at 50 fps 
or moreturning off the
  limit has no effect whasoever
on the other machinesthe only visible effect
  is that the fps indicator goes beyond 50
thus giving a measure of the maximum
  speed that the machine can reach
.


Also, this new version runs 1-2 fps faster on 68030 thanks to the data cache burst:

on 68030 tests proved thatit is advantageous to turn the data cache burst
   on when scaling a 128 dots wide rectangle to a rectangle wider than 8 dots
   
(i.ewith an X scaling factor greater than 1/16); with a scaling factor of
   1
/16 or less the difference proved to be minimal when both the source and
   
destination rectangles were 256 dots tallconsidering that turning the data
   cache burst off would therefore be advantageous only with very narrow 
and
   
tall rectangles (which are uncommon and intrinsically rather inexpensive),
   
it is not worth it to implement a data cache burst management inside the
   scaling routine
;


CHANGELOG

v1.1 (28.3.2024)
* Turned the 68030 data cache burst on for slightly faster performance.
* Made a couple of minor optimizations.
* Added frames rendering limit toggle ([F3]).
* Worked on fps indicator: added hundreds digit; made digits smaller; made digits auto-clearing, so that they read correctly also when they are not cleared before drawing.
* Made staggered lines toggle as soon as [F1] is pressed (instead of when it is released).
* Updated splash screen.
* Redesigned the 'M' in the logo.
* Updated and extended manual.

RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
To have a complete set of scaling routines (which hopefully I'll use for something someday), I added support for color-keying, zero-keying (color-keying with color 0), and horizontal and vertical flipping.
Morever, given that initially the focus was on the stock A1200, the performance on expanded machines was not optimal (as the rendering was done directly in CHIP RAM), so I added also an alternative buffering method that, when 2 rasters can be allocated in FAST RAM, allows rendering in FAST RAM and then copies the rendered raster to the raster in CHIP RAM as quickly as possible, starting when the beam reaches the bottom of the screen. This, relatively to the first effect in the test program (which is the only one whose performance was measured until now), produced a gain of 8-9 fps on my 68030-equipped Amiga 1200.

The updated test program (available at https://retream.itch.io/ptds), to demostrate the new features, streches and shrinks a color/zero-keyed texture covering almost the entire screen over a full-screen zooming background, with all the possible flipping combinations. That is of course a bit taxing for a stock A1200, whose performance drops between 12 and 16 fps in the busiest cases.





(Side note: the video was recorded before finalizing the test program, so it shows an outdated splash screen and zooming jumps relatively to the background when passing from/to the color/zero-keying effects.)


Edited by saimo on 2025/3/19 16:58:47
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
By chance I discovered that Zoomaniac might crash on my real A1200. After some investigation it turned out that it was due to a stack issue that happened when the execution dropped below 50 fps on 68020, 68030 and 68040 (an instruction was executed before instead of after a branch). That's fixed now.
While searching for the problem, I realized a way to make the solid scaling routine a bit faster - so the bug, although finding it required some effort, was actually a good thing!

The new download is available on the PTDS page: https://www.retream.com/PTDS


Edited by saimo on 2025/3/19 16:59:19
RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top
Re: PED81C - pseudo-native, no C2P chunky screens for AGA
Just popping in
Just popping in


See User information
Wow, this is pretty cool, I hadn't seen this before. Very neat.

Go to top
Re: PTDS (formerly PED81C) - pseudo-native, no C2P chunky screens for AGA
Quite a regular
Quite a regular


See User information
@cloverskull

Thanks!


@all

More experimenting with PTDS. This is a proof of concept. It is just the core of a graphics engine for various vague game ideas (that are not going to materialize). It was useful to evaluate the visual quality and the speed (around 20 fps on a stock Amiga 1200, constantly much above 50 fps on an Amiga 1200 with Blizzard 1230 IV, 68030 @ 50 MHz and 60 ns RAM).





https://www.retream.com/PTDS

Notes:
* the video quality is affected by the fact that: the scandoubler did not support SHRES (so a real-time software trick was used to somehow produce the colors, although it is only a visual illusion and causes a sort of rasterline effect); the monitor did not support progressive PAL; the video was shot with an ancient phone at just 24.917 Hz; YouTube's compression degraded the video quality further;
* graphics are just placeholders;
* the city skyline has been derived from the picture at https://www.pinterest.com/pin/some-oth ... line--327988785356024774/

RETREAM - retro dreams for Amiga, Commodore 64 and PC
Go to top

  Register To Post

 




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




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project