[07 May 2012] Hwbeamer & Hollywood 5.0

Contains all messages from the Hollywood mailing list between 01/2006 and 08/2012
Locked
nexus
Posts: 133
Joined: Sun Mar 07, 2010 11:54 am

[07 May 2012] Hwbeamer & Hollywood 5.0

Post by nexus »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Mon, 07 May 2012 15:54:31 -0000

Hi Andreas,

First, thank you very much for Hollywood and your support! Both really helped my a lot to develope hwbeamer and, thus, for creating my PhD slides!

See this thread about my hwbeamer announcement and my PhD slides.

http://www.amigans.net/modules/xforum/v ... 7&forum=21

Second, I also want to give some hints about the problems / observations I had during the recent developments of hwbeamer.

1) Layer effects become extremely slow when there is a layer involved with alpha channel/transparency. This is even true for layers which area shown above the transparent layer (so, actually, there should not be any need to recompute anything related to the transparent layer?).

You can see this with my hwbeamer slides (see link in the referred thread above) on slide 2. When starting the presentation, choose a high resolution window (e.g. 1900x1200). Then you can see the movement of the text-blocks are unbearable slow. On later slides, where there is no such transparent layer involved. The movement speed is reasonable.

The transparent layer is created in the following way (code is shortened):

Code: Select all

brushid=CreateBrush(nil,SETTINGST.width,SETTINGST.height,#RED,{AlphaChannel=True,clear=False})

SelectAlphaChannel(brushid)
SetFillStyle(#FILLCOLOR)
SetFormStyle(#NORMAL)
SetAlphaIntensity(255)

if (h>0)
SetFormStyle(#ANTIALIAS) 
SetAlphaIntensity(0)
; here some "holes" are "cut" into the transparent layer 
Box(SETTINGST,width-rw,SETTINGST.height-rh,w,h,#WHITE,{name="spot"})
EndSelect 
endif

FloodFill(globalspotbrush,0,0,#WHITE,#BLACK)
DisplayBrush(globalspotbrush,0,0,{name="spotbrush",transparency=transparency,InsertPos=inspos})
However, the same "slowness" is true for text shadows. Effects on such text are extremely slow, too (e.g. the title text of "Part I" or "Part II" in my slides). I had to turned of the shadows before applying the effect and turn it on later again. Otherwise, it was simply too slow.

2) Polygons can only be drawn with at most 1000 points or you get an error message (-- something like wrong parameters, read documentation). I verified that 1000 points work but slightly more caused the error message. Sorry, I don't have any example code at the moment :)

3) When manually switching to full screen (with two windows opened) something goes wrong with the event handling (-- at least on linux.).

"Manually" means: catching a key-event, closing all windows that should not go to fullscreen, changing display mode for the remaining window and open the previously closed window again:

Code: Select all

If (SETTINGST.infowin)
CloseDisplay(2)
FreeDisplay(2)
EndIf

Local mode=GetAttribute(#DISPLAY,1,#ATTRMODE)
  If (mode=#DISPMODE_WINDOWED)
  ChangeDisplayMode(#DISPMODE_FULLSCREEN,SETTINGST.width,SETTINGST.height)
   EndIf

  If (SETTINGST.infowin)
  CreateDisplay(2,{BGPic=2,x=#RIGHT,y=#CENTER,width=SETTINGST.width, height=SETTINGST.height,title="info window",layers=True,color=#WHITE})
OpenDisplay(2)
p_setupinfo()
SelectDisplay(1,True)
ActivateDisplay(2)
EndIf
And that`s all code.

"something goes wrong" means the following: In hwbeamer, I catch key inputs like space, cursor keys, page up and down, etc and also left and right mouse buttons to navigate from one slide to the next or a previous slide. However, when switching to fullscreen, the key inputs seem to be ignored. Regardless what key I press, nothing happens. The mouse buttons however still work, such that I can continue to navigate from one slide to the next. Key-events are still not captured, though. When navigating from the title slide to the first slide, I additionally activate a timer which counts the seconds/minutes to see how long the presentation takes. Here I catch a key combination CTRL-SHIFT-T to stop/reset/restart the timer. This event is captured however and as soon as I have stopped the timer, the navigational key events are captured again. Afterwards, I can turn on the timer again. That`s really weird. There is no such problem when keeping all windows in window mode or if I start the application with "-fullscreen" as a commandline argument.

The non-fullscreen windows only show textout-layers and the time passed measured by the timer -- nothing else and especially, there is no event handling at all.

I hope, you have got an idea what goes wrong here and if this is a bug of mine or yours ;) Sorry, that I don`t have any example code, demonstrating the problem. I simply haven`t had the time in the hot phase right before my defence talk to find some short example code :)

Thanks! Tom
User avatar
Clyde
Posts: 348
Joined: Sun Feb 14, 2010 12:38 pm
Location: Dresden / Germany

[08 May 2012] Re: Hwbeamer & Hollywood 5.0

Post by Clyde »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Tue, 08 May 2012 21:08:13 +0200

Hi Tom,

congrats on your PhD and your overall work! I think your mail would be a good starting point for an own blog. Could be a nice series about hwbeamer and Hollywood in general! What do you think?

Regards Micha

PS: Next version of hw4c will be released soon!
Currently using: Hollywood 9 with Windows IDE and Hollywood 9 with Visual Studio Code and hw4vsc
nexus
Posts: 133
Joined: Sun Mar 07, 2010 11:54 am

[09 May 2012] Re: Hwbeamer & Hollywood 5.0

Post by nexus »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Wed, 9 May 2012 11:23:16 +0200 (CEST)
Hi Tom,

congrats on your PhD and your overall work! I think your mail would be a good starting point for an own blog. Could be a nice series about hwbeamer and Hollywood in general! What do you think?
Thanks! A blog is a nice idea for this. I just think, as usually, I do not find the time for things like this. But I keep that in mind and maybe I indeed start something like this.
PS: Next version of hw4c will be released soon!
cool. It is very much appreciated. As you can see in the youtube description, I've given some credits to you because of hw4c :)

However, that reminds me on another problem during my slide development. The more slides I had, the slow hwbeamer started in E-UAE (because of the preloading of all the images). So, I used your HWCC tool (Version 0.9.2) to compile linux binaries. So, I edited the slide contents with cubicIDE in AmigaForever/E-UAE and compiled linux binaries which then were started in their native linux environment.

However, when I used HWCC the whole Emulation/OS crashed extremely often. Closing the HWCC window caused almost always the OS to crash but also compiling caused the OS to crash. The more often I compiled a binary, the more likely it was that everything crashed. And just even keeping the HWCC window open caused sometimes the OS to crash when I e.g. saved some changes in hws-sources.

Before I used HWCC, everything worked fine in CubicIDE and crashes didn't happen (almost) at all. Those crashes were really annoying, however, restarting the emulation environment and opening the hws-sources again was still quicker than waiting in E-UAE until all images were preloaded for my slides. :)

Sometimes however, the hws-files were corrupted or completely empty. That was kind of frightening. However, because of cubic's automatic backups I never lost a single change.

The AOS3-System and the hwbeamer sources are kept on a Fat32 partition (instead of using a hardfile. Cubic and the backups were kept on a hardfile, though). Maybe this is also a reason for the crashes? However, as I said, without HWCC such crashes didn't happen. I used Fat32 to be able to read the partition in Windows, too, and to be able to immediately copy sources form the E-UAE Environment to a linux partition and committing them into an SVN repository.

cheers, Tom

P.S. Oh, and only sometimes a window was opened with a warning that an existing file would be overwritten when I continue. (I uses allowas the option "attach OS string" instead of "create directories"). Such window rarely opened. Actually, that was good because it saved me an extra click ;) However, it was not clear to me what it caused to open or to keep hidden.
nexus
Posts: 133
Joined: Sun Mar 07, 2010 11:54 am

[09 May 2012] Re: Hwbeamer & Hollywood 5.0

Post by nexus »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Wed, 9 May 2012 11:40:12 +0200 (CEST)

Hi Andreas,

and an additional observation/problem was:

4) When selecting an layer with antialias features as output device and drawing a picture on it, the border of the layer does not show antialias features anymore. The code, i used looks as follows :

Code: Select all

UseFontPath(True)
...
SetFontStyle(#NORMAL)
SetFontStyle(#ANTIALIAS)
Circle(x+1,y+1,r,$F0F8FF,{name=cid,hidden=True})

Local piclid=p_displayGFX("mypicture.png",x,y,nil,True,True)
ConvertToBrush(#LAYER,piclid,666)
SelectLayer(cid)
SetFormStyle(#ANTIALIAS)
DisplayBrush(666,r-pw/2,r-ph/2)
EndSelect
FreeBrush(666)
And a question: Do I really have to convert a layer to a brush to be able to display the picture after "SelectLayer()"? It was the only way, I could figure out how to draw a photo into a circle :)

Thanks! Tom
User avatar
airsoftsoftwair
Posts: 5425
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

[12 May 2012] Re: Hwbeamer & Hollywood 5.0

Post by airsoftsoftwair »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Sat, 12 May 2012 22:19:49 +0200
1) Layer effects become extremely slow when there is a layer involved with alpha channel/transparency. This is even true for layers which area shown above the transparent layer (so, actually, there should not be any need to recompute anything related to the transparent layer?).
This shouldn't happen here. The only case where transition fx will become slower is when a layer is using a border or shadow setting or has filters applied. But normal alpha channel / transparency setting shouldn't slow down the effects.

Can you provide a very small code snippet that demonstrates the problem?
2) Polygons can only be drawn with at most 1000 points or you get an error message (-- something like wrong parameters, read documentation). I verified that 1000 points work but slightly more caused the error message. Sorry, I don't have any example code at the moment :)
That's a known limit. I can change this. How many vertices do you need? :)
3) When manually switching to full screen (with two windows opened) something goes wrong with the event handling (-- at least on linux.).

"Manually" means: catching a key-event, closing all windows that should not go to fullscreen, changing display mode for the remaining window and open the previously closed window again: [...]

And that`s all code.
I'm afraid that code doesn't help. I need very small code snippets that I can copy & paste and test directly. Everything else takes too much time :)
"something goes wrong" means the following: In hwbeamer, I catch key inputs like space, cursor keys, page up and down, etc and also left and right mouse buttons to navigate from one slide to the next or a previous slide. However, when switching to fullscreen, the key inputs seem to be ignored. Regardless what key I press, nothing happens. The mouse buttons however still work, such that I can continue to navigate from one slide to the next. Key-events are still not captured, though. When navigating from the title slide to the first slide, I additionally activate a timer which counts the seconds/minutes to see how long the presentation takes. Here I catch a key combination CTRL-SHIFT-T to stop/reset/restart the timer. This event is captured however and as soon as I have stopped the timer, the navigational key events are captured again. Afterwards, I can turn on the timer again. That`s really weird. There is no such problem when keeping all windows in window mode or if I start the application with "-fullscreen" as a commandline argument.

The non-fullscreen windows only show textout-layers and the time passed measured by the timer -- nothing else and especially, there is no event handling at all.

I hope, you have got an idea what goes wrong here and if this is a bug of mine or yours ;) Sorry, that I don`t have any example code, demonstrating the problem. I simply haven`t had the time in the hot phase right before my defence talk to find some short example code :)
Sure, maybe you have time for example code now but please make it ASAP (= as short as possible) :) The shorter the code, the more motivation I have to have a look at it and possibly fix it :)
User avatar
airsoftsoftwair
Posts: 5425
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

[12 May 2012] Re: Hwbeamer & Hollywood 5.0

Post by airsoftsoftwair »

Note: This is an archived post that was originally sent to the Hollywood mailing list on Sat, 12 May 2012 22:25:10 +0200
Hi Andreas,

and an additional observation/problem was:

4) When selecting an layer with antialias features as output device and drawing a picture on it, the border of the layer does not show antialias features anymore. The code, i used looks as follows :
Once again, that code doesn't really help because I can't copy & paste and test it directly. So I'm not sure if we're talking about a bug or feature here :) I'd suppose the behaviour is correct, though, because once you call SelectLayer() the vector layer becomes rasterized and this will definitely lead to a different look of the border, shadow etc. because the vector layer is now handled as a brush layer.
And a question: Do I really have to convert a layer to a brush to be able to display the picture after "SelectLayer()"? It was the only way, I could figure out how to draw a photo into a circle :)
Yes, you can't add a picture to a circle layer without converting this circle layer into a raster layer first. This is necessary because a circle layer is a vector layer and you cannot add raster graphics to vector layers without rasterizing the vector layers first.
Locked