public void float4x4_operator_equal_wide_wide()
        {
            float4x4 a0 = float4x4(492.1576f, -495.206329f, 227.457642f, -147.374054f);
            float4x4 b0 = float4x4(192.568787f, -235.611023f, -254.043121f, -412.624725f);
            bool4x4  r0 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            float4x4 a1 = float4x4(-222.682f, 64.09375f, -23.8904114f, -16.8197327f);
            float4x4 b1 = float4x4(471.9048f, -6.47277832f, -339.102356f, 488.187561f);
            bool4x4  r1 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            float4x4 a2 = float4x4(163.232117f, -165.271f, 470.8777f, -423.942566f);
            float4x4 b2 = float4x4(-379.5966f, -308.417f, -82.333374f, -102.921082f);
            bool4x4  r2 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            float4x4 a3 = float4x4(109.6344f, 462.6903f, -335.38147f, 357.2345f);
            float4x4 b3 = float4x4(226.515747f, -356.9013f, -362.912781f, -427.898438f);
            bool4x4  r3 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
Exemple #2
0
        public void bool4x4_operator_bitwise_or_wide_scalar()
        {
            bool4x4 a0 = bool4x4(true, true, false, true, true, true, true, false, true, false, false, true, false, false, true, false);
            bool    b0 = (true);
            bool4x4 r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 | b0, r0);

            bool4x4 a1 = bool4x4(true, true, true, true, true, true, true, false, true, false, false, false, true, true, true, true);
            bool    b1 = (true);
            bool4x4 r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 | b1, r1);

            bool4x4 a2 = bool4x4(true, false, true, false, false, true, false, true, false, true, true, false, true, true, false, true);
            bool    b2 = (true);
            bool4x4 r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 | b2, r2);

            bool4x4 a3 = bool4x4(false, true, true, true, true, true, false, false, false, true, true, false, false, true, true, false);
            bool    b3 = (true);
            bool4x4 r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 | b3, r3);
        }
Exemple #3
0
        public void bool4x4_operator_equal_scalar_wide()
        {
            bool    a0 = (false);
            bool4x4 b0 = bool4x4(true, false, true, false, false, true, false, false, true, false, true, true, false, true, false, true);
            bool4x4 r0 = bool4x4(false, true, false, true, true, false, true, true, false, true, false, false, true, false, true, false);

            TestUtils.AreEqual(a0 == b0, r0);

            bool    a1 = (true);
            bool4x4 b1 = bool4x4(true, false, false, true, false, true, true, false, true, true, true, true, true, true, false, true);
            bool4x4 r1 = bool4x4(true, false, false, true, false, true, true, false, true, true, true, true, true, true, false, true);

            TestUtils.AreEqual(a1 == b1, r1);

            bool    a2 = (true);
            bool4x4 b2 = bool4x4(false, false, false, true, true, true, false, true, true, true, false, false, true, false, true, true);
            bool4x4 r2 = bool4x4(false, false, false, true, true, true, false, true, true, true, false, false, true, false, true, true);

            TestUtils.AreEqual(a2 == b2, r2);

            bool    a3 = (false);
            bool4x4 b3 = bool4x4(false, false, false, true, true, true, true, false, false, true, false, true, false, false, false, false);
            bool4x4 r3 = bool4x4(true, true, true, false, false, false, false, true, true, false, true, false, true, true, true, true);

            TestUtils.AreEqual(a3 == b3, r3);
        }
        public void double4x4_operator_equal_scalar_wide()
        {
            double    a0 = (-253.39728534100453);
            double4x4 b0 = double4x4(19.952187785856495, -185.79199346610903, 407.8136052600172, -87.2766969610363, -206.27469382354741, 160.503138855334, -274.77081478516141, -2.6315281403397535, 448.35453602688131, -410.03524251004461, 247.32901465489022, 355.53915350303942, -298.06671180299793, 414.10151429385951, -481.30262707234482, 196.55074438664633);
            bool4x4   r0 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            double    a1 = (34.60100008668428);
            double4x4 b1 = double4x4(113.76156645350227, -386.45337861890596, -124.49174672201821, 243.8866447153905, -492.6181826501238, 145.424413033493, 421.55070968230757, -95.409988209330493, 336.80928746648567, 209.58380589707929, 487.441424358376, 161.80653365040507, 149.84247095409899, 225.723996505944, -71.21880176999548, 85.780251781353854);
            bool4x4   r1 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            double    a2 = (192.547256797807);
            double4x4 b2 = double4x4(-49.887493395194156, -229.80195652218629, -103.40733413743197, 19.215747126944279, 492.88110827509365, 140.40315849166507, -267.53641546309757, 125.9727018466092, 478.00049398746364, 116.14462071105118, -368.95778220191494, -225.02866350162248, 2.7237255585955609, -452.2632198055569, 87.456553261474028, 401.30651802630462);
            bool4x4   r2 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            double    a3 = (-18.645524272064449);
            double4x4 b3 = double4x4(-294.21400060048978, -32.7313416156598, -1.2523367410769311, 14.716069943605021, 0.57037043598029413, 180.78359350039796, 498.26289557770963, -503.8667087517058, -31.08398129003308, 462.9193329582547, -250.21223914353749, 347.56193820925523, -213.48793492721762, -123.75923901598867, -193.4521835751143, -242.24109827831438);
            bool4x4   r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
        public void double4x4_operator_not_equal_wide_wide()
        {
            double4x4 a0 = double4x4(430.8425316432689, 104.69001798736394, 225.80243478799355, -310.57017841496048, -418.61945815506363, 304.12820281839379, -509.32682561749908, -160.53807719076895, -203.30197606016975, -505.76325368590807, 162.17220623892365, 1.1561973100324394, 65.662074358045174, 102.78780250567377, 172.93008120960099, 26.621009123800832);
            double4x4 b0 = double4x4(210.02470622305975, -55.203330304102678, -269.92533672504373, -234.54673372700194, 25.917412054686565, -63.726991444699024, -484.55371092471933, -425.333599050219, -53.274394775402925, 328.1944192984115, 15.963139303011417, 461.71412417931208, -113.36304455313973, -240.07297264787974, 495.11916970420589, 203.5583661550462);
            bool4x4   r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            double4x4 a1 = double4x4(235.12595259171258, 128.54198533321824, -354.99697630246959, 334.35948220564023, -495.83200692377613, 468.30740163675853, 458.37094733601941, 299.93733300824522, 43.12718560319729, -354.71349994964595, -145.2871955117617, 390.80186218340032, -303.13149108697263, 391.13459533785215, 139.2868607692825, 104.52318506339714);
            double4x4 b1 = double4x4(340.49345103860526, -241.90719448863865, 459.56982896270688, 213.0737384357833, -384.7828506831, -255.07233846144396, 477.66343115161328, -248.03662621604121, -407.92344565313471, -199.78886971240343, 151.84326488889906, -97.120607659742518, 154.97589380805187, -172.83452065886672, 441.5027942329192, -401.73862785926957);
            bool4x4   r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            double4x4 a2 = double4x4(511.29640293088573, 213.1470559635884, -101.09569625793756, 441.6633772522506, 124.36612301895684, 312.02642622218764, 59.65573766625289, -508.65682315670739, 98.699622438615052, 228.79984174892297, 337.83266965385189, -163.1544383331921, 461.69158885520494, -450.77570340166596, -443.56476637514527, -438.2131223334992);
            double4x4 b2 = double4x4(-411.43016333665241, -337.8202766561044, -430.63088270213029, -150.87180502287663, -206.83699212169137, 34.955056922023687, -255.77146422852366, 99.99864320643178, -161.17557127828502, 68.853526862735634, -285.59012116379574, -428.71731229718648, -286.33740700703925, 2.0271298894784877, -4.8059971354929871, -425.33480115669539);
            bool4x4   r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            double4x4 a3 = double4x4(22.693964253502827, -254.3687413923297, -247.48362481197512, 365.05907004189635, -337.58682290538536, 187.84500726863973, 351.81683866671142, 355.22365467400459, 151.63271696475931, 240.46585690251823, -299.29704751600377, -227.57129751312141, 263.72427499653975, -287.51186551130928, -491.85517930046433, -219.3070386477313);
            double4x4 b3 = double4x4(358.04602949602815, 357.80111067267183, 125.75760966434962, -38.241931694672417, 308.15830507323062, -450.45020339007033, -156.15319473862331, 464.63997314155097, -220.86404786857963, -211.53756795243248, -476.3303417993385, 284.88652409468148, 129.86436826077488, -326.75828925089832, -72.36375263722789, -382.82787984555023);
            bool4x4   r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
Exemple #6
0
 public static void AreEqual(bool4x4 a, bool4x4 b)
 {
     AreEqual(a.c0, b.c0);
     AreEqual(a.c1, b.c1);
     AreEqual(a.c2, b.c2);
     AreEqual(a.c3, b.c3);
 }
        public void double4x4_operator_not_equal_scalar_wide()
        {
            double    a0 = (275.79582823244664);
            double4x4 b0 = double4x4(-57.196896341255353, -382.4325279586169, 97.820359990848374, -161.46364529499022, -458.39563367254829, -499.61786364932448, 327.92217818271467, 367.57121699283425, 59.7863667289663, -209.58068118318016, -62.580453186566217, -479.97497604786184, -49.494519495169868, -114.68521338081229, 109.93924599044919, -176.28482755286842);
            bool4x4   r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            double    a1 = (-347.48529903380449);
            double4x4 b1 = double4x4(85.540928165214609, -356.65954868712441, -104.24357490625397, -133.54918605347592, 243.53971135036079, 13.141311890045813, -379.98594754747393, -41.281226892620907, 87.911684792447659, -339.07727996403224, -371.82034533648766, 333.14425936953364, 294.81196011920088, -187.14565977228136, 220.19225774528093, -228.18207250730234);
            bool4x4   r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            double    a2 = (-499.72373914146971);
            double4x4 b2 = double4x4(97.4059055305114, 501.60439395420462, 459.67539880223353, 158.09812290877949, 358.48858921531985, 243.51259171381253, 336.70294991913386, 89.953149122164177, -65.578377515812576, -159.26015503670095, 410.58855528877518, 123.96303206494224, -239.6251271886868, -299.42983808155628, -491.29190443981992, 207.71164641515895);
            bool4x4   r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            double    a3 = (271.56546724567443);
            double4x4 b3 = double4x4(-329.03772202554984, 461.00740334997295, -317.16052523123125, -102.6549857140775, 211.26339230838391, 116.4261601513374, -34.1936924616777, 391.81758159763069, -34.307318464996, 351.45941631470782, 187.74252351920234, -477.57304237669939, 276.97440660976542, 489.5649785891012, 229.2272890681528, 260.20709645944044);
            bool4x4   r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
        public static void fix64p4x4_operator_equal_wide_wide()
        {
            fix64p4x4 a0 = fix64p4x4(new fix64p(-135.18924f), new fix64p(-49.0941162f), new fix64p(169.129822f), new fix64p(240.8053f), new fix64p(314.7392f), new fix64p(442.393f), new fix64p(177.924438f), new fix64p(335.5334f), new fix64p(168.15448f), new fix64p(350.729553f), new fix64p(367.178467f), new fix64p(46.9414673f), new fix64p(188.76416f), new fix64p(-97.2113953f), new fix64p(-293.320984f), new fix64p(-234.822937f));
            fix64p4x4 b0 = fix64p4x4(new fix64p(-220.014648f), new fix64p(66.98004f), new fix64p(499.2016f), new fix64p(-371.1131f), new fix64p(208.448669f), new fix64p(390.8037f), new fix64p(-72.44382f), new fix64p(362.97644f), new fix64p(194.678345f), new fix64p(471.644836f), new fix64p(-404.044678f), new fix64p(-144.696747f), new fix64p(-494.446655f), new fix64p(-252.970367f), new fix64p(234.417114f), new fix64p(398.724f));
            bool4x4   r0 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            fix64p4x4 a1 = fix64p4x4(new fix64p(417.0337f), new fix64p(26.3864136f), new fix64p(269.245728f), new fix64p(29.4741821f), new fix64p(479.485229f), new fix64p(-237.230957f), new fix64p(-221.9837f), new fix64p(-506.672546f), new fix64p(-22.98944f), new fix64p(487.260864f), new fix64p(-419.731964f), new fix64p(337.2033f), new fix64p(245.043884f), new fix64p(390.215881f), new fix64p(84.4129639f), new fix64p(434.2079f));
            fix64p4x4 b1 = fix64p4x4(new fix64p(260.4287f), new fix64p(370.144226f), new fix64p(89.579834f), new fix64p(-434.816833f), new fix64p(-109.845337f), new fix64p(336.973022f), new fix64p(-409.154968f), new fix64p(500.387573f), new fix64p(-174.081818f), new fix64p(395.101135f), new fix64p(350.3393f), new fix64p(-243.144592f), new fix64p(-416.397369f), new fix64p(151.576477f), new fix64p(-18.2243347f), new fix64p(-431.677917f));
            bool4x4   r1 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            fix64p4x4 a2 = fix64p4x4(new fix64p(-68.7284241f), new fix64p(485.769958f), new fix64p(413.169739f), new fix64p(-418.2693f), new fix64p(-346.795868f), new fix64p(504.159668f), new fix64p(345.186279f), new fix64p(-434.713043f), new fix64p(-499.7741f), new fix64p(282.019043f), new fix64p(259.15625f), new fix64p(306.455933f), new fix64p(435.2254f), new fix64p(-386.8997f), new fix64p(211.364014f), new fix64p(-7.229828f));
            fix64p4x4 b2 = fix64p4x4(new fix64p(-468.330963f), new fix64p(429.495728f), new fix64p(477.389221f), new fix64p(-433.4254f), new fix64p(273.5464f), new fix64p(-34.9762268f), new fix64p(221.968445f), new fix64p(85.91913f), new fix64p(-85.59894f), new fix64p(392.7608f), new fix64p(-117.924072f), new fix64p(-445.3056f), new fix64p(-242.468964f), new fix64p(173.643066f), new fix64p(389.897766f), new fix64p(-14.2904663f));
            bool4x4   r2 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            fix64p4x4 a3 = fix64p4x4(new fix64p(-32.0532227f), new fix64p(-106.298553f), new fix64p(-382.924957f), new fix64p(-424.7822f), new fix64p(-267.8125f), new fix64p(229.897034f), new fix64p(358.1797f), new fix64p(-76.33087f), new fix64p(-493.684326f), new fix64p(139.350586f), new fix64p(211.756653f), new fix64p(-178.8342f), new fix64p(-262.786865f), new fix64p(506.270325f), new fix64p(352.288879f), new fix64p(-132.7894f));
            fix64p4x4 b3 = fix64p4x4(new fix64p(-317.55304f), new fix64p(-265.652771f), new fix64p(-424.168274f), new fix64p(11.6213379f), new fix64p(408.686218f), new fix64p(-181.278351f), new fix64p(-139.8205f), new fix64p(-488.924561f), new fix64p(-207.703278f), new fix64p(-341.9881f), new fix64p(-470.552917f), new fix64p(-462.804352f), new fix64p(419.075562f), new fix64p(143.638733f), new fix64p(-79.912384f), new fix64p(-224.6936f));
            bool4x4   r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
        public static void fix64p4x4_operator_equal_wide_scalar()
        {
            fix64p4x4 a0 = fix64p4x4(new fix64p(65.6712f), new fix64p(404.415527f), new fix64p(-269.730164f), new fix64p(83.6306152f), new fix64p(152.9945f), new fix64p(-155.868286f), new fix64p(314.671265f), new fix64p(386.365173f), new fix64p(290.04895f), new fix64p(-132.6352f), new fix64p(-65.66748f), new fix64p(-69.68326f), new fix64p(-191.190765f), new fix64p(186.845215f), new fix64p(-232.895691f), new fix64p(-319.144043f));
            fix64p    b0 = (new fix64p(-155.815765f));
            bool4x4   r0 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            fix64p4x4 a1 = fix64p4x4(new fix64p(-49.70108f), new fix64p(333.396851f), new fix64p(386.3775f), new fix64p(-296.7019f), new fix64p(-309.1172f), new fix64p(141.542358f), new fix64p(-227.323334f), new fix64p(83.87286f), new fix64p(-410.91687f), new fix64p(110.501282f), new fix64p(-390.103577f), new fix64p(36.57434f), new fix64p(-427.541443f), new fix64p(-268.170837f), new fix64p(175.8117f), new fix64p(-193.47995f));
            fix64p    b1 = (new fix64p(-300.8819f));
            bool4x4   r1 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            fix64p4x4 a2 = fix64p4x4(new fix64p(291.051941f), new fix64p(-429.8739f), new fix64p(-275.156952f), new fix64p(-56.3323669f), new fix64p(-95.83597f), new fix64p(-124.865326f), new fix64p(253.006165f), new fix64p(-300.509521f), new fix64p(314.866516f), new fix64p(195.616211f), new fix64p(-26.1289063f), new fix64p(-284.7747f), new fix64p(-242.672058f), new fix64p(140.3606f), new fix64p(505.644348f), new fix64p(506.537964f));
            fix64p    b2 = (new fix64p(423.97168f));
            bool4x4   r2 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            fix64p4x4 a3 = fix64p4x4(new fix64p(-502.3698f), new fix64p(87.36731f), new fix64p(-433.136383f), new fix64p(-149.626923f), new fix64p(-358.698547f), new fix64p(-249.126862f), new fix64p(469.5932f), new fix64p(511.757751f), new fix64p(51.911377f), new fix64p(245.630432f), new fix64p(192.774841f), new fix64p(-162.209167f), new fix64p(205.5904f), new fix64p(-376.464355f), new fix64p(270.5208f), new fix64p(-388.2033f));
            fix64p    b3 = (new fix64p(-249.517639f));
            bool4x4   r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
        public static void fix64p4x4_operator_not_equal_wide_scalar()
        {
            fix64p4x4 a0 = fix64p4x4(new fix64p(-155.4411f), new fix64p(-19.4266052f), new fix64p(174.633057f), new fix64p(507.920715f), new fix64p(59.177063f), new fix64p(171.151489f), new fix64p(-58.92328f), new fix64p(-398.176849f), new fix64p(492.20105f), new fix64p(-165.241516f), new fix64p(270.341f), new fix64p(-380.243256f), new fix64p(501.899048f), new fix64p(-134.345459f), new fix64p(458.400452f), new fix64p(46.7709961f));
            fix64p    b0 = (new fix64p(-393.413544f));
            bool4x4   r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            fix64p4x4 a1 = fix64p4x4(new fix64p(161.459961f), new fix64p(-145.6124f), new fix64p(-0.449920654f), new fix64p(350.461426f), new fix64p(202.221008f), new fix64p(242.664f), new fix64p(382.677063f), new fix64p(-468.967957f), new fix64p(-497.459473f), new fix64p(-80.93225f), new fix64p(-328.587769f), new fix64p(-506.490326f), new fix64p(449.348145f), new fix64p(210.771f), new fix64p(249.181824f), new fix64p(-338.468536f));
            fix64p    b1 = (new fix64p(261.514221f));
            bool4x4   r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            fix64p4x4 a2 = fix64p4x4(new fix64p(229.670654f), new fix64p(317.286072f), new fix64p(401.939575f), new fix64p(210.984863f), new fix64p(-147.096313f), new fix64p(-193.399048f), new fix64p(207.731384f), new fix64p(284.3921f), new fix64p(-509.0853f), new fix64p(414.307617f), new fix64p(-52.2944641f), new fix64p(-140.437927f), new fix64p(-316.787781f), new fix64p(-358.696838f), new fix64p(312.31897f), new fix64p(270.629456f));
            fix64p    b2 = (new fix64p(-76.5433044f));
            bool4x4   r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            fix64p4x4 a3 = fix64p4x4(new fix64p(-140.016724f), new fix64p(113.137207f), new fix64p(479.6996f), new fix64p(6.097473f), new fix64p(-83.63458f), new fix64p(249.909363f), new fix64p(303.956f), new fix64p(464.888672f), new fix64p(44.6365356f), new fix64p(-259.91626f), new fix64p(-242.33551f), new fix64p(-403.686523f), new fix64p(-469.1471f), new fix64p(135.987488f), new fix64p(-490.840759f), new fix64p(470.225281f));
            fix64p    b3 = (new fix64p(108.910645f));
            bool4x4   r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
        public static void fix64p4x4_operator_not_equal_scalar_wide()
        {
            fix64p    a0 = (new fix64p(478.353149f));
            fix64p4x4 b0 = fix64p4x4(new fix64p(459.553223f), new fix64p(436.453247f), new fix64p(-488.714172f), new fix64p(392.767944f), new fix64p(-266.736633f), new fix64p(338.557861f), new fix64p(-338.100128f), new fix64p(-152.314545f), new fix64p(-452.820679f), new fix64p(209.439331f), new fix64p(50.10797f), new fix64p(372.4344f), new fix64p(-488.0213f), new fix64p(489.740784f), new fix64p(270.4001f), new fix64p(-472.846771f));
            bool4x4   r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            fix64p    a1 = (new fix64p(-286.850464f));
            fix64p4x4 b1 = fix64p4x4(new fix64p(-384.691864f), new fix64p(443.423523f), new fix64p(358.7472f), new fix64p(-15.4140625f), new fix64p(-342.179169f), new fix64p(468.967529f), new fix64p(-130.568085f), new fix64p(401.785828f), new fix64p(-268.352264f), new fix64p(-239.231018f), new fix64p(411.386536f), new fix64p(139.769348f), new fix64p(334.522034f), new fix64p(-223.629242f), new fix64p(-12.4884644f), new fix64p(113.468872f));
            bool4x4   r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            fix64p    a2 = (new fix64p(-189.652252f));
            fix64p4x4 b2 = fix64p4x4(new fix64p(-212.846558f), new fix64p(306.1256f), new fix64p(-178.330383f), new fix64p(382.141968f), new fix64p(-340.8656f), new fix64p(-17.58023f), new fix64p(-409.874847f), new fix64p(-349.70166f), new fix64p(275.8543f), new fix64p(-229.371948f), new fix64p(-127.505737f), new fix64p(90.75342f), new fix64p(-422.087128f), new fix64p(-2.44754028f), new fix64p(-280.5517f), new fix64p(-484.374359f));
            bool4x4   r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            fix64p    a3 = (new fix64p(-33.7634277f));
            fix64p4x4 b3 = fix64p4x4(new fix64p(374.593872f), new fix64p(437.092346f), new fix64p(286.22583f), new fix64p(-18.2327881f), new fix64p(289.732361f), new fix64p(479.485718f), new fix64p(153.853943f), new fix64p(502.982117f), new fix64p(-510.3844f), new fix64p(65.78888f), new fix64p(-237.4867f), new fix64p(219.916138f), new fix64p(-275.342743f), new fix64p(-78.93146f), new fix64p(-449.403564f), new fix64p(-253.034515f));
            bool4x4   r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
        public static void fix64p4x4_operator_not_equal_wide_wide()
        {
            fix64p4x4 a0 = fix64p4x4(new fix64p(279.994141f), new fix64p(-43.34201f), new fix64p(-465.724731f), new fix64p(317.466553f), new fix64p(85.7149658f), new fix64p(360.8905f), new fix64p(366.081543f), new fix64p(154.542847f), new fix64p(332.4262f), new fix64p(397.11322f), new fix64p(-431.374969f), new fix64p(489.0108f), new fix64p(398.4336f), new fix64p(-489.817932f), new fix64p(171.4049f), new fix64p(-67.82968f));
            fix64p4x4 b0 = fix64p4x4(new fix64p(-460.9121f), new fix64p(-476.009033f), new fix64p(468.1364f), new fix64p(-341.012543f), new fix64p(-62.65805f), new fix64p(-458.801666f), new fix64p(-457.730225f), new fix64p(-59.5232544f), new fix64p(3.024231f), new fix64p(155.812744f), new fix64p(-19.8399048f), new fix64p(-6.01693726f), new fix64p(-406.207916f), new fix64p(-102.420715f), new fix64p(-40.362915f), new fix64p(452.6754f));
            bool4x4   r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            fix64p4x4 a1 = fix64p4x4(new fix64p(-192.278717f), new fix64p(227.84082f), new fix64p(62.1381836f), new fix64p(262.186462f), new fix64p(-404.0531f), new fix64p(34.449585f), new fix64p(-204.795776f), new fix64p(-285.4118f), new fix64p(-72.20682f), new fix64p(444.749268f), new fix64p(238.81781f), new fix64p(365.1801f), new fix64p(-437.9229f), new fix64p(-362.442627f), new fix64p(445.954346f), new fix64p(-0.417480469f));
            fix64p4x4 b1 = fix64p4x4(new fix64p(93.25757f), new fix64p(-258.378052f), new fix64p(-184.0498f), new fix64p(-379.2353f), new fix64p(-370.687317f), new fix64p(-255.947235f), new fix64p(29.0557861f), new fix64p(322.407654f), new fix64p(415.071716f), new fix64p(-467.726135f), new fix64p(-433.784668f), new fix64p(-212.165924f), new fix64p(474.674927f), new fix64p(452.483215f), new fix64p(-92.11273f), new fix64p(-385.9221f));
            bool4x4   r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            fix64p4x4 a2 = fix64p4x4(new fix64p(-506.828369f), new fix64p(245.477051f), new fix64p(-173.571045f), new fix64p(390.338562f), new fix64p(252.837769f), new fix64p(47.8658447f), new fix64p(457.7105f), new fix64p(-313.22113f), new fix64p(391.203857f), new fix64p(481.786133f), new fix64p(26.8878174f), new fix64p(-298.1424f), new fix64p(240.077454f), new fix64p(-332.455139f), new fix64p(-333.607178f), new fix64p(-313.1897f));
            fix64p4x4 b2 = fix64p4x4(new fix64p(420.2151f), new fix64p(-239.176056f), new fix64p(-99.0791f), new fix64p(4.476013f), new fix64p(264.348572f), new fix64p(451.312317f), new fix64p(232.958008f), new fix64p(-142.6222f), new fix64p(-300.2256f), new fix64p(268.333252f), new fix64p(-112.103546f), new fix64p(-270.494019f), new fix64p(-71.9932251f), new fix64p(99.46326f), new fix64p(321.7033f), new fix64p(200.059631f));
            bool4x4   r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            fix64p4x4 a3 = fix64p4x4(new fix64p(141.730164f), new fix64p(-261.118866f), new fix64p(295.578735f), new fix64p(-16.0213013f), new fix64p(-487.266846f), new fix64p(-208.563873f), new fix64p(30.3494873f), new fix64p(-157.876465f), new fix64p(275.896057f), new fix64p(-450.7207f), new fix64p(-61.8988647f), new fix64p(99.19006f), new fix64p(206.357483f), new fix64p(32.74652f), new fix64p(-278.623962f), new fix64p(-173.916809f));
            fix64p4x4 b3 = fix64p4x4(new fix64p(-91.62833f), new fix64p(-113.010864f), new fix64p(465.764221f), new fix64p(-485.127716f), new fix64p(-71.7267761f), new fix64p(486.469238f), new fix64p(425.8678f), new fix64p(-158.880951f), new fix64p(292.179565f), new fix64p(234.179932f), new fix64p(243.249329f), new fix64p(117.275146f), new fix64p(3.97106934f), new fix64p(410.42218f), new fix64p(-221.124725f), new fix64p(443.13446f));
            bool4x4   r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
        public static void fix64p4x4_operator_equal_scalar_wide()
        {
            fix64p    a0 = (new fix64p(36.38391f));
            fix64p4x4 b0 = fix64p4x4(new fix64p(-400.4892f), new fix64p(-71.2868347f), new fix64p(156.978088f), new fix64p(-225.238739f), new fix64p(499.141785f), new fix64p(-211.979919f), new fix64p(428.311951f), new fix64p(-489.501343f), new fix64p(-5.691559f), new fix64p(-30.8659363f), new fix64p(-362.9831f), new fix64p(184.503174f), new fix64p(-160.470612f), new fix64p(316.668823f), new fix64p(390.369263f), new fix64p(505.1051f));
            bool4x4   r0 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            fix64p    a1 = (new fix64p(-294.6487f));
            fix64p4x4 b1 = fix64p4x4(new fix64p(443.1991f), new fix64p(96.5592651f), new fix64p(-257.012939f), new fix64p(-245.054962f), new fix64p(326.464844f), new fix64p(-23.9599f), new fix64p(-168.694885f), new fix64p(386.2486f), new fix64p(-227.090637f), new fix64p(-336.612427f), new fix64p(365.108154f), new fix64p(-405.390839f), new fix64p(-473.995483f), new fix64p(298.435364f), new fix64p(-149.86322f), new fix64p(450.0664f));
            bool4x4   r1 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            fix64p    a2 = (new fix64p(153.47644f));
            fix64p4x4 b2 = fix64p4x4(new fix64p(56.28778f), new fix64p(39.3421021f), new fix64p(-350.403717f), new fix64p(-482.717224f), new fix64p(239.9654f), new fix64p(-3.40603638f), new fix64p(-1.49484253f), new fix64p(105.960449f), new fix64p(151.537537f), new fix64p(63.2832031f), new fix64p(-289.693176f), new fix64p(137.553772f), new fix64p(-247.666473f), new fix64p(-339.420563f), new fix64p(23.2382813f), new fix64p(21.1778564f));
            bool4x4   r2 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            fix64p    a3 = (new fix64p(477.03656f));
            fix64p4x4 b3 = fix64p4x4(new fix64p(-411.318146f), new fix64p(122.397095f), new fix64p(-401.49884f), new fix64p(-230.5611f), new fix64p(-214.954041f), new fix64p(464.6731f), new fix64p(-186.327f), new fix64p(-99.4873352f), new fix64p(214.232483f), new fix64p(-387.3675f), new fix64p(-448.7962f), new fix64p(427.889526f), new fix64p(-43.6960449f), new fix64p(182.698669f), new fix64p(298.880127f), new fix64p(246.436829f));
            bool4x4   r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
        public void float4x4_operator_not_equal_wide_wide()
        {
            float4x4 a0 = float4x4(430.842529f, 104.69f, 225.802429f, -310.5702f);
            float4x4 b0 = float4x4(210.024719f, -55.20334f, -269.925354f, -234.546722f);
            bool4x4  r0 = bool4x4(true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            float4x4 a1 = float4x4(-418.619446f, 304.128174f, -509.3268f, -160.538086f);
            float4x4 b1 = float4x4(25.91742f, -63.72699f, -484.5537f, -425.3336f);
            bool4x4  r1 = bool4x4(true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            float4x4 a2 = float4x4(-203.301971f, -505.763245f, 162.17218f, 1.156189f);
            float4x4 b2 = float4x4(-53.2743835f, 328.1944f, 15.9631348f, 461.7141f);
            bool4x4  r2 = bool4x4(true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            float4x4 a3 = float4x4(65.66205f, 102.787781f, 172.930054f, 26.6210327f);
            float4x4 b3 = float4x4(-113.363037f, -240.072968f, 495.119141f, 203.55835f);
            bool4x4  r3 = bool4x4(true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
Exemple #15
0
 public half4x4(bool4x4 v)
 {
     this.c0 = (half4)math.select(new float4(0.0f), new float4(1.0f), v.c0);
     this.c1 = (half4)math.select(new float4(0.0f), new float4(1.0f), v.c1);
     this.c2 = (half4)math.select(new float4(0.0f), new float4(1.0f), v.c2);
     this.c3 = (half4)math.select(new float4(0.0f), new float4(1.0f), v.c3);
 }
Exemple #16
0
        public static void bool4x4_operator_not_equal_wide_scalar()
        {
            bool4x4 a0 = bool4x4(false, true, false, true, true, false, false, false, false, false, false, false, false, true, false, false);
            bool    b0 = (false);
            bool4x4 r0 = bool4x4(false, true, false, true, true, false, false, false, false, false, false, false, false, true, false, false);

            TestUtils.AreEqual(r0, a0 != b0);

            bool4x4 a1 = bool4x4(false, true, true, false, true, true, true, true, true, true, false, true, true, true, false, false);
            bool    b1 = (false);
            bool4x4 r1 = bool4x4(false, true, true, false, true, true, true, true, true, true, false, true, true, true, false, false);

            TestUtils.AreEqual(r1, a1 != b1);

            bool4x4 a2 = bool4x4(true, true, false, true, false, false, false, true, true, true, false, false, true, false, true, false);
            bool    b2 = (false);
            bool4x4 r2 = bool4x4(true, true, false, true, false, false, false, true, true, true, false, false, true, false, true, false);

            TestUtils.AreEqual(r2, a2 != b2);

            bool4x4 a3 = bool4x4(true, true, false, false, true, true, false, false, false, false, false, true, false, false, false, true);
            bool    b3 = (true);
            bool4x4 r3 = bool4x4(false, false, true, true, false, false, true, true, true, true, true, false, true, true, true, false);

            TestUtils.AreEqual(r3, a3 != b3);
        }
 public static void AreEqual(bool4x4 expected, bool4x4 actual)
 {
     AreEqual(expected.c0, actual.c0);
     AreEqual(expected.c1, actual.c1);
     AreEqual(expected.c2, actual.c2);
     AreEqual(expected.c3, actual.c3);
 }
Exemple #18
0
        public static void bool4x4_operator_bitwise_and_wide_wide()
        {
            bool4x4 a0 = bool4x4(false, false, true, true, false, false, true, true, true, false, true, true, true, true, false, false);
            bool4x4 b0 = bool4x4(false, false, true, false, true, true, false, false, true, true, false, false, false, false, true, false);
            bool4x4 r0 = bool4x4(false, false, true, false, false, false, false, false, true, false, false, false, false, false, false, false);

            TestUtils.AreEqual(r0, a0 & b0);

            bool4x4 a1 = bool4x4(true, true, true, false, true, true, false, true, true, false, true, true, true, false, false, true);
            bool4x4 b1 = bool4x4(true, false, true, true, true, true, true, true, true, true, true, false, false, false, true, false);
            bool4x4 r1 = bool4x4(true, false, true, false, true, true, false, true, true, false, true, false, false, false, false, false);

            TestUtils.AreEqual(r1, a1 & b1);

            bool4x4 a2 = bool4x4(true, false, false, true, true, false, true, false, false, false, true, false, false, true, false, true);
            bool4x4 b2 = bool4x4(false, true, true, true, false, true, true, false, true, true, false, false, false, true, true, true);
            bool4x4 r2 = bool4x4(false, false, false, true, false, false, true, false, false, false, false, false, false, true, false, true);

            TestUtils.AreEqual(r2, a2 & b2);

            bool4x4 a3 = bool4x4(false, false, true, true, false, false, false, false, false, true, false, true, false, false, true, true);
            bool4x4 b3 = bool4x4(false, true, false, false, false, true, true, false, false, false, false, false, true, false, false, true);
            bool4x4 r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, true);

            TestUtils.AreEqual(r3, a3 & b3);
        }
        public void double4x4_operator_not_equal_wide_scalar()
        {
            double4x4 a0 = double4x4(-16.914588697680529, 168.83411486858233, -462.71352145760949, 130.30776959765137, 214.50161443208424, -440.26328178879959, -197.12796053529155, -169.09985860115842, -386.61117595555783, -281.02101362916687, -270.26885593601912, -403.96372313236992, -269.80570877241234, 299.65422763473089, -71.750904831919286, -432.75573917513515);
            double    b0 = (-145.37277109239847);
            bool4x4   r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a0 != b0, r0);

            double4x4 a1 = double4x4(-457.36312100727258, 273.87305773136814, 185.042454567292, -482.53069351731364, 116.39514427836764, 511.73495578753523, 230.50753628020527, 100.27476768394683, 129.68240863163135, 321.17879048044733, -220.63900409482375, 140.33521921016984, 369.2123617461009, 453.81121489676241, -333.66624871532724, -373.93775218256644);
            double    b1 = (-13.519590622521719);
            bool4x4   r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a1 != b1, r1);

            double4x4 a2 = double4x4(150.20429451307484, 372.32001488856974, -95.837970539852051, 495.56669663617697, -5.385580780629823, -210.50298581388915, -459.61274812166243, 243.3090676010163, 314.10215702378287, 96.745011136282756, -168.16192944727931, -71.905446324453408, 216.60847983910162, -377.37381356646017, 142.35499841643264, -432.27255722148);
            double    b2 = (-442.16476627912596);
            bool4x4   r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a2 != b2, r2);

            double4x4 a3 = double4x4(94.290808959999481, 337.81056205267578, -197.66150746013108, -46.383895180366892, 250.232084629234, 169.099159081047, -181.22105773781476, -481.96699808629558, -427.18079419954717, -249.44207226924692, -488.48895644046786, 202.56492218867174, -243.82353770165867, -222.83222852592928, -448.60260722069188, 481.97402905019658);
            double    b3 = (331.65338889307031);
            bool4x4   r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(a3 != b3, r3);
        }
Exemple #20
0
        public static void bool4x4_operator_bitwise_or_wide_scalar()
        {
            bool4x4 a0 = bool4x4(true, true, false, true, true, true, true, false, true, false, false, true, false, false, true, false);
            bool    b0 = (true);
            bool4x4 r0 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(r0, a0 | b0);

            bool4x4 a1 = bool4x4(true, true, true, true, true, true, true, false, true, false, false, false, true, true, true, true);
            bool    b1 = (true);
            bool4x4 r1 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(r1, a1 | b1);

            bool4x4 a2 = bool4x4(true, false, true, false, false, true, false, true, false, true, true, false, true, true, false, true);
            bool    b2 = (true);
            bool4x4 r2 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(r2, a2 | b2);

            bool4x4 a3 = bool4x4(false, true, true, true, true, true, false, false, false, true, true, false, false, true, true, false);
            bool    b3 = (true);
            bool4x4 r3 = bool4x4(true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);

            TestUtils.AreEqual(r3, a3 | b3);
        }
        public void double4x4_operator_equal_wide_scalar()
        {
            double4x4 a0 = double4x4(-303.2300766926399, 451.52631327674089, -253.65587413201848, -105.20363502632995, -500.6910920090466, -426.19248338518315, 159.87609656149334, -59.558379439431405, -57.477391031327386, -182.0497396840014, 406.51375861024189, 370.88599866017978, -172.03530629539642, 455.40001198993991, -11.338988547836891, 363.93823044557973);
            double    b0 = (123.5445759871717);
            bool4x4   r0 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            double4x4 a1 = double4x4(-27.150561106927, -290.35904254129116, 180.19686635779067, -374.12832015293105, -439.35894295170851, -126.54608899287234, -197.2617896521752, -227.15933357326281, -479.8991937487848, -439.77767750237962, -495.23734902555, -224.51705013239621, -422.83322616239695, -450.19627043707123, -20.106708774392814, 297.37999906082632);
            double    b1 = (-325.97606507221985);
            bool4x4   r1 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            double4x4 a2 = double4x4(185.9665759475746, -220.59704910060253, -228.686854707397, -333.00125972041917, 434.2130317325765, 406.24874062382094, -239.86977707588568, 380.93927281952426, 90.349506658664723, -361.32792751925433, -453.59993836544453, 157.73248799039629, -491.04621457077855, 296.61425055964582, 482.26513432071783, -305.87698259292029);
            double    b2 = (-102.97598962810633);
            bool4x4   r2 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            double4x4 a3 = double4x4(-290.10212601819171, -110.52835588833705, 496.86356782208361, -441.10175653970884, 50.903518938880211, 66.072402269613235, 455.60591552015671, -390.04430145306713, 491.20810173973814, -498.41480588280353, 143.11344558704343, -347.0413293070352, -146.64416486893043, -243.85346924693022, -85.379532615365235, -438.4940004006466);
            double    b3 = (115.24653988482737);
            bool4x4   r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
Exemple #22
0
        public static void bool4x4_operator_bitwise_xor_scalar_wide()
        {
            bool    a0 = (true);
            bool4x4 b0 = bool4x4(true, false, true, true, false, true, true, false, false, true, true, false, false, true, false, true);
            bool4x4 r0 = bool4x4(false, true, false, false, true, false, false, true, true, false, false, true, true, false, true, false);

            TestUtils.AreEqual(r0, a0 ^ b0);

            bool    a1 = (true);
            bool4x4 b1 = bool4x4(false, true, true, true, false, false, false, true, true, true, false, false, false, true, true, false);
            bool4x4 r1 = bool4x4(true, false, false, false, true, true, true, false, false, false, true, true, true, false, false, true);

            TestUtils.AreEqual(r1, a1 ^ b1);

            bool    a2 = (true);
            bool4x4 b2 = bool4x4(false, false, true, true, true, true, false, false, false, true, false, false, false, true, true, false);
            bool4x4 r2 = bool4x4(true, true, false, false, false, false, true, true, true, false, true, true, true, false, false, true);

            TestUtils.AreEqual(r2, a2 ^ b2);

            bool    a3 = (false);
            bool4x4 b3 = bool4x4(false, true, true, true, true, true, true, true, true, true, false, false, true, false, true, false);
            bool4x4 r3 = bool4x4(false, true, true, true, true, true, true, true, true, true, false, false, true, false, true, false);

            TestUtils.AreEqual(r3, a3 ^ b3);
        }
        public void double4x4_operator_equal_wide_wide()
        {
            double4x4 a0 = double4x4(492.15758275061728, -495.20632027797694, 227.45765195947968, -147.37405950733182, -222.68201909897942, 64.093720704360749, -23.890404473939157, -16.8197190839889, 163.23210890741655, -165.27101071424363, 470.87767980568003, -423.94255967808078, 109.63436918595539, 462.69031283943468, -335.38147727371262, 357.23446934168896);
            double4x4 b0 = double4x4(192.56880888369346, -235.61102472786376, -254.04311740307281, -412.62472052715009, 471.90480945627428, -6.4727852374654162, -339.10237447316865, 488.1875700839737, -379.5965842584132, -308.41700258311675, -82.333374300195544, -102.92108087563935, 226.51573835430463, -356.90132896830391, -362.91277544708589, -427.89843746083716);
            bool4x4   r0 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            double4x4 a1 = double4x4(1.5455777652308598, -347.38824741327585, -114.47217302884542, 435.84865804940864, 194.23808607563285, 138.76554710174241, -467.34914205379278, 370.43337767684523, 476.70826147343416, 320.55264702465047, -498.59197377534207, 92.4169581366782, 104.51136856177425, 166.75460608618084, -204.73343024250744, 434.75675674656259);
            double4x4 b1 = double4x4(466.65013978753711, -102.79904680270658, -43.355954428834821, 85.045664111639212, -91.127054972167628, 422.19208856215334, -477.43130873024057, 1.8770024785198984, 312.5800799394865, 254.59934365684137, 352.72583763335172, 62.490957050812881, 119.71476059766246, -511.05808639482507, -302.47273053902791, -371.76924365189359);
            bool4x4   r1 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            double4x4 a2 = double4x4(-397.32965988541469, 503.98163699730378, -503.7141270598928, 90.659743112819115, -303.4452423078219, 9.3449113412503948, 290.9010785980621, -147.57193882184657, 368.08236067745941, -321.60959044173808, -171.4654224717363, -441.30646368549503, -137.76681834914109, 304.68958463551928, 301.88943948498434, -222.22090564585335);
            double4x4 b2 = double4x4(-20.007841834802093, 21.459455738523729, -426.02067228128232, -305.41193666374863, 261.68332517411716, 50.0047347778476, -334.13464824023407, 75.065677916196023, -51.186689639085273, -135.96155721319911, -409.36487431515235, 160.81974013187914, 102.12079553591127, 277.81306637349212, 434.90674444423371, -15.289183385339186);
            bool4x4   r2 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            double4x4 a3 = double4x4(-13.883811718730158, 307.52174844756803, -469.41294572754435, -6.4088704615872416, -290.07966317333262, 46.04458596466327, -168.61907370789862, 283.58987845275078, -244.71330058049097, -367.14044707228447, -492.86314009728989, 311.69617881984277, -90.701378149307061, -352.77372591233518, -218.71025691680154, -95.301376148733027);
            double4x4 b3 = double4x4(-1.4652092463640543, 64.658699781009318, -163.0260780616785, 390.72893375471654, 113.9645836883991, -248.27529894945923, -469.58777664116946, -73.353983197991738, -420.31107183001518, 358.45325939657789, 58.718313959761645, -499.96478557026239, -168.83810313457536, -93.834922595804073, 324.846676739327, -226.35198675205555);
            bool4x4   r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }
Exemple #24
0
        public static void bool4x4_operator_equal_scalar_wide()
        {
            bool    a0 = (false);
            bool4x4 b0 = bool4x4(true, false, true, false, false, true, false, false, true, false, true, true, false, true, false, true);
            bool4x4 r0 = bool4x4(false, true, false, true, true, false, true, true, false, true, false, false, true, false, true, false);

            TestUtils.AreEqual(r0, a0 == b0);

            bool    a1 = (true);
            bool4x4 b1 = bool4x4(true, false, false, true, false, true, true, false, true, true, true, true, true, true, false, true);
            bool4x4 r1 = bool4x4(true, false, false, true, false, true, true, false, true, true, true, true, true, true, false, true);

            TestUtils.AreEqual(r1, a1 == b1);

            bool    a2 = (true);
            bool4x4 b2 = bool4x4(false, false, false, true, true, true, false, true, true, true, false, false, true, false, true, true);
            bool4x4 r2 = bool4x4(false, false, false, true, true, true, false, true, true, true, false, false, true, false, true, true);

            TestUtils.AreEqual(r2, a2 == b2);

            bool    a3 = (false);
            bool4x4 b3 = bool4x4(false, false, false, true, true, true, true, false, false, true, false, true, false, false, false, false);
            bool4x4 r3 = bool4x4(true, true, true, false, false, false, false, true, true, false, true, false, true, true, true, true);

            TestUtils.AreEqual(r3, a3 == b3);
        }
Exemple #25
0
        public void bool4x4_operator_bitwise_and_wide_wide()
        {
            bool4x4 a0 = bool4x4(false, false, true, true, false, false, true, true, true, false, true, true, true, true, false, false);
            bool4x4 b0 = bool4x4(false, false, true, false, true, true, false, false, true, true, false, false, false, false, true, false);
            bool4x4 r0 = bool4x4(false, false, true, false, false, false, false, false, true, false, false, false, false, false, false, false);

            TestUtils.AreEqual(a0 & b0, r0);

            bool4x4 a1 = bool4x4(true, true, true, false, true, true, false, true, true, false, true, true, true, false, false, true);
            bool4x4 b1 = bool4x4(true, false, true, true, true, true, true, true, true, true, true, false, false, false, true, false);
            bool4x4 r1 = bool4x4(true, false, true, false, true, true, false, true, true, false, true, false, false, false, false, false);

            TestUtils.AreEqual(a1 & b1, r1);

            bool4x4 a2 = bool4x4(true, false, false, true, true, false, true, false, false, false, true, false, false, true, false, true);
            bool4x4 b2 = bool4x4(false, true, true, true, false, true, true, false, true, true, false, false, false, true, true, true);
            bool4x4 r2 = bool4x4(false, false, false, true, false, false, true, false, false, false, false, false, false, true, false, true);

            TestUtils.AreEqual(a2 & b2, r2);

            bool4x4 a3 = bool4x4(false, false, true, true, false, false, false, false, false, true, false, true, false, false, true, true);
            bool4x4 b3 = bool4x4(false, true, false, false, false, true, true, false, false, false, false, false, true, false, false, true);
            bool4x4 r3 = bool4x4(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, true);

            TestUtils.AreEqual(a3 & b3, r3);
        }
        public static void bool4x4_operator_equal_wide_scalar()
        {
            bool4x4 a0 = bool4x4(true, true, false, true, true, false, true, true, true, false, false, false, false, true, false, false);
            bool    b0 = (false);
            bool4x4 r0 = bool4x4(false, false, true, false, false, true, false, false, false, true, true, true, true, false, true, true);

            TestUtils.AreEqual(a0 == b0, r0);

            bool4x4 a1 = bool4x4(false, true, true, false, false, true, false, true, false, true, false, true, false, false, true, false);
            bool    b1 = (false);
            bool4x4 r1 = bool4x4(true, false, false, true, true, false, true, false, true, false, true, false, true, true, false, true);

            TestUtils.AreEqual(a1 == b1, r1);

            bool4x4 a2 = bool4x4(true, false, false, false, false, false, true, false, true, true, false, false, false, true, true, true);
            bool    b2 = (true);
            bool4x4 r2 = bool4x4(true, false, false, false, false, false, true, false, true, true, false, false, false, true, true, true);

            TestUtils.AreEqual(a2 == b2, r2);

            bool4x4 a3 = bool4x4(false, true, false, false, false, false, true, true, true, true, true, false, true, false, true, false);
            bool    b3 = (false);
            bool4x4 r3 = bool4x4(true, false, true, true, true, true, false, false, false, false, false, true, false, true, false, true);

            TestUtils.AreEqual(a3 == b3, r3);
        }
Exemple #27
0
        public void bool4x4_operator_bitwise_xor_scalar_wide()
        {
            bool    a0 = (true);
            bool4x4 b0 = bool4x4(true, false, true, true, false, true, true, false, false, true, true, false, false, true, false, true);
            bool4x4 r0 = bool4x4(false, true, false, false, true, false, false, true, true, false, false, true, true, false, true, false);

            TestUtils.AreEqual(a0 ^ b0, r0);

            bool    a1 = (true);
            bool4x4 b1 = bool4x4(false, true, true, true, false, false, false, true, true, true, false, false, false, true, true, false);
            bool4x4 r1 = bool4x4(true, false, false, false, true, true, true, false, false, false, true, true, true, false, false, true);

            TestUtils.AreEqual(a1 ^ b1, r1);

            bool    a2 = (true);
            bool4x4 b2 = bool4x4(false, false, true, true, true, true, false, false, false, true, false, false, false, true, true, false);
            bool4x4 r2 = bool4x4(true, true, false, false, false, false, true, true, true, false, true, true, true, false, false, true);

            TestUtils.AreEqual(a2 ^ b2, r2);

            bool    a3 = (false);
            bool4x4 b3 = bool4x4(false, true, true, true, true, true, true, true, true, true, false, false, true, false, true, false);
            bool4x4 r3 = bool4x4(false, true, true, true, true, true, true, true, true, true, false, false, true, false, true, false);

            TestUtils.AreEqual(a3 ^ b3, r3);
        }
        static void TestInt4x4_Select_WorksCorrectly()
        {
            var zero        = int4x4.zero;
            var identity    = int4x4.identity;
            var one         = (int4x4)1;
            var zebraLoInts = new int4x4(1, 0, 1, 0);
            var zebraHiInts = new int4x4(0, 1, 0, 1);

            var zebraLoIdentity = new int4x4(new int4(1, 0, 0, 0), 0, new int4(0, 0, 1, 0), 0);
            var zebraHiIdentity = new int4x4(0, new int4(0, 1, 0, 0), 0, new int4(0, 0, 0, 1));

            var t = new bool4x4(true);
            var f = new bool4x4(false);

            var zebraLo = new bool4x4(true, false, true, false);
            var zebraHi = new bool4x4(false, true, false, true);

            Validate(Maths.Select(zero, one, f), zero);
            Validate(Maths.Select(zero, one, t), one);
            Validate(Maths.Select(zero, one, zebraLo), zebraLoInts);
            Validate(Maths.Select(zero, one, zebraHi), zebraHiInts);

            Validate(Maths.Select(zero, identity, f), zero);
            Validate(Maths.Select(zero, identity, t), identity);
            Validate(Maths.Select(zero, identity, zebraLo), zebraLoIdentity);
            Validate(Maths.Select(zero, identity, zebraHi), zebraHiIdentity);
        }
Exemple #29
0
        public void bool4x4_operator_not_equal_wide_wide()
        {
            bool4x4 a0 = bool4x4(true, true, true, false, false, true, false, false, false, false, true, true, true, true, true, true);
            bool4x4 b0 = bool4x4(true, false, false, false, true, false, false, false, false, true, true, true, false, false, true, true);
            bool4x4 r0 = bool4x4(false, true, true, false, true, true, false, false, false, true, false, false, true, true, false, false);

            TestUtils.AreEqual(a0 != b0, r0);

            bool4x4 a1 = bool4x4(true, true, false, true, false, true, true, true, true, false, false, true, false, true, true, true);
            bool4x4 b1 = bool4x4(true, false, true, true, false, false, true, false, false, false, true, false, true, false, true, false);
            bool4x4 r1 = bool4x4(false, true, true, false, false, true, false, true, true, false, true, true, true, true, false, true);

            TestUtils.AreEqual(a1 != b1, r1);

            bool4x4 a2 = bool4x4(true, true, false, true, true, true, true, false, true, true, true, false, true, false, false, false);
            bool4x4 b2 = bool4x4(false, false, false, false, false, true, false, true, false, true, false, false, false, true, false, false);
            bool4x4 r2 = bool4x4(true, true, false, true, true, false, true, true, true, false, true, false, true, true, false, false);

            TestUtils.AreEqual(a2 != b2, r2);

            bool4x4 a3 = bool4x4(true, false, false, true, false, true, true, true, true, true, false, false, true, false, false, false);
            bool4x4 b3 = bool4x4(true, true, true, false, true, false, false, true, false, false, false, true, true, false, false, false);
            bool4x4 r3 = bool4x4(false, true, true, true, true, true, true, false, true, true, false, true, false, false, false, false);

            TestUtils.AreEqual(a3 != b3, r3);
        }
        public void float4x4_operator_equal_scalar_wide()
        {
            float    a0 = (-253.397278f);
            float4x4 b0 = float4x4(19.95221f, -185.791992f, 407.8136f, -87.2767f);
            bool4x4  r0 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a0 == b0, r0);

            float    a1 = (-206.274689f);
            float4x4 b1 = float4x4(160.503113f, -274.7708f, -2.63153076f, 448.354553f);
            bool4x4  r1 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a1 == b1, r1);

            float    a2 = (-410.035248f);
            float4x4 b2 = float4x4(247.329041f, 355.539124f, -298.0667f, 414.1015f);
            bool4x4  r2 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a2 == b2, r2);

            float    a3 = (-481.3026f);
            float4x4 b3 = float4x4(196.55072f, 34.6010132f, 113.7616f, -386.453369f);
            bool4x4  r3 = bool4x4(false, false, false, false);

            TestUtils.AreEqual(a3 == b3, r3);
        }