Home
last modified time | relevance | path

Searched refs:Vector2dF (Results 1 – 25 of 148) sorted by relevance

123456

/external/chromium_org/ui/gfx/geometry/
Dvector2d_f.h20 class GFX_EXPORT Vector2dF {
22 Vector2dF() : x_(0), y_(0) {} in Vector2dF() function
23 Vector2dF(float x, float y) : x_(x), y_(y) {} in Vector2dF() function
35 void Add(const Vector2dF& other);
37 void Subtract(const Vector2dF& other);
39 void operator+=(const Vector2dF& other) { Add(other); }
40 void operator-=(const Vector2dF& other) { Subtract(other); }
42 void SetToMin(const Vector2dF& other) { in SetToMin()
47 void SetToMax(const Vector2dF& other) { in SetToMax()
70 inline bool operator==(const Vector2dF& lhs, const Vector2dF& rhs) {
[all …]
Dvector2d_unittest.cc17 Vector2dF f = i; in TEST()
24 Vector2dF float_zero(0, 0); in TEST()
25 Vector2dF float_nonzero(0.1f, -0.1f); in TEST()
50 Vector2dF f1(3.1f, 5.1f); in TEST()
51 Vector2dF f2(4.3f, -1.3f); in TEST()
54 Vector2dF expected; in TEST()
55 Vector2dF actual; in TEST()
57 { Vector2dF(3.1F, 5.1F), f1 + Vector2d() }, in TEST()
58 { Vector2dF(3.1F, 5.1F), f1 + Vector2dF() }, in TEST()
59 { Vector2dF(3.1f + 4.3f, 5.1f - 1.3f), f1 + f2 }, in TEST()
[all …]
Dvector2d_f.cc13 std::string Vector2dF::ToString() const { in ToString()
17 bool Vector2dF::IsZero() const { in IsZero()
21 void Vector2dF::Add(const Vector2dF& other) { in Add()
26 void Vector2dF::Subtract(const Vector2dF& other) { in Subtract()
31 double Vector2dF::LengthSquared() const { in LengthSquared()
35 float Vector2dF::Length() const { in Length()
39 void Vector2dF::Scale(float x_scale, float y_scale) { in Scale()
44 double CrossProduct(const Vector2dF& lhs, const Vector2dF& rhs) { in CrossProduct()
49 double DotProduct(const Vector2dF& lhs, const Vector2dF& rhs) { in DotProduct()
54 Vector2dF ScaleVector2d(const Vector2dF& v, float x_scale, float y_scale) { in ScaleVector2d()
[all …]
Dpoint_f.h18 class GFX_EXPORT PointF : public PointBase<PointF, float, Vector2dF> {
20 PointF() : PointBase<PointF, float, Vector2dF>(0, 0) {} in PointF()
21 PointF(float x, float y) : PointBase<PointF, float, Vector2dF>(x, y) {} in PointF()
44 inline PointF operator+(const PointF& lhs, const Vector2dF& rhs) {
50 inline PointF operator-(const PointF& lhs, const Vector2dF& rhs) {
56 inline Vector2dF operator-(const PointF& lhs, const PointF& rhs) {
57 return Vector2dF(lhs.x() - rhs.x(), lhs.y() - rhs.y());
60 inline PointF PointAtOffsetFromOrigin(const Vector2dF& offset_from_origin) { in PointAtOffsetFromOrigin()
71 extern template class PointBase<PointF, float, Vector2dF>;
Drect_f.h22 : public RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float> {
25 : RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float> in RectF()
29 : RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float> in RectF()
33 : RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float> in RectF()
37 : RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float> in RectF()
41 : RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float> in RectF()
73 inline RectF operator+(const RectF& lhs, const Vector2dF& rhs) {
78 inline RectF operator-(const RectF& lhs, const Vector2dF& rhs) {
83 inline RectF operator+(const Vector2dF& lhs, const RectF& rhs) {
109 extern template class RectBase<RectF, PointF, SizeF, InsetsF, Vector2dF, float>;
Dquad_f.cc75 Vector2dF a = r1 - point; in PointIsInTriangle()
76 Vector2dF b = r2 - point; in PointIsInTriangle()
77 Vector2dF c = r3 - point; in PointIsInTriangle()
97 void QuadF::operator+=(const Vector2dF& rhs) { in operator +=()
104 void QuadF::operator-=(const Vector2dF& rhs) { in operator -=()
111 QuadF operator+(const QuadF& lhs, const Vector2dF& rhs) { in operator +()
117 QuadF operator-(const QuadF& lhs, const Vector2dF& rhs) { in operator -()
Dvector2d_conversions.h14 GFX_EXPORT Vector2d ToFlooredVector2d(const Vector2dF& vector2d);
17 GFX_EXPORT Vector2d ToCeiledVector2d(const Vector2dF& vector2d);
20 GFX_EXPORT Vector2d ToRoundedVector2d(const Vector2dF& vector2d);
/external/chromium_org/cc/animation/
Dscroll_offset_animation_curve_unittest.cc15 gfx::Vector2dF target_value(100.f, 200.f); in TEST()
25 curve->SetInitialValue(gfx::Vector2dF(136.f, 200.f)); in TEST()
29 curve->SetInitialValue(gfx::Vector2dF(19.f, 200.f)); in TEST()
33 curve->SetInitialValue(gfx::Vector2dF(100.f, 344.f)); in TEST()
37 curve->SetInitialValue(gfx::Vector2dF(100.f, 191.f)); in TEST()
41 curve->SetInitialValue(gfx::Vector2dF(32500.f, 500.f)); in TEST()
45 curve->SetInitialValue(gfx::Vector2dF(150.f, 119.f)); in TEST()
49 curve->SetInitialValue(gfx::Vector2dF(0.f, 14600.f)); in TEST()
53 curve->SetInitialValue(gfx::Vector2dF(95.f, 191.f)); in TEST()
58 gfx::Vector2dF initial_value(2.f, 40.f); in TEST()
[all …]
Dscroll_offset_animation_curve.h20 const gfx::Vector2dF& target_value,
25 void SetInitialValue(const gfx::Vector2dF& initial_value);
26 gfx::Vector2dF GetValue(double t) const;
27 gfx::Vector2dF target_value() const { return target_value_; } in target_value()
28 void UpdateTarget(double t, const gfx::Vector2dF& new_target);
36 ScrollOffsetAnimationCurve(const gfx::Vector2dF& target_value,
39 gfx::Vector2dF initial_value_;
40 gfx::Vector2dF target_value_;
Dscroll_offset_animation_curve.cc20 static float MaximumDimension(gfx::Vector2dF delta) { in MaximumDimension()
24 static base::TimeDelta DurationFromDelta(gfx::Vector2dF delta) { in DurationFromDelta()
48 const gfx::Vector2dF& target_value, in Create()
55 const gfx::Vector2dF& target_value, in ScrollOffsetAnimationCurve()
63 const gfx::Vector2dF& initial_value) { in SetInitialValue()
68 gfx::Vector2dF ScrollOffsetAnimationCurve::GetValue(double t) const { in GetValue()
79 return gfx::Vector2dF(gfx::Tween::FloatValueBetween( in GetValue()
106 const gfx::Vector2dF& new_target) { in UpdateTarget()
107 gfx::Vector2dF current_position = GetValue(t); in UpdateTarget()
108 gfx::Vector2dF old_delta = target_value_ - initial_value_; in UpdateTarget()
[all …]
/external/chromium_org/cc/input/
Dpage_scale_animation.cc19 gfx::Vector2dF NormalizeFromViewport(const gfx::Vector2dF& denormalized, in NormalizeFromViewport()
26 gfx::Vector2dF DenormalizeToViewport(const gfx::Vector2dF& normalized, in DenormalizeToViewport()
33 gfx::Vector2dF InterpolateBetween(const gfx::Vector2dF& start, in InterpolateBetween()
34 const gfx::Vector2dF& end, in InterpolateBetween()
47 const gfx::Vector2dF& start_scroll_offset, in Create()
60 const gfx::Vector2dF& start_scroll_offset, in PageScaleAnimation()
77 void PageScaleAnimation::ZoomTo(const gfx::Vector2dF& target_scroll_offset, in ZoomTo()
97 void PageScaleAnimation::ZoomWithAnchor(const gfx::Vector2dF& anchor, in ZoomWithAnchor()
119 gfx::Vector2dF normalized = NormalizeFromViewport( in InferTargetScrollOffsetFromStartAnchor()
140 gfx::Vector2dF normalized = gfx::ScaleVector2d( in InferTargetAnchorFromScrollOffsets()
[all …]
Dpage_scale_animation.h31 const gfx::Vector2dF& start_scroll_offset,
43 void ZoomTo(const gfx::Vector2dF& target_scroll_offset,
51 void ZoomWithAnchor(const gfx::Vector2dF& anchor,
62 gfx::Vector2dF ScrollOffsetAtTime(base::TimeTicks time) const;
71 gfx::Vector2dF target_scroll_offset() const { return target_scroll_offset_; } in target_scroll_offset()
75 PageScaleAnimation(const gfx::Vector2dF& start_scroll_offset,
90 gfx::Vector2dF ScrollOffsetAt(float interp) const;
91 gfx::Vector2dF AnchorAt(float interp) const;
92 gfx::Vector2dF ViewportRelativeAnchorAt(float interp) const;
97 gfx::Vector2dF start_scroll_offset_;
[all …]
Dtop_controls_manager_unittest.cc93 manager->ScrollBy(gfx::Vector2dF(0.f, 30.f)); in TEST()
96 manager->ScrollBy(gfx::Vector2dF(0.f, 30.f)); in TEST()
99 manager->ScrollBy(gfx::Vector2dF(0.f, 100.f)); in TEST()
104 manager->ScrollBy(gfx::Vector2dF(0.f, -10.f)); in TEST()
107 manager->ScrollBy(gfx::Vector2dF(0.f, -50.f)); in TEST()
112 manager->ScrollBy(gfx::Vector2dF(0.f, -10.f)); in TEST()
115 manager->ScrollBy(gfx::Vector2dF(0.f, -50.f)); in TEST()
120 manager->ScrollBy(gfx::Vector2dF(0.f, -100.f)); in TEST()
124 manager->ScrollBy(gfx::Vector2dF(0.f, 20.f)); in TEST()
134 manager->ScrollBy(gfx::Vector2dF(0.f, 300.f)); in TEST()
[all …]
Dinput_handler.h18 class Vector2dF; variable
39 const gfx::Vector2dF& accumulated_overscroll,
40 const gfx::Vector2dF& latest_overscroll_delta) = 0;
81 const gfx::Vector2dF& scroll_delta) = 0;
96 const gfx::Vector2dF& scroll_delta) = 0;
/external/chromium_org/cc/layers/
Dlayer_impl_unittest.cc455 EXPECT_VECTOR_EQ(gfx::Vector2dF(), layer()->TotalScrollOffset()); in TEST_F()
456 EXPECT_VECTOR_EQ(gfx::Vector2dF(), layer()->scroll_offset()); in TEST_F()
457 EXPECT_VECTOR_EQ(gfx::Vector2dF(), layer()->ScrollDelta()); in TEST_F()
459 layer()->ScrollBy(gfx::Vector2dF(-100, 100)); in TEST_F()
460 EXPECT_VECTOR_EQ(gfx::Vector2dF(0, 80), layer()->TotalScrollOffset()); in TEST_F()
463 EXPECT_VECTOR_EQ(gfx::Vector2dF(), layer()->scroll_offset()); in TEST_F()
465 layer()->ScrollBy(gfx::Vector2dF(100, -100)); in TEST_F()
466 EXPECT_VECTOR_EQ(gfx::Vector2dF(50, 0), layer()->TotalScrollOffset()); in TEST_F()
469 EXPECT_VECTOR_EQ(gfx::Vector2dF(), layer()->scroll_offset()); in TEST_F()
478 EXPECT_VECTOR_EQ(gfx::Vector2dF(), layer()->ScrollDelta()); in TEST_F()
[all …]
Dlayer_impl.h80 virtual void SetTotalScrollOffset(const gfx::Vector2dF& new_value) = 0;
81 virtual gfx::Vector2dF GetTotalScrollOffset() = 0;
100 virtual gfx::Vector2dF ScrollOffsetForAnimation() const OVERRIDE;
107 const gfx::Vector2dF& scroll_offset) OVERRIDE;
277 gfx::Vector2dF FixedContainerSizeDelta() const;
367 void SetBoundsDelta(const gfx::Vector2dF& bounds_delta);
368 gfx::Vector2dF bounds_delta() const { return bounds_delta_; } in bounds_delta()
382 const gfx::Vector2dF& scroll_delta);
386 gfx::Vector2dF ClampScrollToMaxScrollOffset();
389 void SetScrollDelta(const gfx::Vector2dF& scroll_delta);
[all …]
/external/chromium_org/android_webview/browser/
Dbrowser_view_renderer.h126 virtual gfx::Vector2dF GetTotalRootLayerScrollOffset() OVERRIDE;
128 const gfx::Vector2dF& total_scroll_offset_dip,
129 const gfx::Vector2dF& max_scroll_offset_dip,
135 virtual void DidOverscroll(gfx::Vector2dF accumulated_overscroll,
136 gfx::Vector2dF latest_overscroll_delta,
137 gfx::Vector2dF current_fling_velocity) OVERRIDE;
150 void SetTotalRootLayerScrollOffset(gfx::Vector2dF new_value_dip);
163 const gfx::Vector2dF& total_scroll_offset_dip,
236 gfx::Vector2dF scroll_offset_dip_;
239 gfx::Vector2dF max_scroll_offset_dip_;
[all …]
/external/chromium_org/content/public/browser/android/
Dsynchronous_compositor_client.h29 virtual gfx::Vector2dF GetTotalRootLayerScrollOffset() = 0;
30 virtual void UpdateRootLayerState(const gfx::Vector2dF& total_scroll_offset,
31 const gfx::Vector2dF& max_scroll_offset,
38 virtual void DidOverscroll(gfx::Vector2dF accumulated_overscroll,
39 gfx::Vector2dF latest_overscroll_delta,
40 gfx::Vector2dF current_fling_velocity) = 0;
/external/chromium_org/content/browser/android/
Doverscroll_glow.h55 gfx::Vector2dF accumulated_overscroll,
56 gfx::Vector2dF overscroll_delta,
57 gfx::Vector2dF velocity,
58 gfx::Vector2dF overscroll_location);
82 const gfx::Vector2dF& overscroll_delta,
83 const gfx::Vector2dF& overscroll_location);
85 const gfx::Vector2dF& velocity,
Doverscroll_glow.cc23 gfx::Vector2dF ZeroSmallComponents(gfx::Vector2dF vector) { in ZeroSmallComponents()
106 gfx::Vector2dF accumulated_overscroll, in OnOverscrolled()
107 gfx::Vector2dF overscroll_delta, in OnOverscrolled()
108 gfx::Vector2dF velocity, in OnOverscrolled()
109 gfx::Vector2dF displacement) { in OnOverscrolled()
133 gfx::Vector2dF old_overscroll = accumulated_overscroll - overscroll_delta; in OnOverscrolled()
226 const gfx::Vector2dF& overscroll_delta, in Pull()
227 const gfx::Vector2dF& overscroll_location) { in Pull()
233 gfx::Vector2dF overscroll_pull = in Pull()
242 gfx::Vector2dF displacement = in Pull()
[all …]
/external/chromium_org/cc/base/
Dmath_util_unittest.cc73 gfx::Vector2dF x(1, 0); in TEST()
74 gfx::Vector2dF y(0, 1); in TEST()
75 gfx::Vector2dF test_vector(0.5, 0.5); in TEST()
99 gfx::Vector2dF x(1, 0); in TEST()
100 gfx::Vector2dF y(0, 1); in TEST()
101 gfx::Vector2dF test_vector(0.3f, 0.7f); in TEST()
104 EXPECT_VECTOR_EQ(gfx::Vector2dF(0, 0), MathUtil::ProjectVector(x, y)); in TEST()
105 EXPECT_VECTOR_EQ(gfx::Vector2dF(0, 0), MathUtil::ProjectVector(y, x)); in TEST()
109 EXPECT_VECTOR_EQ(gfx::Vector2dF(test_vector.x(), 0), in TEST()
111 EXPECT_VECTOR_EQ(gfx::Vector2dF(0, test_vector.y()), in TEST()
[all …]
/external/chromium_org/ui/events/gestures/
Dfling_curve.cc37 FlingCurve::FlingCurve(const gfx::Vector2dF& velocity, in FlingCurve()
48 displacement_ratio_ = gfx::Vector2dF(velocity.x() / max_start_velocity, in FlingCurve()
59 gfx::Vector2dF FlingCurve::GetScrollAmountAtTime(base::TimeTicks current) { in GetScrollAmountAtTime()
61 return gfx::Vector2dF(); in GetScrollAmountAtTime()
72 gfx::Vector2dF scroll(displacement * displacement_ratio_.x(), in GetScrollAmountAtTime()
74 gfx::Vector2dF scroll_increment(scroll.x() - cumulative_scroll_.x(), in GetScrollAmountAtTime()
Dfling_curve.h19 FlingCurve(const gfx::Vector2dF& velocity, base::TimeTicks start_timestamp);
22 gfx::Vector2dF GetScrollAmountAtTime(base::TimeTicks current_timestamp);
29 gfx::Vector2dF displacement_ratio_;
30 gfx::Vector2dF cumulative_scroll_;
/external/chromium_org/content/common/input/
Ddid_overscroll_params.h17 gfx::Vector2dF accumulated_overscroll;
18 gfx::Vector2dF latest_overscroll_delta;
19 gfx::Vector2dF current_fling_velocity;
/external/chromium_org/cc/test/
Danimation_test_common.h83 const gfx::Vector2dF& scroll_offset) OVERRIDE;
90 gfx::Vector2dF scroll_offset() { return scroll_offset_; } in scroll_offset()
100 gfx::Vector2dF scroll_offset_;
112 virtual gfx::Vector2dF ScrollOffsetForAnimation() const OVERRIDE;
114 void set_scroll_offset(const gfx::Vector2dF& scroll_offset) { in set_scroll_offset()
119 gfx::Vector2dF scroll_offset_;

123456