Jump to content

bigmuscle

Patron
  • Posts

    1,758
  • Joined

  • Days Won

    7
  • Donations

    0.00 USD 
  • Country

    Czech Republic

Everything posted by bigmuscle

  1. yeah, this is done by the time which sets windows as layered. It runs with interval 500 ms thus new windows won't have transparency effect until the update routine is executed. This could be easily fixed by installing global windows hook which sets the window as layered during its creation. Problem is that this would require to have another service running (just because dwm.exe process does not run under logged user credentials). For anyone, who has problem with 0.4, could you try set BypassLayeredWindowsRendering to zero whether it helps?
  2. AERO GLASS for Win8 PREVIEW 4 So, another build is here. What's new: * begun work on Direct3D mode, it works, it should be much faster than Direct2D mode but it has a lot of glitches at this time. This mode use native DWM objects and shaders!!! (but Direct2D is still as default until it is complete) * disabled alpha-blending of layered windows with alpha value of 254 - this should make rendering faster and avoid small transparency on all windows. This option has not been tested much so you can disable it using the registry settings. * removed option to force bounding rectangle redraw * fixed PDB file loading to generate useful crash reports * added hot key Ctrl+Alt+F12 to quickly disable DWM hooking (e.g. in the case of black screen etc.) * added new registry settings: In Direct3D mode, you can use classic colorization settings under HKEY_CURRENT_USER\Software\Microsoft\Windows\DWM: ColorizationBlurBalance, ColorizationAfterglow, ColorizationColor, ColorizationColorBalance HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\DWM (no user-specific settings now!) BypassLayeredWindowsRendering (DWORD) = when set to 0, the layered windows with 254 alpha are rendered in normal way. UseDirect2DRendering (DWORD) = 0 = use Direct3D mode, 1 = use Direct2D mode ColorizationXXXInactive (DWORD) = sets colorization settings for inactive windows (Direct3D mode only). In Direct2D you can use only ColorizationColorInactive (format is 0xAARRGGBB - alpha is ignored) to set the the color of inactive border. Note: settings BlurDeviation has no effect in Direct3D mode. http://leteckaposta.cz/332845979
  3. I guess that having rounded border would require to modify vertex buffer and generate new vertices (and I don't want to do it at this time). Rectangle border is generated from 22 vertices, but rounded border is generated from 70 vertices. It could increase complexity a lot.
  4. vanden: as I wrote above, read the changelogs of preview versions for exact description. DeviceFeatureLevel is registry settings for my utility under HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\DWM.
  5. So try the thing with DeviceFeatureLevel registry value. I can't say about Virtualbox, but on VMWare when display drivers are not installed - Direct3D 10.1 render function is not called at all. When you change the DeviceFeatureLevel to 0x9300 then it starts working.
  6. Can you tell me how to do this? I am having this same problem, and it is driving me crazy. Read the topic few pages back. I wrote it in the changelog of some previous release. However, I can't ensure that it will really work. For me, it just fixed crash when no graphics drivers were installed.
  7. You can try playing with DeviceFeatureLevel registry settings. It allows achieving glass effect also on non-supported drivers (and even when no graphics drivers are installed).
  8. Yeah, there is still everything - pixel shaders, vertex shaders, sampler states, input layouts etc. and everything is even loaded into memory during DWM startup. I am currently playing with the pixel shaders and it works like a charm. It even respects the colorization/balance settings from the registry. However, I do not want to rely on it too much because we can't say how long the code stays there and it can be removed with any future update.
  9. It is not fully possible, but next version will use original pixel shaders which are still present in Windows 8 and even loaded into memory by DWM process itself.
  10. I must admit that I am not sure what you think by "the library values from a dwm of windows 8 release preview".
  11. Please, could you discuss GUI things in a separate thread? I want to have this thread for discussing DWM hook stuff only.
  12. If it is the same bug as I think (i.e. windows are not really minimized, they are just not drawn, so you see the content beneath them) then there seems to be no solution yet. I guess this is the problem of DWM itself. And since it happens on DWMHook startup only I'm not going to fix it now.
  13. I don't see the blacklist as a good solution. Also it couldn't be on file/application name level but on the level of window/class name. When occluded regions are correctly generated, we won't need the "layered" hack anymore and it should work for any application. Currently I have implemented a small feature that layered windows with alpha 254 are not blended into desktop anymore. It fixes the problem that you can see through the window under certain conditions but unfortunately it has no effect on problems with rendering of applications such as iTunes.
  14. Could you share your solution via UXTheme? Did it enable true transparency, i.e. rendering the content behind the window border without layered windows hack? Applications such as Office 2013, Visual Studio 2013 are not affected by my tool because they do not use DWM rendering for their windows (i.e. DWMWA_NCRENDERING_ENABLED flag is disabled for them).
  15. Just a small secret... every program which you install into your computer can take screenshots
  16. no, this is preview version which is not intended for regular usage
  17. debug log is created in the folder where DLL is located unless you disabled it in the registry
  18. please, provide debug log in such case so we can know where it stopped working
  19. if you use StartIsBack's transparency method then AeroGlass blur is rendered into taskbar too. Then the AeroGlass settings are also applied to the taskbar area.
  20. sorry but there is no solution for your problem yet
  21. Unfortunately, this is normal, because blur algorithm requires some more extra pixels around to correctly blur edge pixels (the higher radius the more pixels is required). The problem is Win8 does not mark these extra pixels as dirty when some region changes so it blurs with wrong pixels around the edges
  22. Yeah, close animation seems to be disabled when layered window is activated. I have not found a way to get it back (except of hooking WM_CLOSE and call AnimateWindow on my own which is a bit ugly). btw, anyone having problem with high CPU/GPU usage, please try that ForceBoundingRectangleRedraw settings. It will be bring some glitches into border painting (which is not important currently) but it let us know whether your problem is caused by blurring algorithm or by layered windows.
  23. And just a small thing for users who like coding in C++ and Direct2D/Direct3D and would like to play with a little code. At the beginning of this project I was trying to implement transparency and blur effect via wndproc hooking and implementing my own WM_NCPAINT handler. It was working correctly but it was slow. There were many lags on window move and resize. I was using the following code to reach the transparency effect. The problem if this code is that is written using GDI library so it is slow and does not render any layered windows nor Direct3D content in transparent areas. Maybe it would be worth to reimplement it using Direct2D/Direct3D (maybe user32.dll: DwmGetDxSharedSurface could be used to get actual window content) and then try using in the project to achieve transparency without layered windows. void OffscreenBuffer::update() { // since there is no easy way to access DWM Direct3D surface, we must render windows using GDI // problem is that it does not render any Direct3D content (including DWM window border or layered windows) bmpRT->BeginDraw(); HDC hDC; gdiBitmapTarget->GetDC(D2D1_DC_INITIALIZE_MODE_COPY, &hDC); auto winRegion = CreateRectRgn(wi.rcWindow.left - RADIUS, wi.rcWindow.top - RADIUS, wi.rcWindow.right + RADIUS, wi.rcWindow.bottom + RADIUS); auto clientRegion = CreateRectRgn(wi.rcWindow.left + wi.cxWindowBorders + RADIUS, wi.rcWindow.top + wi.cyWindowBorders + RADIUS, wi.rcWindow.right - wi.cxWindowBorders - RADIUS, wi.rcWindow.bottom - wi.cxWindowBorders - RADIUS); HRGN borderRegion = CreateRectRgn(0,0,0,0); CombineRgn(borderRegion, winRegion, clientRegion, RGN_DIFF); // iterate over all windows (starting with the current window) and render their content into off-screen bitmap // only windows obsured by our window border are rendered HWND next = hWnd; while(next = GetNextWindow(next, GW_HWNDNEXT)) { if(IsWindowVisible(next) && !((GetWindowLong(next, GWL_EXSTYLE) & WS_EX_LAYERED) == WS_EX_LAYERED)) // ignore layered windows for now { RECT wndRect = { 0 }; GetWindowRect(next, &wndRect); if(RectInRegion(borderRegion, &wndRect)) // does window lie beneath our border? { HDC winDC = ::GetWindowDC(next); // avoid drawing area which lies outside of the border SelectClipRgn(winDC, borderRegion); SelectClipRgn(hDC, borderRegion); // blit the clipped region BitBlt(hDC, wndRect.left, wndRect.top, wndRect.right - wndRect.left, wndRect.bottom - wndRect.top, winDC, 0, 0, SRCCOPY); SelectClipRgn(winDC, NULL); ReleaseDC(next, winDC); // substract region of this window not to blit windows which are obscured by it HRGN wndRgn = CreateRectRgnIndirect(&wndRect); int currRgn = CombineRgn(borderRegion, borderRegion, wndRgn, RGN_DIFF); DeleteObject(wndRgn); // if we end up with empty region (i.e. all discovered windows already take whole border area), // it makes no sense to continue, because all other windows wouldn't be visible at all if(currRgn == NULLREGION) break; } } } SelectClipRgn(hDC, NULL); DeleteObject(winRegion); DeleteObject(clientRegion); DeleteObject(borderRegion); RECT rc = { max(0, wi.rcWindow.left), max(0, wi.rcWindow.top), min(wi.rcWindow.right, 1920), min(wi.rcWindow.bottom, 1080) }; gdiBitmapTarget->ReleaseDC(&rc); bmpRT->EndDraw(); } Just in case, anyone want to play...
×
×
  • Create New...