Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 23:34 24 Apr 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Any interest in MMBasic for Windows with full Graphics?

     Page 5 of 5    
Author Message
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 5712
Posted: 07:42pm 23 Jan 2022
Copy link to clipboard 
Print this post

Very nice, Peter. :)
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
LeoNicolas

Guru

Joined: 07/10/2020
Location: Canada
Posts: 444
Posted: 09:17pm 23 Jan 2022
Copy link to clipboard 
Print this post

Will it run on Linux?
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5898
Posted: 09:38pm 23 Jan 2022
Copy link to clipboard 
Print this post

  LeoNicolas said  Will it run on Linux?

As per the title, Peter is coding for Windows.

I assume that it might run under Wine etc.

Provided all the strange extensions being requested are left out and the code kept relatively 'normal', there is a chance the it may be possible to compile it for other platforms.

Jim
VK7JH
MMedit   MMBasic Help
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8575
Posted: 10:56pm 23 Jan 2022
Copy link to clipboard 
Print this post

More progress


 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3650
Posted: 09:00am 24 Jan 2022
Copy link to clipboard 
Print this post

  LeoNicolas said  Will it run on Linux?

Peter gave details of the cross-platform tool he's picked...

John
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 3507
Posted: 09:59am 24 Jan 2022
Copy link to clipboard 
Print this post

  matherp said  More progress



What did you do ?
The current 5.05.01 DOS version runs 123570 grains on a i9 (absolutely not the slowest machine). 3x more performance. WAUW...

Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8575
Posted: 10:04am 24 Jan 2022
Copy link to clipboard 
Print this post

  Quote  What did you do ?


As they say in the song "It's a kind of magic"  

Another performance data point - Solar Eclipse calculation

MM+ @ 100MHz 121.75 seconds
PicoMite @ 252 MHz 35 seconds
CMM2 7 seconds

MMB4W 0.4 seconds
Edited 2022-01-24 20:42 by matherp
 
flasherror
Senior Member

Joined: 07/01/2019
Location: United States
Posts: 159
Posted: 03:43pm 24 Jan 2022
Copy link to clipboard 
Print this post

What is the screen resolution? User configurable?
 
Tinine
Guru

Joined: 30/03/2016
Location: United Kingdom
Posts: 1646
Posted: 03:59pm 24 Jan 2022
Copy link to clipboard 
Print this post

Heck....Game changer for me....possibly.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8575
Posted: 04:42pm 24 Jan 2022
Copy link to clipboard 
Print this post

  Quote   What is the screen resolution? User configurable?

Will be - just got that working without even needing to restart
Can't decide whether to mimic CMM2 resolutions up to and including 1080p or to give complete flexibility. In all cases colour depth will be ARGB8888 and I think I'll set it up with two pages and transparency so you can do things like have a graph moving over a fixed grid.
 
flasherror
Senior Member

Joined: 07/01/2019
Location: United States
Posts: 159
Posted: 12:10am 25 Jan 2022
Copy link to clipboard 
Print this post

I wonder about the overhead of doing graphics at high resolution, especially with sprites. Also, since the interpreter is doing font stuff in software will there be a bottleneck somewhere? Maybe this will not be an issue since running on a PC looks much faster than any other MMBasic platform.
(after 2 minute read of olcPixelGameEngine wiki: interesting, "decals" are GPU accelerated sprites but with some restrictions - see https://github.com/OneLoneCoder/olcPixelGameEngine/wiki/TUTORIAL---Decals )
(after 5 minutes thinking): what about using decals as the font char primitives ("A", "B", "C" etc) to draw text to screen? If I understand it correctly decals have highest priority over the background (i.e. stuff drawn by CPU) so you can't use sprites etc on top of decals, but would be fast though. Hardware accelerated cursor LOL?
Edited 2022-01-25 10:29 by flasherror
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8575
Posted: 11:14am 25 Jan 2022
Copy link to clipboard 
Print this post

Coming together nicely

Graphics demo

Mode change is also now implemented, all CMM2 modes + completely free resolution

MODE n ' select a CMM2 mode but in full ARGB888
mode width%, height%, pixelsize% 'specify the width and height and the size of a MMBasic pixel in screen pixels

The latter syntax allows you to have a huge window but with say 320x240 resolution from MMbasic's perspective
 
flasherror
Senior Member

Joined: 07/01/2019
Location: United States
Posts: 159
Posted: 12:36pm 25 Jan 2022
Copy link to clipboard 
Print this post

Does it make sense to have an additional high precision timer other than the 1 mS base timer? Since PC is fast, using 1mS base timer to try to measure code execution time might not give the precision required (i.e. a lot of code could probably execute in 1mS?). On the other hand, if the speed is so fast maybe you wouldn't need to measure/optimize code execution a lot...
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 5712
Posted: 12:53pm 25 Jan 2022
Copy link to clipboard 
Print this post

Not bad at all, Peter. Do you think it might need speeding up a bit?
;)
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8575
Posted: 02:02pm 25 Jan 2022
Copy link to clipboard 
Print this post

  Quote  Do you think it might need speeding up a bit?


Yes, I haven't start tuning it yet
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 5712
Posted: 02:49pm 25 Jan 2022
Copy link to clipboard 
Print this post


Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
MauroXavier
Guru

Joined: 06/03/2016
Location: Brazil
Posts: 303
Posted: 04:29pm 25 Jan 2022
Copy link to clipboard 
Print this post

  matherp said  Coming together nicely

Graphics demo

Mode change is also now implemented, all CMM2 modes + completely free resolution

MODE n ' select a CMM2 mode but in full ARGB888
mode width%, height%, pixelsize% 'specify the width and height and the size of a MMBasic pixel in screen pixels

The latter syntax allows you to have a huge window but with say 320x240 resolution from MMbasic's perspective


Only waiting for this to be ready to port the Into The Darkness to a full 60 FPS raycast engine... Unfortunately, the CMM2 struggles to keep 15 FPS in this game thanks to my lack of ability to optimize it more.
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 3507
Posted: 06:30pm 25 Jan 2022
Copy link to clipboard 
Print this post

  matherp said  Coming together nicely

Graphics demo

Mode change is also now implemented, all CMM2 modes + completely free resolution

MODE n ' select a CMM2 mode but in full ARGB888
mode width%, height%, pixelsize% 'specify the width and height and the size of a MMBasic pixel in screen pixels

The latter syntax allows you to have a huge window but with say 320x240 resolution from MMbasic's perspective


Impressive demo....

I understand the choice for the mode command, but I hope there are additional options in the future. Most screens on PC's are 1920x1080 nowadays (16:9) and the CMM2 modes do not scale nicely on that resolution.

1024x768: no scaling, uses approc 1/3 of the screen
800x600: when scaling 2x, exceeds screen dimensions: no scaling possible 1/4'th of screen
640x480: scaling 2x => 1280x960, uses around 2/3 screen, that is not to bad
        scaling 3x => exceeds vertical size.

I hope some better matching video mode van be found. Otherwise 640x480 gives best result.

Volhout
PicomiteVGA PETSCII ROBOTS
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8575
Posted: 06:53pm 25 Jan 2022
Copy link to clipboard 
Print this post

Mode 16?
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 3507
Posted: 07:54am 26 Jan 2022
Copy link to clipboard 
Print this post

Yip

Mode 16 was not available on my Gen-1.
But Mode 12 with double pixels is just as fine. Matches exactly. Might have been designed for that ..;)

Volhout
PicomiteVGA PETSCII ROBOTS
 
     Page 5 of 5    
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024