English Amiga Board


Go Back   English Amiga Board > Requests > request.Apps

 
 
Thread Tools
Old 23 July 2019, 21:43   #1
Glen M
Registered User

 
Join Date: May 2017
Location: Belfast
Posts: 385
Simple colour changing program.

I was wondering if anyone knew of a simple program that would change say the colour of the screen instantly when pressing a button.

I want to time for input lag on an rgb to hdmi scaler I have.

I remember the 8 bit guy doing something similar on a c64 (I think he was testing the c64 mini against original) and wrote a small program to change colour.

Is there anything out there like this.
Glen M is offline  
Old 23 July 2019, 22:10   #2
Dan
Registered User
Dan's Avatar
 
Join Date: Nov 2004
Location: Germany
Posts: 434
It could be easily written, in amos pro.

How should the app behave ?
Change color on keyboard or on joystick, or on both ?

Should the color stay while the button is pressed ? Shall it change back at some time or by pressing specific key ?

On which amiga resolution should it run ?
Dan is offline  
Old 24 July 2019, 10:24   #3
Glen M
Registered User

 
Join Date: May 2017
Location: Belfast
Posts: 385
It would be cool if the app could change screen colour on press of a joystick button.

Just a full screen of colour on low res and when you press a button screen changes colour. If it makes it easier just change between 2 solid colours say red and blue.

So program loads full screen of red, press joystick button once and screen changes to blue, press again changes to red. Or a random colour generation would also work.

This will allow me to capture the screen footage at 50fps and see just how much input lag is generated by my HDMI scaler compared to say native composite out of the Amiga.
Glen M is offline  
Old 24 July 2019, 16:29   #4
Dan
Registered User
Dan's Avatar
 
Join Date: Nov 2004
Location: Germany
Posts: 434
Here it is, it is compiled as a cli-executable.

And this is the sourcecode for it:

Code:
Screen Open 0,320,240,16,Lowres
Flash Off : Curs Off 
Pen 0 : Paper 1
Palette $F00,$F
X=0 : Y=0

Cls 

Repeat 
Z=Fire(1)

   If Z=-1 and Y=0 : Rem test if Joystick button is pressed and make sure it is pressed only once 
      If X=0
         Rem Cls 1
         Palette $F,$F00
      Else If X=1
         Rem Cls 2
         Palette $F00,$F
      End If 
      Y=1 : X=(X+1) mod 2
   End If 

   If Z=0 : Rem Fire-Button is released, Allow the usage of the fire button
      Y=0
   End If 
Until Inkey$=" " : Rem Space key ends the program
Attached Files
File Type: 7z ColorChanging.7z (31.6 KB, 12 views)

Last edited by Dan; 24 July 2019 at 16:36.
Dan is offline  
Old 19 August 2019, 16:33   #5
Glen M
Registered User

 
Join Date: May 2017
Location: Belfast
Posts: 385
Quote:
Originally Posted by Dan View Post
Here it is, it is compiled as a cli-executable.
Just wanted to say a quick thank you to Dan for providing this. I was able to use it to test my cheap RGB to HDMI converter for lag and its producing approximately 2-3 frames of input lag which at 50FPS is nothing I can register anyway.
Glen M is offline  
 


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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Running simple C program Sim085 Coders. General 10 30 January 2018 13:43
External windows program communicating with program running inside WinUAE xxxxx support.WinUAE 10 19 February 2013 09:27
Simple weather program. Thorham Coders. General 1 04 September 2010 00:53
Changing the colour of the Workbench background NovaCoder support.Apps 15 08 February 2009 23:26
Calling another program from a compiled Amos program...? andyr support.Apps 3 24 October 2004 23:47

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 13:48.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.
Page generated in 0.06741 seconds with 15 queries