 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
Laszlo
Joined: 14 Feb 2005 Posts: 4033 Location: Pittsburgh
|
Posted: Mon Oct 16, 2006 1:36 am Post subject: |
|
|
| Version 1.02 works flawlessly for me (XP, 2GHz Centrino, 1GB RAM). I even increased the animate steps to 9, but with animate delays of 0. I am really curious how much faster it can get with DirectX. |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Mon Oct 16, 2006 5:11 am Post subject: |
|
|
this one is an experimental version for the *brave* v1.03 experimental
new features, speed refresh for the thumbnail under under mouse (toggle this with "space-key") thumbnails are clickable (i managed to change tabs in firefox in expose mode) only correct with maximized windows! (left click goes to targetwindow, middleclick for un-expose, activate window)
perhaps its better to create new versions based on v1.02 but its fun to interact with the "zoomed" windows. |
|
| Back to top |
|
 |
Laszlo
Joined: 14 Feb 2005 Posts: 4033 Location: Pittsburgh
|
Posted: Mon Oct 16, 2006 6:29 am Post subject: |
|
|
1.03 works, too. I have to make a selection with the middle button, which is OK, if your mouse has one. I don't know what the left clicks do. I only see the mouse pointer jumping around. Pressing the space bar reduces the quality of the thumbnail under the mouse pointer. I guess it is the price for fast update.
I uncommented the "minimize table size" commands (line 221, 222), because otherwise there is sometimes an empty row in the table of thumbnails. Why did you take them out? |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Mon Oct 16, 2006 6:41 am Post subject: |
|
|
| Laszlo wrote: | | I don't know what the left clicks do. I only see the mouse pointer jumping around. |
hmm, play a little more with it. the mouse clicks on the visible region of your thumbnailwindow. you can remote-click on the real window so you can press your play button on your mediaplayer etc. you even can close windows if you manage to hit the tiny [x] in upper right.
| Quote: | | Pressing the space bar reduces the quality of the thumbnail under the mouse pointer. I guess it is the price for fast update. |
yes, i make the fast refresh only quality:3 (coloroncolor) as interpolation is to slow. this way you even can follow fast flashbanner or video on video.google.com inside your expose in nearly realtime. (100% cpu though, abouth half the normal framerate)
| Quote: | | I uncommented the "minimize table size" commands (line 221, 222), because otherwise there is sometimes an empty row in the table of thumbnails. Why did you take them out? |
i commented them out to minimize the error of transtating the click into the real coordinates of the original window. quite experimental.
for letting the mouseclick through expose i first tried ControlClick which does not work. but by digging a whole into the window with WinSet Region works.
The mouse jumps around because it clicks onto the real window and then returns to the position it had in expose. more like a proof of concept for remote-controlling your zoomed windows. |
|
| Back to top |
|
 |
Laszlo
Joined: 14 Feb 2005 Posts: 4033 Location: Pittsburgh
|
Posted: Mon Oct 16, 2006 6:49 am Post subject: |
|
|
| The remote click does not seem to work for me. I tried this web page, [x], [quote], [pm], [reply]... no effect. |
|
| Back to top |
|
 |
Hacker
Joined: 10 Jun 2006 Posts: 65 Location: Bratislava, Slovakia
|
Posted: Mon Oct 16, 2006 5:55 pm Post subject: |
|
|
holomind,
| Quote: | | as i said, you either get quick response and watch windows "popping" up, or you "wait" for the backbuffer to complete |
As I said, I absolutely prefer waiting for the backbuffer, but I can't find any option to turn it on (off).
| Quote: | | i get nearly instant visible of windows. only 5 frames is to quick, and i even dont get a smooth animation. |
You are slowly forcing me to make a video using my digicam.
| Quote: | | which parts are too slow for you and not not only "animation" |
Well, the interval between the "frames" of the animation is too large. Just like when a game is too new for a computer - 5fps.
| Quote: | | what happens if you set animationstep to 1 ? |
You mean "animate_in_steps"?
Hm, wow, then it's almost immediate! Hey, nice!
The first run is about 1,3s, next runs are instantaneous.
Heh, I once tried 0, but the script didn't work, so I didn't try any other low number.
| Quote: | | is your problem moving (scaling the front window into the thumbnail-view)... |
Yes, this is the problem. The "animation".
| Quote: | | what are your pc specs ? cpu/ram/gfx-card ? |
Duron 1,1 GHz, 384 MB, Matrox Marvel G400 16 MB, 1024*768*32
Roman |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Wed Oct 18, 2006 12:10 am Post subject: |
|
|
| Laszlo wrote: | | The remote click does not seem to work for me. I tried this web page, [x], [pm], [reply]... no effect. |
perhaps you have problems because your taskbar is on left, as its experimental the calculation for finding the real position for click is not so perfect. one would need to apply the same formular like scaling thumbs down but in reverse. ) i switched back to version 1.02 which is more stable. |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Wed Oct 18, 2006 12:19 am Post subject: |
|
|
where are all contributors, adding features to expose-clone in wiki ?
* config(gui) , keybordsupport for selecting windows, plugin/standalone support... ?
we also should look/vote for a new name else we get trouble by apple-lawyers who dont want the name "expose" to be used outside of mac. they dont want that windows is getting features form osx, and less people switch.
the 2.0 releaseparty will be fun, one idea would be to meet in the #ahk chat at the same time (eg on a friday evening) and have a internetparty
i dont know if all ahk developers > 1000 posts have met at the same (real) time
i experimented a bit with direct-x or opengl but didnt find good sources. one always needs to compile c++ code or similar, and its very hard to call directx or opengl from ahk as they are "objectoriented" and not flat-api like gdi32.dll. this means my experiments with opengl/directdraw/directx will be low-prio. ... |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 3626 Location: Belgrade
|
Posted: Wed Oct 18, 2006 9:00 am Post subject: |
|
|
| Quote: | | where are all contributors, adding features to expose-clone in wiki ? |
I changed the spelling errors
Cmon, holomind don't be dissapointed. I will work on Expose when I find time witch as appears today will not be so soon (but not to distant also). I just don't have any free time now.
Hm... maybe if I don't sleep....  _________________
 |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Thu Oct 19, 2006 11:44 am Post subject: |
|
|
@majkinetor: i am glad you help with the project and i will wait until people contribute, anyways this should be/keep fun
i am still exploring the possibilites of using 3d-accelleration for animation.
its not really easy (even after reading some books and articles).
but my way to go is now:
opengl has a somewhat "c" -api and can perhaps be easily called with dllcall("opengl32.dll/..."). directx is com and only objectoriented and maybe hard to use with ahk. also i find openglcode easier to read.
there is one nice helperfunktion/library for doing 2d (and 3d with opengl) graphics. perhaps its only a wrapper for gdi, but anyways looks good. (i even have some working php-code doing 3d-graphics with sdl which animates more smooth than direct bitblt, perhaps)
http://www.libsdl.org/
would be nice to have opengl and sdl support in ahk, as i really dont like to program in cpp and would prefer to use ahk with some dllcalls and some wrapper libraries like GDI.ahk. |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Mon Oct 23, 2006 11:00 am Post subject: |
|
|
long time no posts here
i have done some research into the universe of opengl... and have some little usable parts and going into the right direction.
i managed to get some simple opengl demos running (which i can modify) with euphoria, which is easier to use than c++.
http://www.rapideuphoria.com/ (they have some "opengl" examples).
i managed to load a screenshot (bmp) and rotate it inside a opengl window. sounds not much, but is the basic parts needed to put the expose animation into an opengl window. if you are inside opengl (having your bmp as a mapped texture) animation is very fast and smooth. (on my pc i get about 30frames/sec rotating an 1400x1050 bitmap, and about 10fps when using only 1% cpu) i guess this cant be dont with bitblts.
euphoria has a bit of problems with opengl and uses 100% cpu all the time as it tries to paint as much frames as possible. but if you add some sleep-waits in the code you get smooth framerates and low cpu (thats what i want).
as this euphoria also is only wrapping the openglfunctions (which rely on opengl32.dll + glut.dll and others) it should be possible to do this with ahk directly. but using euphoria for the job is much easier in the moment.
in opengl you als can make screenshots with reading the frontbuffer (the thing you get with hdc=GetDC(0)) and saving it to file. also opengl is fast enough to do video playback of eg. avi etc. )
i have to find a way to combine the gdi/printwindow call with opengl to get liveupdate for the windows. this gives very nice possibilites.
i also found another interesting thing which is called video-mirror driver.
used in vnc to speed up transfer rates. it actually makes a copy of your display (=desktop) into a memory-dc which you can use then.
its like you attach another monitor to your computer and have windows on this. (like multimonitor). instead of mirroring your desktop is should be possible to have a virtual monitor. eg. a "real" virtual desktop where you have real pixels in memdc. this way you can move your window to this "virtual" monitor and then window paints all things to this memdc.
if you manage that windows dont overlap in this memdc windows/os has minimal repaints to do and this should keep cpu usage at minimum.
i guess you can do normal bitblts from this virtual desktop back to your real desktop. (i can just imagine that "hardware overlay" does something quite similar).
i guess i will run out of video/memory quickly but it will be fun to experiment.
i have made speed comparisons of vnc with "loopback" (eg. showing your window on your own desktop) vs. printwindow+ bitblt. and actually the printwindow and bitblt solution gave me better results sometimes.
with this two techniques (virtual desktop or video-mirror and opengl) one should be able to create something like xgl or compiz. where the windows are rendered "WM_PAINT" offscreen into the backbuffer, and then displayed with opengl into the frontbuffer (=desktop) with some fancy animations and other stuff. actually in opengl its not much speed difference if you watch a window in flat 2d or rotate it.
my idea is not to have fancy 3d rotation and stuff, but to have "zoomable" windows which you can minimize/scale with opengl, and have something like expose but in between.
also the 3ddesk program from linux which lets you change your desktops which are wrapped on a cube. could be possible with opengl and the upper details.
i noticed one drawback which is loading a bitmap into opengl texture is quite slow, seems euphoria could be optimized here. or it is a problem with the pc-bus system because you copy data from real-memory to video-memory which moves through cpu, or the problem is that SGI uses BGR instead of RGB for bitmaps and you have to flip the Blue and Red Bytes... |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 3626 Location: Belgrade
|
Posted: Mon Oct 23, 2006 11:40 am Post subject: |
|
|
excellent research. _________________
 |
|
| Back to top |
|
 |
scriptmonkey
Joined: 19 May 2006 Posts: 112
|
Posted: Thu Nov 02, 2006 3:40 pm Post subject: |
|
|
Is there a way to active the script by double clicking the Middle Mouse button? Some of the programs I use needs the middle mouse button, but this script interfere with it.
Good script though.  _________________ Zak M. |
|
| Back to top |
|
 |
holomind
Joined: 11 Mar 2006 Posts: 300 Location: Munich, Germany
|
Posted: Thu Nov 02, 2006 5:28 pm Post subject: |
|
|
@scriptmonkey: there are some examples of reading doubleclick in the manual and forum (the idea is to watch for click and if the last click is not long ago its a doubleclick)
http://www.autohotkey.com/forum/topic6448.html |
|
| Back to top |
|
 |
aydc
Joined: 12 Dec 2006 Posts: 15
|
Posted: Wed Feb 28, 2007 11:40 am Post subject: |
|
|
This is incredible!!! I've never used MacOSX, so when macheads bragged about expose, I always thought they were exaggerating.
After using this, I can only imagine how good it would be if microsoft included this to OS. That'll probably never happen, so your script is the next best thing. Thanks for the effort. |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|