几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   DirectDWG (http://www.dimcax.com/hust/forumdisplay.php?f=89)
-   -   【转帖】setviewportclip (http://www.dimcax.com/hust/showthread.php?t=18571)

yang686526 2009-05-07 03:50 PM

【转帖】setviewportclip
 
setviewportclip
setviewportclip
hello.
in my application, i let setviewportclip() not be excuted.
then windirectx module couldn't draw anymore.
by the way, as i made onsize() excuted each time before drawing, it went well.
what is the functionality of setviewportclip()?

the functionality of exgsdirectxview::setviewportclip is
1. initialize a stencil-buffer
2. clear a z-buffer
3. fills a frame-buffer in accordance with viewport background settings.
if you don't call setviewportclip, directx device may stop render, e.g., because stencil test is turned on, but stencil buffer is not initialized. or because z-buffer is not clean. quite strange to comment out some piece of code and expect that everything will continue to be working
sincerely yours,
george udov


所有的时间均为北京时间。 现在的时间是 06:26 PM.