Driver Problems? Questions? Issues?
Put OSR's experience to work for you! Contact us for assistance with:
  • Creating the right design for your requirements
  • Reviewing your existing driver code
  • Analyzing driver reliability/performance issues
  • Custom training mixed with consulting and focused directly on your specific areas of interest/concern.
Check us out. OSR, the Windows driver experts.

Upcoming OSR Seminars:

Writing WDF Drivers I: Core Concepts, Nashua, NH 15-19 May, 2017
Writing WDF Drivers II: Advanced Implementation Tech., Nashua, NH 23-26 May, 2017
Kernel Debugging and Crash Analysis, Dulles, VA 26-30 June, 2017
Windows Internals & Software Driver Development, Nashua, NH 24-28 July, 2017


Go Back   OSR Online Lists > ntdev
Welcome, Guest
You must login to post to this list
  Message 1 of 45  
09 May 17 09:30
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

Hello everyone, I just started to learn how to write drivers and I don't fully understand how do I check the drivers .. I want to see the examples provided by MS and I don't understand what to check so I hope someone could help me with some guide lines , sorry if this question is off-topic but this is the only "live" forum deals with drivers.. In general : what I'm trying to do is to print pictures/change color of the screen from the kernel mode so I'll be happy to hear any advice about how to do it right.. Thank you all and have a nice day :)
  Message 2 of 45  
09 May 17 12:55
Tim Roberts
xxxxxx@probo.com
Join Date: 28 Jan 2005
Posts To This List: 11455
Display driver check

xxxxx@gmail.com wrote: > Hello everyone, I just started to learn how to write drivers and I don't fully understand how do I check the drivers .. I want to see the examples provided by MS and I don't understand what to check so I hope someone could help me with some guide lines , sorry if this question is off-topic but this is the only "live" forum deals with drivers.. > In general : what I'm trying to do is to print pictures/change color of the screen from the kernel mode so I'll be happy to hear any advice about how to do it right.. There is no way to do that right. The concept of "user interface" is a user-mode concept, not a kernel-mode concept. You don't have easy access to the desktop from the kernel. What's your overall goal here? You can certainly launch a helper application to handle the UI tasks for you. -- Tim Roberts, xxxxx@probo.com Providenza & Boekelheide, Inc.
  Message 3 of 45  
09 May 17 13:33
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

My overall goal is to draw/print pixels on the monitor without being application. I wanna to be able to communicate directly with the GPU and display things on the monitor - For example, draw a blue rectangle in the middle of the screen without any nessecery application.
  Message 4 of 45  
09 May 17 16:30
Tim Roberts
xxxxxx@probo.com
Join Date: 28 Jan 2005
Posts To This List: 11455
Display driver check

xxxxx@gmail.com wrote: > My overall goal is to draw/print pixels on the monitor without being application. I wanna to be able to communicate directly with the GPU and display things on the monitor - For example, draw a blue rectangle in the middle of the screen without any nessecery application. Nope. You can't do that, at least not in any supportable and maintainable way. You will need user-mode help. -- Tim Roberts, xxxxx@probo.com Providenza & Boekelheide, Inc.
  Message 5 of 45  
09 May 17 18:22
M M
xxxxxx@hotmail.com
Join Date: 21 Oct 2010
Posts To This List: 717
Display driver check

If you wish to take over a monitor from Windows are draw your image on it this might be possible. If you want to interleave your blue rectangle with ordinary Windows drawing, then you are out of luck. This is of course possible by hammering or random memory, but in terms of a solution that works in general, this is way out of bounds Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10 From: xxxxx@gmail.com<mailto:xxxxx@gmail.com> Sent: May 9, 2017 1:32 PM To: Windows System Software Devs Interest List<mailto:xxxxx@lists.osr.com> Subject: RE:[ntdev] Display driver check My overall goal is to draw/print pixels on the monitor without being application. I wanna to be able to communicate directly with the GPU and display things on the monitor - For example, draw a blue rectangle in the middle of the screen without any nessecery application. --- NTDEV is sponsored by OSR Visit the list online at: <http://www.osronline.com/showlists.cfm?list=ntdev> MONTHLY seminars on crash dump analysis, WDF, Windows internals and software drivers! Details at <http://www.osr.com/seminars> To unsubscribe, visit the List Server section of OSR Online at <http://www.osronline.com/page.cfm?name=ListServer> --
  Message 6 of 45  
10 May 17 02:34
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

So when you say here is that I can't go to the register which holds the next screen and change their values so things I want will show on the screen ? If I can't, can you please say what can I change in the screen in term so colors and pixels changing without application - For example, lets say the next screen is what you see now ( I mean the forum ) and by changing things I'll draw a black line in the middle of the screen.
  Message 7 of 45  
10 May 17 03:16
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

I found that : https://www.youtube.com/watch?v=Tfh0ytz8S0k. Look at 6:00 you'll see that he draw a Pacman over all elements of the screen and if you look bit earlier you'll see that he done it but writing values to the memory. But, that is "out-dated" I'm looking for more "dated"/modern implementation of the same result.
  Message 8 of 45  
10 May 17 04:24
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Nice jurassic video. Exactly the same things can be done today with a modern contemporary Windows DirectX application. This DirectX application can run in both "Windowed Mode" or in "Full Screen Mode". What a DirectX application can NEVER do in any standard, documented and maintainable way: Modify screen content of OTHER applications or even Windows itself. One of the many reasons is shown at 0:30 "The video chip back then didn't have its own bank of memory, so it had to share with the CPU". Nowadays graphics adapters DO have own dedicated PCI on-board video memory (at least AMD and NVidia do). This on-board video memory can directly display to the screen. It might reside in a segment which is not even CPU-visible. It is extremely difficult to access by any software (other than the GPU vendor's display driver itself). Marcel Ruedinger datronicsoft
  Message 9 of 45  
10 May 17 05:04
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

But doesn't embedded video cards like Intel graphics share their memory with the CPU ? And I can't DirectX or OpenGL because as you said, it's limited to only their application.
  Message 10 of 45  
10 May 17 05:58
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

If limited to Intel GPU only, then the frame buffer can be accessed more easily, indeed. Still the Intel WDDM display driver would need to be hacked to find out where the frame buffer is located, what is its resolution pitch, etc. Such a "solution" would still be very hard to implement reliably and maintain because: - Frame buffer can change location in memory and size at any point time. (e.g. resolution change, sleep/wake, and many more occasions) - Framebuffer of Intel GPUs is tiled/swizzled in memory. - Next update of Intel driver can break existing "solution". Just to name a few of the problems one would encounter with such a "solution"... Why not use a very simple user mode application implementing "Transparent Window" and "Always on Top" Windows features. That sounds much more like a real solution to me... Marcel Ruedinger datronicsoft
  Message 11 of 45  
10 May 17 07:03
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

OK first of all really than you for helping me! Secondly, I'm limited to Intel GPU ( sorry I didn't said that before... ). I can't use "Transparent Window" and "Always on Top" application because that will block all the other apps - I mean that lets say I'm on facebook and then the app started, although it's transparent I couldn't be able to keep surfing in Facebook and click on things because the top window is the app ( if the app on full screen ). But, if I could write to the GPU then I could keep surfing but there is always be something ( lets say black line ) that I *see* on the screen but the line don't hurt my surfing experience - except for the fact that there is black line in the screen. About your "solution" can you instruct me what I need to do in order to accomplish what I just described to you?
  Message 12 of 45  
10 May 17 07:27
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

This is a Windows driver development forum. I don't want to pollute it with beginner level Windows application programming instructions. Just one hint: Use Windows Task Manager and select the menu "Always on Top". Then you can still see Windows Task Manager and input into the Window below. Marcel Ruedinger datronicsoft
  Message 13 of 45  
10 May 17 07:46
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

By saying "solution" I didn't mean to the DirectX solution ... I meant to instructions for your first solution which I write to the memory of the embedded GPU.
  Message 14 of 45  
10 May 17 08:33
Bob Ammerman
xxxxxx@ramsystems.biz
Join Date: 05 Jun 2016
Posts To This List: 48
Display driver check

AlwaysOnTop !=3D HasFocus * Bob =A0 Bob Ammerman =A0 xxxxx@ramsystems.biz 716.864.8337 138 Liston St=20 Buffalo, NY 14223 www.ramsystems.biz > -----Original Message----- > From: xxxxx@lists.osr.com [mailto:bounce-631079- > xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com > Sent: Wednesday, May 10, 2017 7:03 AM > To: Windows System Software Devs Interest List <xxxxx@lists.osr.com> > Subject: RE:[ntdev] Display driver check >=20 > OK first of all really than you for helping me! > Secondly, I'm limited to Intel GPU ( sorry I didn't said that before... )= . > I can't use "Transparent Window" and "Always on Top" application becaus= e > that will block all the other apps - I mean that lets say I'm on facebook= and > then the app started, although it's transparent I couldn't be able to kee= p > surfing in Facebook and click on things because the top window is the app= ( if > the app on full screen ). But, if I could write to the GPU then I could k= eep > surfing but there is always be something ( lets say black line ) that I = *see* on > the screen but the line don't hurt my surfing experience - except for the= fact > that there is black line in the screen. > About your "solution" can you instruct me what I need to do in order to > accomplish what I just described to you? >=20 > --- > NTDEV is sponsored by OSR >=20 > Visit the list online at: > <http://www.osronline.com/showlists.cfm?list=3Dntdev> >=20 <...excess quoted lines suppressed...>
  Message 15 of 45  
10 May 17 08:35
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

what?
  Message 16 of 45  
10 May 17 13:25
Tim Roberts
xxxxxx@probo.com
Join Date: 28 Jan 2005
Posts To This List: 11455
Display driver check

xxxxx@gmail.com wrote: > Secondly, I'm limited to Intel GPU ( sorry I didn't said that before... ). > I can't use "Transparent Window" and "Always on Top" application because that will block all the other apps - I mean that lets say I'm on facebook and then the app started, although it's transparent I couldn't be able to keep surfing in Facebook and click on things because the top window is the app ( if the app on full screen ). Wrong. As Bob tried to tell you, just because your window is topmost in the Z order does not mean you have the focus. Clicks and keyboard entries can still go to your browser. However, you do not actually have to BE the topmost window to draw on the desktop: HDC * dc = GetDC(GetDesktopWindow()); That gives you a DC to draw on the desktop. You don't even need a window at all. You can compile and run this complete command-line application to prove that: #include <atlbase.h> #pragma comment( lib, "gdi32.lib" ) int main() { HDC dc = GetDC( GetDesktopWindow() ); SetDCBrushColor( dc, RGB(255,0,0) ); SelectObject( dc, GetStockObject(DC_BRUSH) ); Rectangle( dc, 200, 200, 400, 400 ); } > But doesn't embedded video cards like Intel graphics share their memory with the CPU ? Possibly, but but there's no way to find that memory in kernel mode, and even if you found it, the memory doesn't belong to you. It belongs to another driver. It might be in a format you don't know, especially if the foreground app has taken control. > But, if I could write to the GPU then I could keep surfing but there is always be something ( lets say black line ) that I *see* on the screen but the line don't hurt my surfing experience - except for the fact that there is black line in the screen. > About your "solution" can you instruct me what I need to do in order to accomplish what I just described to you? We are all absolutely clear on what you want to do. We've all told you the facts -- in modern Windows, it can't be done in kernel mode. When you don't LIKE an answer. you don't get a different answer by asking the question again. -- Tim Roberts, xxxxx@probo.com Providenza & Boekelheide, Inc.
  Message 17 of 45  
10 May 17 15:07
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Well, you decided to delve into beginner level Windows application programm= ing here. Subsequently the following questions arise immediately:=20 How would this approach synchronize with Desktop being redrawn by Windows? Was this a good advice to solve the OP's problem? Marcel R=FCdinger datronicsoft
  Message 18 of 45  
10 May 17 16:06
R0b0t1
xxxxxx@gmail.com
Join Date: 24 Mar 2017
Posts To This List: 35
Display driver check

On Wed, May 10, 2017 at 2:06 PM, <xxxxx@datronic.de> wrote: > Well, you decided to delve into beginner level Windows application programming here. Subsequently the following questions arise immediately: > How would this approach synchronize with Desktop being redrawn by Windows? > Was this a good advice to solve the OP's problem? > This devolved into normal application programming because the list either refused to or was unable to answer his original question. The question he originally asked has an answer even if it is a bad idea. I can think of a few valid reasons to want to control video memory directly, or even a whole monitor, even if it's just for the novelty of it. To the OP: If you actually want to pursue this you will probably need to switch to Linux. Nobody here has any idea how to do what you asked about. They gave you some guesses which are mostly right but there may in fact be a way to do it by interfacing with the Windows display driver that is above the drivers that talk to graphics cards. If you start reading about the (modern!) Linux graphics system you will see what I'm talking about. Windows kernel architecture seems to mirror Linux kernel architecture in more than a few places, which kind of implies something similar has to exist. But discounting that it's unlikely they don't have some kind of wrapper layer.
  Message 19 of 45  
10 May 17 16:10
R0b0t1
xxxxxx@gmail.com
Join Date: 24 Mar 2017
Posts To This List: 35
Display driver check

Also to the OP: If you want to interface with the graphics card, as a graphics device, and display things to the screen, under Windows, you should probably look at https://www.khronos.org/opengl/wiki/Creating_an_OpenGL_Context_(WGL). It would also be possible to use a cross platform library like SDL2 or GLFW.
  Message 20 of 45  
10 May 17 16:15
R0b0t1
xxxxxx@gmail.com
Join Date: 24 Mar 2017
Posts To This List: 35
Display driver check

Okay, I really do apologize for the triple post, but I just remembered some relevant information w.r.t. the original topic: It's possible to allocate framebuffers from an OpenGL device. These framebuffers have no associated display. However, there is one framebuffer, normally claimed by the OS, that is tied to the display output. If you can claim this framebuffer and set it up then you control the video output for the computer at the lowest level possible. In this case the "driver above the graphics card drivers" is kind of OpenGL.
  Message 21 of 45  
10 May 17 16:39
Tim Roberts
xxxxxx@probo.com
Join Date: 28 Jan 2005
Posts To This List: 11455
Display driver check

R0b0t1 wrote: > Also to the OP: If you want to interface with the graphics card, as a > graphics device, and display things to the screen, under Windows, you > should probably look at > https://www.khronos.org/opengl/wiki/Creating_an_OpenGL_Context_(WGL). > It would also be possible to use a cross platform library like SDL2 or > GLFW. All of those things work just fine to draw graphics into your own window. That's not what he wants to do. He wants to vandalize the current desktop image from a kernel driver. -- Tim Roberts, xxxxx@probo.com Providenza & Boekelheide, Inc.
  Message 22 of 45  
10 May 17 16:45
Tim Roberts
xxxxxx@probo.com
Join Date: 28 Jan 2005
Posts To This List: 11455
Display driver check

xxxxx@datronic.de wrote: > Well, you decided to delve into beginner level Windows application programming here. Subsequently the following questions arise immediately: > How would this approach synchronize with Desktop being redrawn by Windows? It would synchronize in exactly the same way as the draw-directly-on-the-frame-buffer hackery that he proposed in the first place, which is to say "not at all". The original poster is laboring under the misconception that the hackery he wants to do must be done from kernel mode. That is utterly false, as my code demonstrates. It's still hackery, but it works. > Was this a good advice to solve the OP's problem? Got a better idea? The OP's problem cannot be solved in the way he wants to solve it. I'm fairly confident that this is not a commercial enterprise trying to innovate solutions to a new problem. This is an individual trying to do something cute, like drawing annoying things onto a game that he doesn't like. He wants hackery. -- Tim Roberts, xxxxx@probo.com Providenza & Boekelheide, Inc.
  Message 23 of 45  
10 May 17 17:01
R0b0t1
xxxxxx@gmail.com
Join Date: 24 Mar 2017
Posts To This List: 35
Display driver check

On Wed, May 10, 2017 at 3:44 PM, Tim Roberts <xxxxx@probo.com> wrote: > xxxxx@datronic.de wrote: >> Well, you decided to delve into beginner level Windows application programming here. Subsequently the following questions arise immediately: >> How would this approach synchronize with Desktop being redrawn by Windows? > > It would synchronize in exactly the same way as the > draw-directly-on-the-frame-buffer hackery that he proposed in the first > place, which is to say "not at all". The original poster is laboring > under the misconception that the hackery he wants to do must be done > from kernel mode. That is utterly false, as my code demonstrates. It's > still hackery, but it works. <...excess quoted lines suppressed...> I really think all of this is irrelevant. The display output is available directly from a graphics card via OpenGL. The question then becomes "how do you obtain the root framebuffer from the Windows kernel?" >> Was this a good advice to solve the OP's problem? > > Got a better idea? The OP's problem cannot be solved in the way he > wants to solve it. I'm fairly confident that this is not a commercial > enterprise trying to innovate solutions to a new problem. This is an > individual trying to do something cute, like drawing annoying things > onto a game that he doesn't like. He wants hackery. > > -- > Tim Roberts, xxxxx@probo.com All of those statements are guesses. That nobody has provided any justification as to why this is a bad idea except trying to state "it's hard" while lacking any knowledge at all about the low level graphics subsystem of Windows means the conversation shouldn't be about why he's wanting to do what he wants to do, but why he can't seem to do it easily.
  Message 24 of 45  
10 May 17 17:47
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Who are you R0b0t1? What makes you say that "Nobody here has any idea how to do what you asked about."? What makes you say that "All of those statements are guesses." Do you think that anyone will believe such an ignorant and even completely wrong statement? You didn't even google my company name. You don't even seem to know or understand about my company's freeware product www.spacedesk.ph Thus you can't understand that our spacedesk driver is accessing frame buffers on all GPUs (NVidia, AMD and Intel). Seems that you can't understand either that it even simulates additional framebuffers which the GPU does not really have. Obviously you also don't know that our spacedesk WDDM filter hook driver is installed on millions of PCs worldwide. If I were you, I would apologize to the forum and to the public for telling them false and ignorant statements. Otherwise, how could anyone still take you for serious in the future? Only after such an apology, I might consider to give you the justification you are asking for. PS: That was only one small example of my personal background. I have written many more driver and graphics solutions in well known products worldwide. And I haven't even started mentioning the other contributors' background here... Have a nice day Marcel Ruedinger datronicsoft
  Message 25 of 45  
10 May 17 18:12
R0b0t1
xxxxxx@gmail.com
Join Date: 24 Mar 2017
Posts To This List: 35
Display driver check

On Wed, May 10, 2017 at 4:47 PM, <xxxxx@datronic.de> wrote: > Who are you R0b0t1? > What makes you say that "Nobody here has any idea how to do what you asked about."? > What makes you say that "All of those statements are guesses." > Do you think that anyone will believe such an ignorant and even completely wrong statement? > 1. I am R0b0t1. 2. The wild mass guessing. 3. He admitted some of them were guesses. For others, e.g. the intent behind hidogame's original question, must be speculation, because he left gaps in the information given. Or Mr. Roberts has ESP. There is nothing wrong with guessing, as long as it is reasonable, but really most of those statements are indirectly disparaging the OP. While it is my intent to have a reasonable discussion, if people are going to claim things without backing them up with facts and evidence I'm not entirely sure that is possible. To a certain extent I will accept things that look like opinion based on the credibility of the poster but for most of the comments in this thread that doesn't really matter because of what (comparatively little) I know of the OpenGL specification and how it relates to operating systems using a display device. > You didn't even google my company name. > You don't even seem to know or understand about my company's freeware product www.spacedesk.ph > Thus you can't understand that our spacedesk driver is accessing frame buffers on all GPUs (NVidia, AMD and Intel). > Seems that you can't understand either that it even simulates additional framebuffers which the GPU does not really have. > Obviously you also don't know that our spacedesk WDDM filter hook driver is installed on millions of PCs worldwide. > 1. I don't have any reason to care about your company, but I have visited some domains in this mailing list. 2. I don't care about your product. 3. How is that relevant? 4. How is that relevant? 5. How is that relevant? The last three sentences could be interesting, but based on my knowledge of how the graphics subsystem is handled GPU side those are all irrelevant to driving the screen directly in the way I mentioned. > If I were you, I would apologize to the forum and to the public for telling them false and ignorant statements. Otherwise, how could anyone still take you for serious in the future? > I'm not sure I owe the entire forum an apology. It was never my intent to single anyone out - I want to maintain my membership on the list, after all. > Only after such an apology, I might consider to give you the justification you are asking for. > I didn't ask for your consideration specifically. > PS: That was only one small example of my personal background. I have written many more driver and graphics solutions in well known products worldwide. And I haven't even started mentioning the other contributors' background here... > Don't rely on your position to claim you're important, use your position to provide the OP with useful information if you want to help. If you don't want to help, why bother posting? > Have a nice day > Marcel Ruedinger > datronicsoft > To the uninvolved parties and those who were merely responding to the Win32 API questions - none of what I said was really aimed at you, and if you want you can find other posts of mine on this list that mirror the sentiments in my most recent additions to this thread.
  Message 26 of 45  
10 May 17 18:35
M M
xxxxxx@hotmail.com
Join Date: 21 Oct 2010
Posts To This List: 717
Display driver check

From UM, get the window handle of the current desktop and draw on it. This is a simple solution that will actually work and while your software may still be branded malware for interfering with the user, it won?t immediately crash the machine and it will be vastly easier to write & debug Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10 From: xxxxx@gmail.com<mailto:xxxxx@gmail.com> Sent: May 10, 2017 3:16 AM To: Windows System Software Devs Interest List<mailto:xxxxx@lists.osr.com> Subject: RE:[ntdev] Display driver check I found that : https://www.youtube.com/watch?v=Tfh0ytz8S0k. Look at 6:00 you'll see that he draw a Pacman over all elements of the screen and if you look bit earlier you'll see that he done it but writing values to the memory. But, that is "out-dated" I'm looking for more "dated"/modern implementation of the same result. --- NTDEV is sponsored by OSR Visit the list online at: <http://www.osronline.com/showlists.cfm?list=ntdev> MONTHLY seminars on crash dump analysis, WDF, Windows internals and software drivers! Details at <http://www.osr.com/seminars> To unsubscribe, visit the List Server section of OSR Online at <http://www.osronline.com/page.cfm?name=ListServer> --
  Message 27 of 45  
10 May 17 18:56
M M
xxxxxx@hotmail.com
Join Date: 21 Oct 2010
Posts To This List: 717
Display driver check

This post is irrelevant. Getting the display output is fine, but modifying it is not supported under any circumstance. Certainly it will never work on a headless server and will be problematic at best on multi-monitor and RDI configurations. The OP can achieve what he is looking to do by painting directly to the current desktop window from UM using a trivial application. If he uses a simple timer loop, the race conditions become irrelevant too. We are not talking about synchronizing access to critical data structures, but rather a ?get my pixels on top? problem. When the UM process runs under the same security context, and considers non-trivial clipping regions, these problems essentially go away. This is clearly malware if it runs on anyone but the OP?s desktop, so I don?t see how you can dispute Tim?s statements. The only possible exception is if it is some kind of admin tool to show the status of a machine in real time ? and in that case, the admins in question will have agreed to install and run it. Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10 From: R0b0t1<mailto:xxxxx@gmail.com> Sent: May 10, 2017 5:01 PM To: Windows System Software Devs Interest List<mailto:xxxxx@lists.osr.com> Subject: Re: [ntdev] Display driver check On Wed, May 10, 2017 at 3:44 PM, Tim Roberts <xxxxx@probo.com> wrote: > xxxxx@datronic.de wrote: >> Well, you decided to delve into beginner level Windows application programming here. Subsequently the following questions arise immediately: >> How would this approach synchronize with Desktop being redrawn by Windows? > > It would synchronize in exactly the same way as the > draw-directly-on-the-frame-buffer hackery that he proposed in the first > place, which is to say "not at all". The original poster is laboring > under the misconception that the hackery he wants to do must be done > from kernel mode. That is utterly false, as my code demonstrates. It's > still hackery, but it works. <...excess quoted lines suppressed...> I really think all of this is irrelevant. The display output is available directly from a graphics card via OpenGL. The question then becomes "how do you obtain the root framebuffer from the Windows kernel?" >> Was this a good advice to solve the OP's problem? > > Got a better idea? The OP's problem cannot be solved in the way he > wants to solve it. I'm fairly confident that this is not a commercial > enterprise trying to innovate solutions to a new problem. This is an > individual trying to do something cute, like drawing annoying things > onto a game that he doesn't like. He wants hackery. > > -- > Tim Roberts, xxxxx@probo.com All of those statements are guesses. That nobody has provided any justification as to why this is a bad idea except trying to state "it's hard" while lacking any knowledge at all about the low level graphics subsystem of Windows means the conversation shouldn't be about why he's wanting to do what he wants to do, but why he can't seem to do it easily. --- NTDEV is sponsored by OSR Visit the list online at: <http://www.osronline.com/showlists.cfm?list=ntdev> MONTHLY seminars on crash dump analysis, WDF, Windows internals and software drivers! Details at <http://www.osr.com/seminars> To unsubscribe, visit the List Server section of OSR Online at <http://www.osronline.com/page.cfm?name=ListServer> --
  Message 28 of 45  
10 May 17 19:13
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

@ R0b0t1: Very funny - Above you complain about other peoples' statements which are not backed by facts. And at the same time you admit that your own statements against other people are a wild guess and not backed by anything - NO MORE COMMENT! BTW: Don't worry - I have no authority to remove anyone from this list. It was only my natural feeling for common sense and code of conduct. @ M M + Tim Roberts Yes, of course this approach is 10,000 times better than a driver. Still it is difficult or even impossible to properly synchronize Desktop updates by Windows itself. Have you e.g. considered UAC screens? That's why I originally suggested AlwaysOnTop Windows. These can exactly mimic DirectX sprites (which were in the focus of OP's video). I even know products which used this to simulate additional mouse pointers. Marcel Ruedinger datronicsoft
  Message 29 of 45  
10 May 17 20:24
Tim Roberts
xxxxxx@probo.com
Join Date: 28 Jan 2005
Posts To This List: 11455
Display driver check

xxxxx@datronic.de wrote: > @ M M + Tim Roberts > Yes, of course this approach is 10,000 times better than a driver. > Still it is difficult or even impossible to properly synchronize Desktop updates by Windows itself. > Have you e.g. considered UAC screens? > That's why I originally suggested AlwaysOnTop Windows. > These can exactly mimic DirectX sprites (which were in the focus of OP's video). These are good points, and I do appreciate your experience in this thread. The problem we have here is the classic "wings on a pig" issue. The poster has concluded that the solution to his problem requires very specific tactic X, and has asked us how to provide tactic X, without telling us what his larger problem is. If he can give us more details about what he is REALLY trying to do, then we can either point him towards a hack solution, or suggest production-worthy methods that would be a LOT more work. -- Tim Roberts, xxxxx@probo.com Providenza & Boekelheide, Inc.
  Message 30 of 45  
11 May 17 00:12
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

No, no, no! This is NOT the classic "wings on a pig" problem and you know it. Even you tended to loose your patience here. The task is simple and precisely specified. The solution is similarly simple. The problem in this thread is the approach how to overcome the own lack of skills. We see two different approaches here: (1.) I am going to the Gym. I am too weak to lift 20 kilos. That's why I will now go lift 200 kilos. Translated: I demonstrated publicly that I don't have the skill to write 50 lines of simplest Windows application code. That's why I now ask again how to write 10,000 lines of extremely difficult Windows driver code. (2.) I am going to the Gym. I am too weak to lift 20 kilos. All the people in the gym are incompetent because they cannot make me lift 200 kilos. Translated: I demonstrate publicly that I don't have the skills and I write confusing, unorganized posts with many statements wrong or even contradicting each other. Then I make false blame on other people instead of trying to ask qualified questions and taking own effort and responsibility. Telling the larger picture won't help in any one of these cases either. At least (1.) still has a chance to eventually achieve a solution. He seems to try for himself instead of blaming others. He seems to be serious and he is trying to ask qualified questions. If he will invest substantial patience and time to acquire the necessary basic skills then he can eventually learn how to lift the 20 kilos first. Then he might be able to ask good enough questions so that someone can REALLY help him. Marcel Ruedinger datronicsoft
  Message 31 of 45  
11 May 17 03:22
Peewe Be
xxxxxx@gmail.com
Join Date: 09 May 2017
Posts To This List: 9
Display driver check

Hello everyone, first of all thank you all you are very good people that want to help me and I'm extremely appreciate that! now, I saw a lot of "fights" that I'm really sorry that happened - That wasn't my intent. @ Tim : I didn't tell my bigger problem because the isn't bigger problem all I just want to do is : To be able to print red screen or pictures on the display for exactly 1 frame and than back to the original display. The main purpose is to create subliminal screen ( I know 1 frame at Hz won't be 100% subliminal ) which will showed for 1 frame every ~500 ms. @ Anyone who said I should doing it in Application : I already did it. In OpenGL and DirectX. Those application destroyed the subliminality of the main goal because if I make my window full screen,transparent and alwaysontop then user can't do nothing, and even if I could to pass the clicks to the under screen, my screen will loose his focus and the user won't see the red screen/pictures. assumptions : 1. I need it to work on Intel Graphics 530 and only the current version I don't care for next version support. I wanna make an experiment and that's it. 2. I need it to be on Windows because as you all know Windows run on ~90% of the computers. 3. I don't care if it will be in user/kernel mode AS LONG AS IT FULFILL MY GOAL! I'm not an organization, I'm a researcher. I understand that what I asked is very difficult that's why I came here to ask you guys. If you will told me that it's nearly impossible I'll think about Linux solutions. Thank you all again, I'll be here for farther questions if needed. Have a nice day !
  Message 32 of 45  
11 May 17 06:24
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

My initial suggestion remains the same: Simple application (I didn't even say DirectX nor or OpenGL). Mouse click problem can be solved by Windows application programming technique called "Hooks". The only new problem you are mentioning now: Synchronize with frames of underlying application or Windows. This cannot fully nor cleanly be solved by the approach above. Synchronizing with underlying frame rate needs hooking of DirectX application which owns the display (Desktop Window Manager or other full screen DirectX application) and possibly even additional hooking of windowed DirectX and OpenGL applications. This can be achieved using a product called "Microsoft Detours" or similar open source hook products. This is e.g. how a well known tool called FRAPS is working. You might however be blocked by malware protection and by cheat prevention of certain games. You can find many graphics or gaming forums which tell you exactly how to do this in detail. Now after all, we don't want to forget that this is a Windows driver developer forum. Time to say good bye again. Thanks for the nice video. Brought back old memories... Marcel Ruedinger datronicsoft
  Message 33 of 45  
12 May 17 05:22
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Just to ensure that serious engineers are not mislead by an amazing set of wrong statements. "Windows kernel architecture seems to mirror Linux kernel architecture" => Couldn't be more wrong. Obviously not even read the basic Windows architecture book "Inside Windows 6th edition". "If you want to interface with the graphics card, you should probably look at ...OpenGL...cross platform..." => Couldn't be more wrong. All windows operating system components (e.g. Desktop Windows Manager) use DirectX. Using OpenGL on Windows systems always has certain limitations compared to DirectX. "...These framebuffers have no associated display. => Couldn't be more wrong. Obviously not even looked at Google or Wikipedia for the definition of framebuffer. Obviously not even able to distinguish concepts of frame buffer and "Primary Surface" (concept exists in Open GL too). "...is one framebuffer, normally claimed by the OS, that is tied to the display output." => Couldn't be more wrong. Obviously not even familiar with the most fundamental concept of DirectX screen presentation: Swapchains. There are at least two primary surfaces which are flipped upon every screen presentation operation. Never ever is there only one Primary Surface tied to the display output (except on old Windows 7 NON-AERO themes). "...If you can claim this framebuffer and set it up then you control the video output for the computer at the lowest level possible." => Couldn't be more wrong. The video output switches different primary surfaces many times in a second. "Claiming" one wouldn't help at all. Even "claiming" all wouldn't help because there are another concept called "overlays" and "multi plane overlays". Apart from the fact that they cannot be "claimed" because they belong to the display manufacturer's WDDM driver anyway. ...I could go on for hours... @R0b0t1: You are not even brave enough to show your real name (which all serious contributors here do) and you refused to apologize. I can only repeat now: If I were you, I would immediately apologize now to the forum and to the public. In case you still cannot understand the reasons: 1. Bad behaviour trying to discredit serious engineers for alledgedly not backing their statements. 2. Making desastrously incompetent false engineering statements yourself (some people even have a different word for making false statements - they call it "lying").
  Message 34 of 45  
12 May 17 11:18
Peter Viscarola (OSR)
xxxxxx@osr.com
Join Date:
Posts To This List: 5857
List Moderator
Display driver check

@R0b0t1: I gotta tell you... you really ARE trying my patience. Mr. Ruedinger Is a respected dev... you are an unidentified non-entity, due to your lack of a real name, organizational affiliation, and corporate email address. Don't bait the bear, R0b0t1. Unlike the MSFT-owned forums, we don't have to put up with stupid shit on this list to molllfy customers or public shareholders. I appreciate that you're trying to contribute. That's good. You're brining your own perspective. That's helpful. Just provide the appropriate level of respect to the people on this list that have long earned it, please. Peter OSR @OSRDrivers (Note: real name, company affiliation, corporate email address, twitter handle)
  Message 35 of 45  
12 May 17 20:12
M M
xxxxxx@hotmail.com
Join Date: 21 Oct 2010
Posts To This List: 717
Display driver check

I?m glad you agree with this approach, but I?m sure that you realize that always on top windows will have effectively the same behaviour as directly drawing on the desktop. UAC screens and other effects like locking the desktop, fast user switching etc. Don?t really come into it as long as one is working entirely in UM and never changing the graphics mode (a la classic GDI or GDI+ calls only) Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10 From: xxxxx@datronic.de<mailto:xxxxx@datronic.de> Sent: May 10, 2017 7:12 PM To: Windows System Software Devs Interest List<mailto:xxxxx@lists.osr.com> Subject: RE:[ntdev] Display driver check @ R0b0t1: Very funny - Above you complain about other peoples' statements which are not backed by facts. And at the same time you admit that your own statements against other people are a wild guess and not backed by anything - NO MORE COMMENT! BTW: Don't worry - I have no authority to remove anyone from this list. It was only my natural feeling for common sense and code of conduct. @ M M + Tim Roberts Yes, of course this approach is 10,000 times better than a driver. Still it is difficult or even impossible to properly synchronize Desktop updates by Windows itself. Have you e.g. considered UAC screens? That's why I originally suggested AlwaysOnTop Windows. These can exactly mimic DirectX sprites (which were in the focus of OP's video). I even know products which used this to simulate additional mouse pointers. Marcel Ruedinger datronicsoft --- NTDEV is sponsored by OSR Visit the list online at: <http://www.osronline.com/showlists.cfm?list=ntdev> MONTHLY seminars on crash dump analysis, WDF, Windows internals and software drivers! Details at <http://www.osr.com/seminars> To unsubscribe, visit the List Server section of OSR Online at <http://www.osronline.com/page.cfm?name=ListServer> --
  Message 36 of 45  
12 May 17 20:20
M M
xxxxxx@hotmail.com
Join Date: 21 Oct 2010
Posts To This List: 717
Display driver check

Well, then you did it wrong in UM. First, ignore Directx etc. As you certainly do not want to run your own full screen app. Second, reread the previous posts. Without going into a lot of details, it is quite possible to draw on top without interfering with the keyboard and mouse input to other applications. Even if you choose to resort to capturing all input and forwarding it to the correct window, this need not change the z-order and cause your graphics to be invisible. All of the suggestions have limitations. As you are a researcher, this should be good for you as you can describe them I your conclusions. Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10 From: xxxxx@gmail.com<mailto:xxxxx@gmail.com> Sent: May 11, 2017 3:22 AM To: Windows System Software Devs Interest List<mailto:xxxxx@lists.osr.com> Subject: RE:[ntdev] Display driver check Hello everyone, first of all thank you all you are very good people that want to help me and I'm extremely appreciate that! now, I saw a lot of "fights" that I'm really sorry that happened - That wasn't my intent. @ Tim : I didn't tell my bigger problem because the isn't bigger problem all I just want to do is : To be able to print red screen or pictures on the display for exactly 1 frame and than back to the original display. The main purpose is to create subliminal screen ( I know 1 frame at Hz won't be 100% subliminal ) which will showed for 1 frame every ~500 ms. @ Anyone who said I should doing it in Application : I already did it. In OpenGL and DirectX. Those application destroyed the subliminality of the main goal because if I make my window full screen,transparent and alwaysontop then user can't do nothing, and even if I could to pass the clicks to the under screen, my screen will loose his focus and the user won't see the red screen/pictures. assumptions : 1. I need it to work on Intel Graphics 530 and only the current version I don't care for next version support. I wanna make an experiment and that's it. 2. I need it to be on Windows because as you all know Windows run on ~90% of the computers. 3. I don't care if it will be in user/kernel mode AS LONG AS IT FULFILL MY GOAL! I'm not an organization, I'm a researcher. I understand that what I asked is very difficult that's why I came here to ask you guys. If you will told me that it's nearly impossible I'll think about Linux solutions. Thank you all again, I'll be here for farther questions if needed. Have a nice day ! --- NTDEV is sponsored by OSR Visit the list online at: <http://www.osronline.com/showlists.cfm?list=ntdev> MONTHLY seminars on crash dump analysis, WDF, Windows internals and software drivers! Details at <http://www.osr.com/seminars> To unsubscribe, visit the List Server section of OSR Online at <http://www.osronline.com/page.cfm?name=ListServer> --
  Message 37 of 45  
12 May 17 22:01
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Wrong: UAC screens and other effects like locking the desktop, fast user switching etc. Don't really come into it as long as one is working entirely in UM and never changing the graphics mode (a la classic GDI or GDI+ calls only). As an example, just write a simple Windows application. Then see what happens when it is trying to get a handle to the Desktop Device Context while UAC screen is showing. Wrong: First, ignore DirectX etc. As you certainly do not want to run your own full screen app. Reread my previous post which said that you need DirectX API hooking if you want to synchronize with underlying framerate. The only thing I missed: I forgot to insert the word "API" when I mentioned API hooking. Thought that this was obvious since I mentioned Microsoft Detours (well known API hooking product). Enjoying to take this further to any level of detail you like, as long as nobody will complain about "off-topic" discussion. Marcel Ruedinger datronicsoft
  Message 38 of 45  
12 May 17 22:17
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Just to avoid further misunderstandings upfront: I was talking about two completely different kinds of "hooks" above. 1. Windows programming technique called "Hooks" (specifically: WH_KEYBOARD_LL WH_MOUSE_LL) 2. API hooking of DirectX applications which own the Display in fullscreen mode (e.g. Desktop Windows Manager) or DirectX applications which show on the display in Windowed mode (if needed to synchronize with the frame rate) Marcel Ruedinger datronicsoft
  Message 39 of 45  
13 May 17 11:36
N. W.
xxxxxx@outlook.com
Join Date: 04 May 2017
Posts To This List: 27
Display driver check

>I wanna to be able to communicate directly with the GPU and display things on the monitor… It is said that GPUs are more powerful then CPUs. That’s why some want to exploit their computing power for doing other things than drawing. To do so they use programming languages provided by graphic card manufacturers to pass « commands » to the GPU. For NVIDIA, this is called CUDA. https://en.m.wikipedia.org/wiki/CUDA W. N.
  Message 40 of 45  
13 May 17 12:54
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

You quote: "I wanna to be able to communicate directly with the GPU and DISPLAY THINGS ON THE MONITOR" Then you introduce CUDA which does OTHER THINGS THAN DRAWING. You did not answer the question you are quoting. Nor did anyone here ask for technologies to use GPUs for OTHER THINGS THAN DRAWING. Nor is CUDA a technology which would be discussed here in a Windows kernel development newsgroup. This thread is so full of wrong information (R0b0t1). Please do not add any useless information to it - thank you! Marcel Ruedinger datronicsoft
  Message 41 of 45  
13 May 17 13:47
N. W.
xxxxxx@outlook.com
Join Date: 04 May 2017
Posts To This List: 27
Display driver check

With all due respect Mr Ruedinger, please stop your inquisition. Here is a document published by NVIDIA, titled "What every CUDA programmer should know about OpenGL" where it is explained that programmers can use both CUDA and OpenGL to do graphics. Here is an excerpt: 1- CUDA was created to expose the GPU’s powerful parallel processing capabilities without any Graphics knowledge or experience. 2- It’s a success! And now there are 10,000’s of new GPU programmers. 3- But GPUs can still do graphics… so let’s use this capability for visualization. The document can be downloaded here: http://www.nvidia.com/content/gtc/documents/1055_gtc09.pdf Please, Mr Ruedinger, provide useful information or stop posting. 😉 W. N.
  Message 42 of 45  
13 May 17 14:12
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Ha ha ha, at least not only spamming the forum, but awarding me with a great title. I love it! THE INQUISITOR Engineers worldwide - be careful! Don't tell bullshit or THE INQUISITOR will come after you... ROFL Marcel Ruedinger datronicsoft
  Message 43 of 45  
13 May 17 14:26
N. W.
xxxxxx@outlook.com
Join Date: 04 May 2017
Posts To This List: 27
Display driver check

Yes, NVIDIA engineers would love your words. Now that you are disrespectful, you no longer diserve respect. Sorry about that but you need to change your behaviour. This will be my last comment on this thread. Hope the OP will find my humble contribution useful. W. N.
  Message 44 of 45  
13 May 17 14:37
Marcel Ruedinger
xxxxxx@datronic.de
Join Date: 01 Nov 2010
Posts To This List: 93
Display driver check

Amazing - getting funnier and funnier... Now he is even starting to speak for Nvidia... PS1: I DO personally know Nvidia engineers and they did always like my words indeed. PS2: You didn't read the list rules prohibiting commercial product advertisement (THE INQUISITOR calling again ;-). Marcel Ruedinger datronicsoft
  Message 45 of 45  
13 May 17 15:24
Peter Viscarola (OSR)
xxxxxx@osr.com
Join Date:
Posts To This List: 5857
List Moderator
Display driver check

Chill people. That mean you too, Mr. Ruedinger. Please. In fact, I think this thread has ceased to be useful, so I'm going to go ahead and lock it lest we continue use to stray. Peter OSR @OSRDrivers
Posting Rules  
You may not post new threads
You may not post replies
You may not post attachments
You must login to OSR Online AND be a member of the ntdev list to be able to post.

All times are GMT -5. The time now is 03:12.


Copyright ©2015, OSR Open Systems Resources, Inc.
Based on vBulletin Copyright ©2000 - 2005, Jelsoft Enterprises Ltd.
Modified under license