44 if (((pts[
i].
x + 0x8000) & ~0xffff) || ((pts[
i].
y + 0x8000) & ~0xffff))
59 dest_short[
i].
x = pts[
i].
x;
60 dest_short[
i].
y = pts[
i].
y;
62 return dest_short +
count;
146 DC *
dc = get_physdev_dc(
dev );
148 struct gdi_path *
path;
159 free_gdi_path(
path );
192 DC *
dc = get_physdev_dc(
dev );
231 DC *
dc = get_physdev_dc(
dev );
234 double angleStart, angleEnd;
235 double xinterStart, yinterStart, xinterEnd, yinterEnd;
274 angleStart =
atan2( -(
double)ystart, (
double)xstart);
275 angleEnd =
atan2( -(
double)yend, (
double)xend);
279 xinterStart = (
right -
left + 1)/2 *
cos(angleStart) + xCentre;
280 yinterStart = -(
bottom -
top + 1)/2 *
sin(angleStart) + yCentre;
281 xinterEnd = (
right -
left + 1)/2 *
cos(angleEnd) + xCentre;
282 yinterEnd = -(
bottom -
top + 1)/2 *
sin(angleEnd) + yCentre;
284 if(angleStart < 0) angleStart += 2 *
M_PI;
285 if(angleEnd < 0) angleEnd += 2 *
M_PI;
286 if(angleEnd < angleStart) angleEnd += 2 *
M_PI;
288 bounds.
left =
min(xinterStart, xinterEnd);
289 bounds.
top =
min(yinterStart, yinterEnd);
290 bounds.
right =
max(xinterStart, xinterEnd);
291 bounds.
bottom =
max(yinterStart, yinterEnd);
293 for(
i = 0;
i <= 8;
i++) {
294 if(
i *
M_PI / 2 < angleStart)
296 if(
i *
M_PI / 2 > angleEnd)
320 if(bounds.
left > xCentre) bounds.
left = xCentre;
321 else if(bounds.
right < xCentre) bounds.
right = xCentre;
322 if(bounds.
top > yCentre) bounds.
top = yCentre;
323 else if(bounds.
bottom < yCentre) bounds.
bottom = yCentre;
412 DC *
dc = get_physdev_dc(
dev );
451 DC *
dc = get_physdev_dc(
dev );
491 DC *
dc = get_physdev_dc(
dev );
556 DC *
dc = get_physdev_dc(
dev );
645 for(poly = 0; poly < polys; poly++) {
646 cptl += counts[poly];
647 if(counts[poly] < 2) bounds_valid =
FALSE;
649 if(!cptl) bounds_valid =
FALSE;
664 if(bounds_valid && !physDev->
path)
678 if(
ret && !bounds_valid)
756 emr.
iMode = fillType;
888 DC *
dc = get_physdev_dc(
dev );
899 const UINT textAlign =
dc->textAlign;
900 const INT graphicsMode =
dc->GraphicsMode;
902 FLOAT exScale, eyScale;
916 SIZE wndext, vportext;
920 exScale = 100.0 * ((
FLOAT)horzSize / (
FLOAT)horzRes) /
922 eyScale = 100.0 * ((
FLOAT)vertSize / (
FLOAT)vertRes) /
958 textWidth += lpDx[
i];
961 textHeight = strSize.
cy;
970 textWidth += charSize.
cx;
971 textHeight =
max(textHeight, charSize.
cy);
1037 ULONG i,
pt,
size, num_pts = ngrad * (
mode == GRADIENT_FILL_TRIANGLE ? 3 : 2);
1038 const ULONG *pts = (
const ULONG *)grad_array;
1044 if (!emr)
return FALSE;
1046 for (
i = 0;
i < num_pts;
i++)
1057 if (vert_array[
pt].x < emr->rclBounds.left)
1061 if (vert_array[
pt].y < emr->rclBounds.top)
1075 memcpy( emr->
Ver, vert_array, nvert *
sizeof(vert_array[0]) );
1076 memcpy( emr->
Ver + nvert, pts, num_pts *
sizeof(pts[0]) );
_STLP_DECLSPEC complex< float > _STLP_CALL cos(const complex< float > &)
_STLP_DECLSPEC complex< float > _STLP_CALL sin(const complex< float > &)
valarray< _Tp > atan2(const valarray< _Tp > &__x, const valarray< _Tp > &__y)
char ACPI_OBJECT_TYPE * Types
static const char * wine_dbgstr_rect(const RECT *prc)
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define ERROR_INVALID_PARAMETER
#define HeapFree(x, y, z)
GLint GLint GLint GLint GLint x
GLuint GLuint GLsizei GLenum type
GLint GLint GLint GLint GLint GLint y
GLuint GLuint GLsizei count
GLint GLint GLsizei GLsizei height
GLint GLint GLsizei width
GLdouble GLdouble GLdouble GLdouble top
GLsizei const GLfloat * points
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define memcpy(s1, s2, n)
static const unsigned char enhmetafile[]
#define offsetof(TYPE, MEMBER)
#define FIELD_OFFSET(t, f)
BOOL EMFDRV_PaintRgn(PHYSDEV dev, HRGN hrgn)
BOOL EMFDRV_PolyDraw(PHYSDEV dev, const POINT *pts, const BYTE *types, DWORD count)
static BOOL EMFDRV_Polylinegon(PHYSDEV dev, const POINT *pt, INT count, DWORD iType)
BOOL EMFDRV_FillRgn(PHYSDEV dev, HRGN hrgn, HBRUSH hbrush)
static BOOL EMFDRV_PolyPolylinegon(PHYSDEV dev, const POINT *pt, const INT *counts, UINT polys, DWORD iType)
BOOL EMFDRV_Pie(PHYSDEV dev, INT left, INT top, INT right, INT bottom, INT xstart, INT ystart, INT xend, INT yend)
BOOL EMFDRV_FillPath(PHYSDEV dev)
BOOL EMFDRV_Polyline(PHYSDEV dev, const POINT *pt, INT count)
static BOOL EMFDRV_PaintInvertRgn(PHYSDEV dev, HRGN hrgn, DWORD iType)
static void * store_points(POINTL *dest, const POINT *pts, UINT count, BOOL short_points)
BOOL EMFDRV_ArcTo(PHYSDEV dev, INT left, INT top, INT right, INT bottom, INT xstart, INT ystart, INT xend, INT yend)
BOOL EMFDRV_FrameRgn(PHYSDEV dev, HRGN hrgn, HBRUSH hbrush, INT width, INT height)
BOOL EMFDRV_RoundRect(PHYSDEV dev, INT left, INT top, INT right, INT bottom, INT ell_width, INT ell_height)
static const RECTL empty_bounds
COLORREF EMFDRV_SetPixel(PHYSDEV dev, INT x, INT y, COLORREF color)
BOOL EMFDRV_InvertRgn(PHYSDEV dev, HRGN hrgn)
BOOL EMFDRV_GradientFill(PHYSDEV dev, TRIVERTEX *vert_array, ULONG nvert, void *grad_array, ULONG ngrad, ULONG mode)
static BOOL EMFDRV_ArcChordPie(PHYSDEV dev, INT left, INT top, INT right, INT bottom, INT xstart, INT ystart, INT xend, INT yend, DWORD iType)
BOOL EMFDRV_PolyBezierTo(PHYSDEV dev, const POINT *pts, DWORD count)
BOOL EMFDRV_Chord(PHYSDEV dev, INT left, INT top, INT right, INT bottom, INT xstart, INT ystart, INT xend, INT yend)
static void get_points_bounds(RECTL *bounds, const POINT *pts, UINT count, DC *dc)
BOOL EMFDRV_ExtFloodFill(PHYSDEV dev, INT x, INT y, COLORREF color, UINT fillType)
BOOL EMFDRV_StrokeAndFillPath(PHYSDEV dev)
BOOL EMFDRV_MoveTo(PHYSDEV dev, INT x, INT y)
static BOOL can_use_short_points(const POINT *pts, UINT count)
BOOL EMFDRV_StrokePath(PHYSDEV dev)
BOOL EMFDRV_PolyBezier(PHYSDEV dev, const POINT *pts, DWORD count)
BOOL EMFDRV_PolylineTo(PHYSDEV dev, const POINT *pt, INT count)
BOOL EMFDRV_AngleArc(PHYSDEV dev, INT x, INT y, DWORD radius, FLOAT start, FLOAT sweep)
BOOL EMFDRV_PolyPolygon(PHYSDEV dev, const POINT *pt, const INT *counts, UINT polys)
BOOL EMFDRV_LineTo(PHYSDEV dev, INT x, INT y)
BOOL EMFDRV_Polygon(PHYSDEV dev, const POINT *pt, INT count)
BOOL EMFDRV_Rectangle(PHYSDEV dev, INT left, INT top, INT right, INT bottom)
BOOL EMFDRV_ExtTextOut(PHYSDEV dev, INT x, INT y, UINT flags, const RECT *lprect, LPCWSTR str, UINT count, const INT *lpDx)
BOOL EMFDRV_Ellipse(PHYSDEV dev, INT left, INT top, INT right, INT bottom)
BOOL EMFDRV_PolyPolyline(PHYSDEV dev, const POINT *pt, const DWORD *counts, DWORD polys)
BOOL EMFDRV_Arc(PHYSDEV dev, INT left, INT top, INT right, INT bottom, INT xstart, INT ystart, INT xend, INT yend)
static BOOL emfdrv_stroke_and_fill_path(PHYSDEV dev, INT type)
*nSize LPSTR _Inout_ LPDWORD nSize
BOOL WINAPI GetTextMetricsW(_In_ HDC, _Out_ LPTEXTMETRICW)
int WINAPI GetDeviceCaps(_In_opt_ HDC, _In_ int)
UINT WINAPI GetTextAlign(_In_ HDC)
int WINAPI GetGraphicsMode(_In_ HDC)
BOOL WINAPI GetCurrentPositionEx(_In_ HDC, _Out_ LPPOINT)
#define EMR_STROKEANDFILLPATH
BOOL WINAPI GetWindowExtEx(_In_ HDC, _Out_ LPSIZE)
DWORD WINAPI GetRegionData(_In_ HRGN hrgn, _In_ DWORD nCount, _Out_writes_bytes_to_opt_(nCount, return) LPRGNDATA lpRgnData)
#define EMR_POLYPOLYLINE16
BOOL WINAPI GetViewportExtEx(_In_ HDC, _Out_ LPSIZE)
BOOL WINAPI GetTextExtentPoint32W(_In_ HDC hdc, _In_reads_(c) LPCWSTR lpString, _In_ int c, _Out_ LPSIZE psizl)
int WINAPI GetPath(_In_ HDC hdc, _Out_writes_opt_(cpt) LPPOINT apt, _Out_writes_opt_(cpt) LPBYTE aj, int cpt)