>From: “Jeffery Frazier”
>Reply-To: “Windows System Software Devs Interest List”
>
>To: “Windows System Software Devs Interest List”
>Subject: RE: [ntdev] DrvCreateDeviceBitmap() Question
>Date: Thu, 28 Jul 2005 14:19:31 -0400
>
>Erik,
>
>I don’t think that there is anything known as a user mode video driver.
>You
>don’t need a driver on the client machine, you can just draw in any window
>since you have the bitmaps. What I have read is that tracking the changes
>is the best way to go. If you are going to do this, implement all of the
>drawing operations and write the changes to a buffer, the user mode
>application on the server would take the screen changes and encode them and
>send them through the wire. You may be able to get a DrvEscape through a
>device bitmap since its type is HDC in user mode, but it isn’t going to buy
>you anything if you are trying to track the changes only.
>
>If you want to track changes you must implement:
>DrvAlphaBlend
>DrvBitBlt
>DrvCopyBits
>DrvFillPath
>DrvGradientFill
>DrvLineTo
>DrvPlgBlt
>DrvStretchBlt
>DrvStretchBltROP
>DrvStrokeAndFillPath
>DrvStrokePath
>DrvTextOut
>DrvTransparentBlt
>
>
>for each of these functions, punt back to the GDI. Then in the updated
>rectangle in the main surface, psoDest, copy the area that is updated into
>the buffer that you have allocated to store the drawing commands.
>
>Hope this helps,
>
>Jeff
>
>
>-----Original Message-----
>From: xxxxx@lists.osr.com
>[mailto:xxxxx@lists.osr.com]On Behalf Of Shaw, Erik (Xetron)
>Sent: Thursday, July 28, 2005 1:41 PM
>To: Windows System Software Devs Interest List
>Subject: RE:[ntdev] DrvCreateDeviceBitmap() Question
>
>
>Jeff,
> I guess I should have stated that this is two different drivers. The
>mirror driver on the server would collect these rendering commands, write
>them to a user-mode buffer, and this would be polled from a service that
>would send them out over the network as you said.
> On the client side, another driver would need to exist since I don’t
>have
>access to the EngXxx functions from user-mode (also see note below), I
>wanted to use DrvEscape on a bitmap in this driver (call it the rendering
>driver) so that I could invoke GDI to actually make these calls. If you are
>pretty sure DrvEscape won’t be called on even a Device bitmap, then I
>suppose I could figure out a way to just draw to the driver’s actual
>surface. I wasn’t planning on using the surface at all, I just figured it
>may be easier to use a bitmap.
> So do you think this design is really going to improve network traffic
>over sending the already-drawn screen change rectangles themselves? Do you
>think it is feasible?
>Erik
>
>Note: I found that some EngXxx functions ARE exported from GDI32.dll with
>the same names and parameter numbers, however, they take different
>parameter
>types that don’t seem to be available outside of Microsoft. These must be
>for user-mode video drivers or something? This isn’t something I knew
>existed.
>
>
>-----------------------------------------------------------
>X-Message-Number: 25
>X-lyris-Id: 78382
>Date: Thu, 28 Jul 2005 11:23:43 -0400
>From: “Jeffery Frazier”
>Subject: RE: DrvCreateDeviceBitmap() Question
>Erik,
>Actually I don’t think DrvEscape will be called with a device bitmap. If
>you only want to get the changes, you are going to have to know when and
>where a drawing call is made, so you will have to hook all of the drawing
>functions in the mirror driver. In each of these functions, you will have
>to write this change information to some buffer that can then be polled in
>user mode. Is this what you want to do? It seems like you want two
>different mutually exclusive things: access to the bitmap at all times and
>only wanting the changes to be sent. Which one are you actually wanting to
>do?
>Jeff
>
>
>Erik
>
>—
>Questions? First check the Kernel Driver FAQ at
>http://www.osronline.com/article.cfm?id=256
>
>You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
>To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>—
>Questions? First check the Kernel Driver FAQ at
>http://www.osronline.com/article.cfm?id=256
>
>You are currently subscribed to ntdev as: xxxxx@hotmail.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com
_________________________________________________________________
NRIs, does your family in India need money urgently?
http://creative.mediaturf.net/creatives/icicibank/ICICI_NRI_ERA.htm Open an
ICICI Bank NRI savings A/c
>From: “Jeffery Frazier”
>Reply-To: “Windows System Software Devs Interest List”
>
>To: “Windows System Software Devs Interest List”
>Subject: RE: [ntdev] DrvCreateDeviceBitmap() Question
>Date: Thu, 28 Jul 2005 11:23:43 -0400
>
>Erik,
>
>Actually I don’t think DrvEscape will be called with a device bitmap. If
>you only want to get the changes, you are going to have to know when and
>where a drawing call is made, so you will have to hook all of the drawing
>functions in the mirror driver. In each of these functions, you will have
>to write this change information to some buffer that can then be polled in
>user mode. Is this what you want to do? It seems like you want two
>different mutually exclusive things: access to the bitmap at all times and
>only wanting the changes to be sent. Which one are you actually wanting to
>do?
>
>Jeff
>
>
>-----Original Message-----
>From: xxxxx@lists.osr.com
>[mailto:xxxxx@lists.osr.com]On Behalf Of Shaw, Erik (Xetron)
>Sent: Thursday, July 28, 2005 10:29 AM
>To: Windows System Software Devs Interest List
>Subject: RE:[ntdev] DrvCreateDeviceBitmap() Question
>
>
>Hi Jeff,
> I do have the functions defined and DrvEscape is called for my surface
>when
>ExtEscape is called in user-mode for the surface’s HDC. I also wanted to
>create a bitmap in my driver that would be using the same interface.
> I was just going to use DrvEscape to get the SURFOBJ* to the bitmap and
>then replace the destination surface from each DrvXxx call seen in the
>mirror driver with the SURFOBJ* for my bitmap, then call the related EngXxx
>command. In this way the exact same image that is drawn on the screen will
>be drawn to my bitmap.
> Obviously, there is more difficulty involved in splitting this into a
>client and server (including recreating the objects referenced by some of
>the parameters on the client machine), but I think that this will be doable
>and hopefully cut down on the network traffic that would result from
>sending
>JPEGs of the screen change rectangles each time.
> What do you think?
>Erik
>
>
> > Date: Wed, 27 Jul 2005 11:42:43 -0400
> > From: “Jeffery Frazier”
> > Subject: RE: DrvCreateDeviceBitmap() Question
> >
> > Erik,
> >
> > make sure that you have { INDEX_DrvEscape, (PFN) DrvEscape }, defined in
>your function list and the function DrvEscape will be called whenever
>ExtEscape > is called inside your user application. are you sure that your
>mirror driver is being loaded? If my recollection serves, all ExtEscape
>calls, even
> > those destined for the original display driver, reach the mirror driver.
>What are you going to do with the surface object when you get it?
> > DrvEscape copies memory from User mode and places it in kernel mode and
>will do the reverse as well.
> >
> > Jeff
>
>—
>Questions? First check the Kernel Driver FAQ at
>http://www.osronline.com/article.cfm?id=256
>
>You are currently subscribed to ntdev as: unknown lmsubst tag argument: ‘’
>To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>—
>Questions? First check the Kernel Driver FAQ at
>http://www.osronline.com/article.cfm?id=256
>
>You are currently subscribed to ntdev as: xxxxx@hotmail.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com
_________________________________________________________________
Formula One fan? http://server1.msn.co.in/sp05/tataracing/ Get news,
wallpapers and photos of Narain Karthikeyan.
Shaw, Erik (Xetron) wrote:
Jeff,
I guess I should have stated that this is two different drivers. The
mirror driver on the server would collect these rendering commands,
write them to a user-mode buffer, and this would be polled from a
service that would send them out over the network as you said.On the client side, another driver would need to exist since I don’t
have access to the EngXxx functions from user-mode (also see note
below), I wanted to use DrvEscape on a bitmap in this driver (call it
the rendering driver) so that I could invoke GDI to actually make these
calls. If you are pretty sure DrvEscape won’t be called on even a Device
bitmap, then I suppose I could figure out a way to just draw to the
driver’s actual surface. I wasn’t planning on using the surface at all,
I just figured it may be easier to use a bitmap.
You could use the user-mode routines. Eventually, those map into the EngXXx
routines.
For example:
To do a EngAlphaBlend, use the AlphaBlend function exported by gdi32.dll.
You’ll have to translate some parameters, but other than that you should be fine.
Burk.
RE: DrvCreateDeviceBitmap() QuestionYou can associate your bitmap surface with the pdev when an entry point is hit and do the drawing on the bitmap. Once you are done with the drawing, you can reassociate the older surface before leaving the entry point.
Thanks
Vipin
“Shaw, Erik (Xetron)” wrote in message news:xxxxx@ntdev…
Hi Jeff,
I do have the functions defined and DrvEscape is called for my surface when ExtEscape is called in user-mode for the surface’s HDC. I also wanted to create a bitmap in my driver that would be using the same interface.
I was just going to use DrvEscape to get the SURFOBJ* to the bitmap and then replace the destination surface from each DrvXxx call seen in the mirror driver with the SURFOBJ* for my bitmap, then call the related EngXxx command. In this way the exact same image that is drawn on the screen will be drawn to my bitmap.
Obviously, there is more difficulty involved in splitting this into a client and server (including recreating the objects referenced by some of the parameters on the client machine), but I think that this will be doable and hopefully cut down on the network traffic that would result from sending JPEGs of the screen change rectangles each time.
What do you think?
Erik
> Date: Wed, 27 Jul 2005 11:42:43 -0400
> From: “Jeffery Frazier”
> Subject: RE: DrvCreateDeviceBitmap() Question
>
> Erik,
>
> make sure that you have { INDEX_DrvEscape, (PFN) DrvEscape }, defined in your function list and the function DrvEscape will be called whenever ExtEscape > is called inside your user application. are you sure that your mirror driver is being loaded? If my recollection serves, all ExtEscape calls, even
> those destined for the original display driver, reach the mirror driver. What are you going to do with the surface object when you get it?
> DrvEscape copies memory from User mode and places it in kernel mode and will do the reverse as well.
>
> Jeff