How to write a driver for virtual printer

强颜欢笑 提交于 2019-12-01 09:34:30

问题


I want to write a driver for virtual printer (in C++ or Java) (As explained in How to create a virtual printer in Windows?) I would redirect the file to a file server (again as explained in http://www.colorpilot.com/VirtualPrinterForCSharp2.html.

What are the fundamental building blocks of a printer driver ?

I have read about spooler and print monitor but I am not sure that these are all that I have to know!

Any guide or suggestion appreciated in advance!

Regards


回答1:


Most print redirection requirements are fulfilled using a Port Monitor. You dont need to do a printer driver because if you do that then this is more difficult to broadbase across end-users who may want to use their printer drivers, you will need to have drivers for each printer and so on.

http://pages.cs.wisc.edu/~ghost/redmon/ is a very good example of a redirection port monitor. Mostly written in C. Please look at the licensing agreements before you see how you can use it in your project.

There is also a sample port monitor in the Windows WDK (Windows Driver Kit) you could use a base reference.

Hope this helps. If so, please vote a +1 :)



来源:https://stackoverflow.com/questions/4640287/how-to-write-a-driver-for-virtual-printer

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!