Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
100 user(s) are online (96 user(s) are browsing Forums)

Members: 1
Guests: 99

skynet, more...

Support us!

Headlines

 
  Register To Post  

(1) 2 »
Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@All
Have anyone some example code of how to disable/enable screenblanker engine globaly on os4 ? Want to do so for mplayer while video is playing, to avoid blankers interrupt it, i.e. same as on all normal oses all video players do.

If no ready to use code, then at least some inputs about logic will be welcome as well


Edited by kas1e on 2014/4/4 15:36:59
Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Just can't stay away
Just can't stay away


See User information

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Not too shy to talk
Not too shy to talk


See User information
That would be very nice feature.

@kas1e

"same as on all normal oses all video players do"

Not tried on windows for past 10 years or so, but at least during the past few years Linux players have failed to do that (perhaps some player handle it, some do not, not verified recently, I have just set the screenblanker time long enough).

It's silly how it does not work with windows presentation apps. Allways presentations are stopped because screenblanker activating in the middle of presentations (ppt/pdf).

- Kimmo
--------------------------PowerPC-Advantage------------------------
"PowerPC Operating Systems can use a microkernel architecture with all it�s advantages yet without the cost of slow context switches." - N. Blachford
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Amigans Defender
Amigans Defender


See User information
@KimmoK

Quote:
That would be very nice feature.


It already exists.

Quote:
It's silly how it does not work with windows presentation apps. Allways presentations are stopped because screenblanker activating in the middle of presentations (ppt/pdf).


Windows is a bit finicky as to what it deems "user input". Certainly joysticks are not sufficient to keep the screenblanker at bay.

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@jabirulo
Right ! So as it about using of application library. And then maybe adding of ringio support also will be good idea if i anyway should register app.. But where and when then ? When movie/sound starts/end ?

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@kas1e

Quote:
@jabirulo
Right ! So as it about using of application library. And then maybe adding of ringio support also will be good idea if i anyway should register app.. But where and when then ? When movie/sound starts/end ?


IMHO, the best option would be to disable the screenblanker while a movie is playing, and enable it again at all other times, including when a movie is paused.

Hans

Join Kea Campus' Amiga Corner and support Amiga content creation
https://keasigmadelta.com/ - see more of my work
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@Hans
Yep,that how it done already by Fab in muimplayer (i.e. all calling of enable/disable functions are placed where need it already). All i need it put there aos4 parts and all will works fine.

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Just can't stay away
Just can't stay away


See User information
@kas1e
There's some programming baggage with application.library unless your program is already using it. Here's the simple solution:

/* Turns off the screen blanker */
/* gcc blank.c -o blank -lauto */

#include <proto/commodities.h>

int main(int argc, char**argv)
{
int32 result = 0;

result = ICommodities->BrokerCommand("ScreenBlankerEngine", CXCMD_DISABLE);
}

However, that only works with the OS4 screenblanker. If there are other screenblankers in use that don't use screenblanker.library, you will need to find out how to disable those.



Edited by xenic on 2014/4/5 19:01:44
Amiga X1000 with 2GB memory & OS 4.1FE + Radeon HD 5450

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@xenic

Quote:

There's some programming baggage with application.library unless your program is already using it.


As i read in Trixie‘s tutor about application library, all i need it just open it and register my app to have appid, and then can do what i need.

Quote:

However, that only works with the OS4 screenblanker. If there are other screenblankers in use that don't use screenblanker.library, you will need to find out how to disable those.


Is on os4 possible to have screenblankers which didn't use screenblanker.library ? i mean imho they all use it ?


Edited by kas1e on 2014/4/6 7:21:24
Edited by kas1e on 2014/4/6 7:21:55
Edited by kas1e on 2014/4/6 7:23:27
Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@kas1e

Quote:

Is on os4 possible to have screenblankers which didn't use screenblanker.library ? i mean imho they all use it ?


Example

...and there are a lot more out there

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@Raziel
So if there screenblankers which are not use screenblanker.library, but still are real screenblankers, then application library is only way to go.

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@kas1e

Actually that was only to show you that there are more ways to achieve a screen blank

I would say go with @xenic's solution of turning off the OS screenblanker (it's the "official" way of blanking screens).
imho you shouldn't bother or care what people have installed, otherwise you'd end up with no hair

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@Raziel
Quote:

that there are more ways to achieve a screen blank


I assume that with application.library way, _any_ screenblanker can be disabled/enabled, as they works via os4's screenblanker engine (by any i mean not some 3d party screenblanker which works on their own control, with their engine, but those ones which can be controled by prefs:screenblankers and works over os4's screenblanker engine). For other ones i have no worry, there can be milions of them with different kind of control.


Quote:

(it's the "official" way of blanking screens).


But application.library the same official way. Also, if with application.library way i can disable all kind of blankers which are controlled by prefs:screenblankers, its for sure better, in compare with way which will disable only blankers which use screenblanker.library (if of course have blanker in prefs:blankers dind't mean that its already use screenblanker.library).

At least that how i understand it: application.library way disable _any_ screenblanker, xenic's way disable only blankers which use screenblanker.library (if its not the same, and having blanker over os4's inbuild screenblanker engine didn't mean that its already use screenblanker.library).

I of course worry only about blankers controled by prefs:screenblankers and which use os4's screenblanker engine. Other blankers are "hacks". If that one on which you point out below are can't be controlled by prefs:screenblankers, and its just some 3d party app which works "like screenblanker", then of course its even not worth of worry to point on it, as there can be milions of different kinds.

Quote:

imho you shouldn't bother or care what people have installed,


I only care about that: way to disable/enable whole os4's inbuild screenblanking when i need. And only about os4's inbuild blanker engine, not about some non related to os4's blankerengine blankers which only called as blankers, but in reality its some commodities or bins in background or whatever without use of os4's screenblanker engine, but with their own init/fini/control.


Edited by kas1e on 2014/4/6 11:21:55
Edited by kas1e on 2014/4/6 11:24:23
Edited by kas1e on 2014/4/6 11:26:18
Edited by kas1e on 2014/4/6 11:37:58
Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Amigans Defender
Amigans Defender


See User information
Quote:
that was only to show you that there are more ways to achieve a screen blank

There may well be, but the idea is to use the screenblanker engine provided by the OS. Application Library and the screenblanker engine are interrelated: if an application is registered with REGAPP_AllowsBlanker, FALSE (or if at any time after registration APPATTR_AllowsBlanker is set to FALSE), the screenblanker engine will know that it should not kick in. If you use a custom blanker framework that does not communicate with Application Library, the _AllowsBlanker tags will have no effect.

Application/blanker interaction has somewhat been escaping attention because until now relatively few applications bothered to register with the library. With the advent of the BOOPSI Application Class (developed for OpenAmiga.org and to be released later this spring) I expect the number of registered apps to grow exponentially because it will now be much easier to use the Application Library framework.

These apps will of course expect their blanker disabling tags to work, so using a blanker engine other than the one provided by the OS is a no-no, as it would only create inconsistency in behaviour and confusion.

The Rear Window blog

AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@Trixie
Do you know maybe: Is any screenblanker which use screenblanker engine provided by the OS already use screenblanker.library ? I still think application library way is way to go, but just in theory, did xenic's way mean the same in end: disabling of all blankers which used by os4's screenblanker engine ?



Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Amigans Defender
Amigans Defender


See User information
@kas1e

Quote:
Is any screenblanker which use screenblanker engine provided by the OS already use screenblanker.library

I can't really say, Roman, try asking someone on the dev team. I'm more knowledgeable on the Application Library side of things but what the blanker engine uses internally, don't know.

Quote:
I still think application library way is way to go

It is.

Quote:
did xenic's way mean the same in end: disabling of all blankers which used by os4's screenblanker engine?

Not really. Xenic's solution disables the screenblanker engine's commodity broker, which is a global operation affecting all blankers using the engine. On the other hand, Application Library disables the blanker for individual registered applications: it has no global switch-all-blankers type of command AFAIK.

The Rear Window blog

AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Home away from home
Home away from home


See User information
@Trixie
Quote:

Not really. Xenic's solution disables the screenblanker engine's commodity broker, which is a global operation affecting all blankers using the engine. On the other hand, Application Library disables the blanker for individual registered applications: it has no global switch-all-blankers type of command AFAIK.


But imho for video player its more than ok to disable blanker for individual registered application (in that case video player itself). I.e. visually and for end users it will be the same imho in both ways : while player is play video, then no blanking.

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Just can't stay away
Just can't stay away


See User information
@trixie
Quote:
Not really. Xenic's solution disables the screenblanker engine's commodity broker, which is a global operation affecting all blankers using the engine. On the other hand, Application Library disables the blanker for individual registered applications: it has no global switch-all-blankers type of command AFAIK.


How can the screenblanker be controlled for an individual application and not globally when Amiga is a multitasking system? Application.library would need to track task switching to determine when the individual application code is running and only disable the screenblanker during those times. If it doesn't do that then the screenblanker would be disabled globally just like it would with the single line of code I suggested.

Amiga X1000 with 2GB memory & OS 4.1FE + Radeon HD 5450

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Just can't stay away
Just can't stay away


See User information
@kas1e
Quote:
while player is play video, then no blanking.

Yes, the screenblanking should only be disabled while a video is playing. If I leave my MPlayer window open, switch to my Internet screen to check email and then leave the computer for hours, I don't want the screenblanker to be disabled while I'm gone.

Amiga X1000 with 2GB memory & OS 4.1FE + Radeon HD 5450

Go to top
Re: Is there way to globaly disable/enable screenblanker engine ?
Amigans Defender
Amigans Defender


See User information
@xenic

Quote:
ow can the screenblanker be controlled for an individual application and not globally when Amiga is a multitasking system? Application.library would need to track task switching to determine when the individual application code is running and only disable the screenblanker during those times. If it doesn't do that then the screenblanker would be disabled globally just like it would with the single line of code I suggested.


I think what trixie meant, was that the screenblanker control works for any screenblanker application, whereas your method only works for ScreenBlankerEngine.

Any application can register itself to recieve screenblanker events and enable/disable themselves accordingly.

The other problem with your method is that it won't stack. If application A disables the blanker, and then application B disables the blanker, when applicaton A enables the blanker it should stay disabled until application B also enables it. I don't actually know if it does actually works like this, but it should.

Go to top

  Register To Post
(1) 2 »

 




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




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project