E:\Visual_C__MFC擴展編程實例 例18
動態地抓取應用程序的屏幕圖像并將其打印。
上一個實例打印的是文檔的報表,而不是當前出現在屏幕上的內容。在本例中,將實現
屏幕抓取并打印其內容。M F C 為打印視提供了有限的支持, 但只要用M F C 在
C Vi e w : : O n D r a w ( )中所提供的設備環境,就可以繪制自己的視。在打印視的時候, M F C只需調
用具備打印機設備環境的O n D r a w ( )函數即可。但是,如果不繪制自己的視,例如,用一個或
者一個以上的控件窗口填充自己的視就不會打印任何東西。每個控件將使用自己的設備環境
將自己打印到屏幕,因此打印視的唯一途徑就是抓取屏幕(拷貝其內容到一個位圖對象)并將其
打印到打印機。由于該功能整個與位圖相關,因此將該功能封裝到了位圖類中。
acm HDOJ 1051WoodenSticks
Description:
There is a pile of n wooden sticks. The length and weight of each stick are known in advance. The sticks are to be processed by a woodworking machine in one by one fashion. It needs some time, called setup time, for the machine to prepare processing a stick. The setup times are associated with cleaning operations and changing tools and shapes in the machine. The setup times of the woodworking machine are given as follows:
(a) The setup time for the first wooden stick is 1 minute.
(b) Right after processing a stick of length l and weight w , the machine will need no setup time for a stick of length l and weight w if l<=l and w<=w . Otherwise, it will need 1 minute for setup.
This designs uses a Nios II system to demonstrate how to read from the SD card. The software reads WAV files from the SD card and plays it through the LINE OUT line. Simply put a SD card into the slot on the board and connect some speakers to the LINE OUT port.Preparing the SD card
This book has been updated for the new Java version, J2SE 5.0, and works its way through a project with requirements and structure similar to the project you ll encounter in the SCJD exam
The Game:
Make the snake grow longer by directing it to the food.
Extra bonus points are given from hearts, eat them as fast as possible as amount of bonus points decreases with time.
Higher level gives more points for the food but will also make it tougher to steer a long snake as speed increaces.
Five different mazes as well as play w/o maze are possible.
DOSBox emulates a full x86 pc with sound and dos. Its main use is to run old dosgames on platforms which don t have dos(win2K/XP/linux/FreeBSD/Mac OS X)