Home > Software engineering >  Can Direct2D in RenderTarget Clear a PathGeometry?
Can Direct2D in RenderTarget Clear a PathGeometry?

Time:09-21

Just like using a GraphicsPath Gdi + to SetClip, then Clear, but the RenderTarget PushAxisAlignedClip can only set the rectangular area,

CodePudding user response:

Didn't quite understand your meaning, what do you want to achieve a specific function

CodePudding user response:

reference 1st floor oblivi response:
didn't quite understand your meaning, what do you want to achieve a specific function

Is to generate a Geometry, and then Clear the area of the Geometry record, say simple point is Clear a specified area of any shape

CodePudding user response:

Space camera is a four trustum of a pyramid,

CodePudding user response:

The Boolean operation reference AutoCAD 3 d arbitrary shape or 3 ds Max Studio or Maya or... Popular 3 d software comes, the features of the related

CodePudding user response:

Direct2D did not fill the Region that directly, you can use GDI and GDI + graphics drawing first, then hand over the DC
 HDC HDC=GetDC (hWnd); 
HDC memDC=CreateCompatibleDC (HDC);
. MemDC... Do something...
ID2D1DCRenderTarget * g_pDCRT;
G_pDCRT - & gt; BindDC (memDC, & amp; CRect (... ));

CodePudding user response:

reference 5 floor oblivi reply:
Direct2D did not fill the Region that directly, you can use the GDI and GDI + the graphics drawing first, then hand over the DC
 HDC HDC=GetDC (hWnd); 
HDC memDC=CreateCompatibleDC (HDC);
. MemDC... Do something...
ID2D1DCRenderTarget * g_pDCRT;
G_pDCRT - & gt; BindDC (memDC, & amp; CRect (... ));

Thanks, D2D and gdi I know/gid + mixed programming, can really achieve the gdi and gdi + can do everything, but with the D2D is to enjoy the hardware acceleration, this post I want to know if can do is use D2D itself

CodePudding user response:

There had not been fillgeometry d2d?

CodePudding user response:

refer to 7th floor WJN92 response:
d2d fillgeometry isn't is?

It is not to fill, is to be Clear, the fill will be only one color with the color of the original in rt to fusion, the Clear is to use a new color to cover the original color, including the alpha channel

CodePudding user response:

refer to the eighth floor solomonlxd response:
Quote: refer to 7th floor WJN92 response:

There had not been fillgeometry d2d?

It is not to fill, is to be Clear, the fill will be only one color with the color of the original in rt to fusion, the Clear is to use a new color to cover the original color, including the alpha channel


The alpha is set to 1.0 no?

CodePudding user response:

references 9 f WJN92 response:
Quote: refer to the eighth floor solomonlxd response:

Quote: refer to 7th floor WJN92 response:

There had not been fillgeometry d2d?

It is not to fill, is to be Clear, the fill will be only one color with the color of the original in rt to fusion, the Clear is to use a new color to cover the original color, including the alpha channel



The alpha is set to 1.0 no?


Because to do layered window, background need to be transparent, must use any alpha color to clear

CodePudding user response:

The Clear can only be rectangular
  • Related