Home | History | Annotate | Download | only in referencerenderer

Lines Matching refs:deInt64

31 inline deInt64 toSubpixelCoord (float v)
33 return (deInt64)(v * (1<<RASTERIZER_SUBPIXEL_BITS) + (v < 0.f ? -0.5f : 0.5f));
36 inline deInt64 toSubpixelCoord (deInt32 v)
41 inline deInt32 ceilSubpixelToPixelCoord (deInt64 coord, bool fillEdge)
49 inline deInt32 floorSubpixelToPixelCoord (deInt64 coord, bool fillEdge)
57 static inline void initEdgeCCW (EdgeFunction& edge, const HorizontalFill horizontalFill, const VerticalFill verticalFill, const deInt64 x0, const deInt64 y0, const deInt64 x1, const deInt64 y1)
61 const deInt64 xd = x1-x0;
62 const deInt64 yd = y1-y0;
84 static inline deInt64 evaluateEdge (const EdgeFunction& edge, const deInt64 x, const deInt64 y)
89 static inline bool isInsideCCW (const EdgeFunction& edge, const deInt64 edgeVal)
99 const tcu::Vector<deInt64,2> m_v0;
100 const tcu::Vector<deInt64,2> m_v1;
102 SubpixelLineSegment (const tcu::Vector<deInt64,2>& v0, const tcu::Vector<deInt64,2>& v1)
108 tcu::Vector<deInt64,2> direction (void) const
121 static tcu::Vector<deInt64,2> toSubpixelVector (const tcu::Vec2& v)
123 return tcu::Vector<deInt64,2>(toSubpixelCoord(v.x()), toSubpixelCoord(v.y()));
126 static tcu::Vector<deInt64,2> toSubpixelVector (const tcu::IVec2& v)
128 return tcu::Vector<deInt64,2>(toSubpixelCoord(v.x()), toSubpixelCoord(v.y()));
132 static bool isTheCenterOfTheFragment (const tcu::Vector<deInt64,2>& a)
150 static bool vertexOnLeftSideOfLine (const tcu::Vector<deInt64,2>& p, const SubpixelLineSegment& l)
152 const tcu::Vector<deInt64,2> u = l.direction();
153 const tcu::Vector<deInt64,2> v = ( p - l.m_v0);
154 const deInt64 crossProduct = (u.x() * v.y() - u.y() * v.x());
159 static bool vertexOnRightSideOfLine (const tcu::Vector<deInt64,2>& p, const SubpixelLineSegment& l)
161 const tcu::Vector<deInt64,2> u = l.direction();
162 const tcu::Vector<deInt64,2> v = ( p - l.m_v0);
163 const deInt64 crossProduct = (u.x() * v.y() - u.y() * v.x());
168 static bool vertexOnLine (const tcu::Vector<deInt64,2>& p, const SubpixelLineSegment& l)
170 const tcu::Vector<deInt64,2> u = l.direction();
171 const tcu::Vector<deInt64,2> v = ( p - l.m_v0);
172 const deInt64 crossProduct = (u.x() * v.y() - u.y() * v.x());
177 static bool vertexOnLineSegment (const tcu::Vector<deInt64,2>& p, const SubpixelLineSegment& l)
182 const tcu::Vector<deInt64,2> v = l.direction();
183 const tcu::Vector<deInt64,2> u1 = ( p - l.m_v0);
184 const tcu::Vector<deInt64,2> u2 = ( p - l.m_v1);
193 static LINE_SIDE getVertexSide (const tcu::Vector<deInt64,2>& v, const SubpixelLineSegment& l)
209 bool lineInCornerAngleRange (const SubpixelLineSegment& line, const tcu::Vector<deInt64,2>& cornerExitNormal)
212 const tcu::Vector<deInt64,2> v = line.direction();
213 const deInt64 dotProduct = dot(v, cornerExitNormal);
222 bool lineInCornerOutsideAngleRange (const SubpixelLineSegment& line, const tcu::Vector<deInt64,2>& cornerExitNormal)
225 const tcu::Vector<deInt64,2> v = line.direction();
226 const deInt64 dotProduct = dot(v, cornerExitNormal);
234 bool doesLineSegmentExitDiamond (const SubpixelLineSegment& line, const tcu::Vector<deInt64,2>& diamondCenter)
240 const deInt64 halfPixel = 1ll << (RASTERIZER_SUBPIXEL_BITS-1);
244 tcu::Vector<deInt64,2> p0;
245 tcu::Vector<deInt64,2> p1;
249 { diamondCenter + tcu::Vector<deInt64,2>(0, -halfPixel), diamondCenter + tcu::Vector<deInt64,2>(-halfPixel, 0), false },
250 { diamondCenter + tcu::Vector<deInt64,2>(-halfPixel, 0), diamondCenter + tcu::Vector<deInt64,2>(0, halfPixel), false },
251 { diamondCenter + tcu::Vector<deInt64,2>(0, halfPixel), diamondCenter + tcu::Vector<deInt64,2>(halfPixel, 0), true },
252 { diamondCenter + tcu::Vector<deInt64,2>(halfPixel, 0), diamondCenter + tcu::Vector<deInt64,2>(0, -halfPixel), true },
279 tcu::Vector<deInt64,2> dp;
287 { tcu::Vector<deInt64,2>(0, -halfPixel), false, DiamondCorners::CORNER_EDGE_CASE_HIT_SECOND_QUARTER, DiamondCorners::CORNER_START_CASE_POSITIVE_Y_45, DiamondCorners::CORNER_END_CASE_DIRECTION_AND_SECOND_QUARTER},
288 { tcu::Vector<deInt64,2>(-halfPixel, 0), false, DiamondCorners::CORNER_EDGE_CASE_NONE, DiamondCorners::CORNER_START_CASE_NONE, DiamondCorners::CORNER_END_CASE_DIRECTION },
289 { tcu::Vector<deInt64,2>(0, halfPixel), false, DiamondCorners::CORNER_EDGE_CASE_HIT_FIRST_QUARTER, DiamondCorners::CORNER_START_CASE_NEGATIVE_Y_45, DiamondCorners::CORNER_END_CASE_DIRECTION_AND_FIRST_QUARTER },
290 { tcu::Vector<deInt64,2>(halfPixel, 0), true, DiamondCorners::CORNER_EDGE_CASE_HIT, DiamondCorners::CORNER_START_CASE_OUTSIDE, DiamondCorners::CORNER_END_CASE_NONE },
296 const tcu::Vector<deInt64,2> p = diamondCenter + corners[ndx].dp;
435 const deInt64 x0 = toSubpixelCoord(v0.x());
436 const deInt64 y0 = toSubpixelCoord(v0.y());
437 const deInt64 x1 = toSubpixelCoord(v1.x());
438 const deInt64 y1 = toSubpixelCoord(v1.y());
439 const deInt64 x2 = toSubpixelCoord(v2.x());
440 const deInt64 y2 = toSubpixelCoord(v2.y());
458 const deInt64 s = evaluateEdge(m_edge01, x2, y2);
471 const deInt64 xMin = de::min(de::min(x0, x1), x2);
472 const deInt64 xMax = de::max(de::max(x0, x1), x2);
473 const deInt64 yMin = de::min(de::min(y0, y1), y2);
474 const deInt64 yMax = de::max(de::max(y0, y1), y2);
508 const deInt64 sx0 = toSubpixelCoord(x0) + halfPixel;
509 const deInt64 sx1 = toSubpixelCoord(x0+1) + halfPixel;
510 const deInt64 sy0 = toSubpixelCoord(y0) + halfPixel;
511 const deInt64 sy1 = toSubpixelCoord(y0+1) + halfPixel;
513 const deInt64 sx[4] = { sx0, sx1, sx0, sx1 };
514 const deInt64 sy[4] = { sy0, sy0, sy1, sy1 };
524 tcu::Vector<deInt64, 4> e01;
525 tcu::Vector<deInt64, 4> e12;
526 tcu::Vector<deInt64, 4> e20;
602 (deInt64)((POS) * (1<<RASTERIZER_SUBPIXEL_BITS) + 0.5f)
607 static const deInt64 s_samplePos2[] =
613 static const deInt64 s_samplePos4[] =
622 static const deInt64 s_samplePos8[] =
635 static const deInt64 s_samplePos16[] =
664 const deInt64* samplePos = DE_NULL;
684 const deInt64 sx0 = toSubpixelCoord(x0);
685 const deInt64 sx1 = toSubpixelCoord(x0+1);
686 const deInt64 sy0 = toSubpixelCoord(y0);
687 const deInt64 sy1 = toSubpixelCoord(y0+1);
689 const deInt64 sx[4] = { sx0, sx1, sx0, sx1 };
690 const deInt64 sy[4] = { sy0, sy0, sy1, sy1 };
700 tcu::Vector<deInt64, 4> e01[NumSamples];
701 tcu::Vector<deInt64, 4> e12[NumSamples];
702 tcu::Vector<deInt64, 4> e20[NumSamples];
710 const deInt64 ox = samplePos[sampleNdx*2 + 0];
711 const deInt64 oy = samplePos[sampleNdx*2 + 1];
834 const tcu::Vector<deInt64,2> widthOffset = (isXMajor ? tcu::Vector<deInt64,2>(0, -1) : tcu::Vector<deInt64,2>(-1, 0)) * (toSubpixelCoord(lineWidthPixels - 1) / 2);
836 const deInt64 x0 = toSubpixelCoord(v0.x()) + widthOffset.x();
837 const deInt64 y0 = toSubpixelCoord(v0.y()) + widthOffset.y();
838 const deInt64 x1 = toSubpixelCoord(v1.x()) + widthOffset.x();
839 const deInt64 y1 = toSubpixelCoord(v1.y()) + widthOffset.y();
842 const deInt64 xMin = de::min(x0, x1) - toSubpixelCoord(1);
843 const deInt64 xMax = de::max(x0, x1) + toSubpixelCoord(1);
844 const deInt64 yMin = de::min(y0, y1) - toSubpixelCoord(1);
845 const deInt64 yMax = de::max(y0, y1) + toSubpixelCoord(1);
883 const deInt64 halfPixel = 1ll << (RASTERIZER_SUBPIXEL_BITS-1);
887 const tcu::Vector<deInt64,2> widthOffset = (isXMajor ? tcu::Vector<deInt64,2>(0, -1) : tcu::Vector<deInt64,2>(-1, 0)) * (toSubpixelCoord(lineWidth - 1) / 2);
888 const tcu::Vector<deInt64,2> pa = LineRasterUtil::toSubpixelVector(m_v0.xy()) + widthOffset;
889 const tcu::Vector<deInt64,2> pb = LineRasterUtil::toSubpixelVector(m_v1.xy()) + widthOffset;
896 const tcu::Vector<deInt64,2> diamondPosition = LineRasterUtil::toSubpixelVector(m_curPos) + tcu::Vector<deInt64,2>(halfPixel,halfPixel);
901 const tcu::Vector<deInt64,2> pr = diamondPosition;