Skip to main content

UVec2

Struct UVec2 

Source
#[repr(C)]
pub struct UVec2 { pub x: u32, pub y: u32, }
Expand description

A 2-dimensional vector.

Fields§

§x: u32§y: u32

Implementations§

Source§

impl UVec2

Source

pub const ZERO: UVec2

All zeroes.

Source

pub const ONE: UVec2

All ones.

Source

pub const MIN: UVec2

All u32::MIN.

Source

pub const MAX: UVec2

All u32::MAX.

Source

pub const X: UVec2

A unit vector pointing along the positive X axis.

Source

pub const Y: UVec2

A unit vector pointing along the positive Y axis.

Source

pub const AXES: [UVec2; 2]

The unit axes.

Source

pub const fn new(x: u32, y: u32) -> UVec2

Creates a new vector.

Examples found in repository?
examples/material-playground.rs (line 66)
66const MAP_SIZE: UVec2 = UVec2::new(64, 64);
More examples
Hide additional examples
examples/isometric-board.rs (line 717)
716fn sprite_frame(facing_right: bool) -> Frame {
717    let cell = Sheet::new(UVec2::new(SPRITE_COLUMNS, SPRITE_ROWS))
718        .cell_at(UVec2::new(SPRITE_COLUMN, SPRITE_ROW));
719    if facing_right { cell } else { cell.mirrored() }
720}
examples/sprite-adventure.rs (line 916)
905fn ground_cell(col: i32, row: i32) -> Frame {
906    let (column, sheet_row) = match col - PATH_COLUMN {
907        0 => (PATH_DIRT + row.rem_euclid(2) as u32, PATH_ROW),
908        -1 => (PATH_WEST_VERGE, PATH_ROW),
909        1 => (PATH_EAST_VERGE, PATH_ROW),
910        _ => (
911            (col * 31 + row * 17).rem_euclid(GROUND_COLUMNS as i32) as u32,
912            GRASS_ROW,
913        ),
914    };
915
916    Sheet::new(UVec2::new(GROUND_COLUMNS, GROUND_ROWS)).cell_at(UVec2::new(column, sheet_row))
917}
918
919/// The stone sheet's plain masonry, laid `tiles` times across: the sampler
920/// wraps, so a window wider than the sheet repeats the course.
921fn masonry(tiles: f32) -> Frame {
922    let course = 1.0 / STONE_ROWS as f32;
923
924    Frame::rect(Vec2::new(0.0, 1.0 - course), Vec2::new(tiles, 1.0))
925}
926
927/// The wall or door's alpha `fraction` of the way from [`SOLID`] to
928/// [`GHOST_ALPHA`].
929fn ghost_alpha(fraction: f32) -> f32 {
930    SOLID + (GHOST_ALPHA - SOLID) * fraction
931}
932
933/// The wall face in column `variant`, windowed to the meters `standing` of
934/// one course, measured up from that course's own base: every row of the
935/// cave sheet below the floor's covers [`WALL_HEIGHT`], so a course keeps
936/// the floor's texels to the meter however it is cut.
937fn cave_wall_face(variant: u32, standing: Range<f32>) -> Frame {
938    let cell = Vec2::new(1.0 / CAVE_COLUMNS as f32, 1.0 / CAVE_ROWS as f32);
939    let left = (variant % CAVE_COLUMNS) as f32 * cell.x;
940    let face = (CAVE_FLOOR_ROW + 1) as f32 * cell.y;
941    let up_from_base = |height: f32| 1.0 - (1.0 - face) * (height / WALL_HEIGHT);
942
943    Frame::rect(
944        Vec2::new(left, up_from_base(standing.end)),
945        Vec2::new(left + cell.x, up_from_base(standing.start)),
946    )
947}
948
949/// The logical point egui paints the physical pixel `pixel` at.
950fn logical(pixel: Vec2, pixels_per_point: f32) -> egui::Pos2 {
951    let point = pixel / pixels_per_point;
952    egui::pos2(point.x, point.y)
953}
954
955fn main() {
956    run(
957        Config::new("Mirage: sprite adventure")
958            .with_size(1280, 720)
959            .with_assets([
960                MODEL,
961                WALKER_SOURCE,
962                WALKER_RELIEF_SOURCE,
963                GROUND_SOURCE,
964                BUSH_SOURCE,
965                BUSH_RELIEF_SOURCE,
966                ROCK_SOURCE,
967                ROCK_RELIEF_SOURCE,
968                TORCH_RELIEF_SOURCE,
969                CRATE_SOURCE,
970                WELL_SOURCE,
971                STONE_SOURCE,
972                CAVE_SOURCE,
973                POND_SOURCE,
974                TORCH_SOURCE,
975                FLAME_SOURCE,
976                INTERACT_SOUND,
977                GEM_SOUND,
978            ]),
979        Keep::init,
980    );
981}
982
983struct Keep {
984    area: Area,
985    position: Vec3,
986    previous: Vec3,
987    facing: Facing,
988    walk_ticks: u32,
989    simulated: Duration,
990    door_opening: bool,
991    /// Ticks the door has been opening for, at a cap of
992    /// [`DOOR_SWING_TICKS`]: how long its world prompt reads "opening" once
993    /// it starts.
994    swing_ticks: u32,
995    gem_taken: bool,
996    /// How far the door wall's fade from [`SOLID`] to [`GHOST_ALPHA`] has
997    /// run as of the last tick: `0.0` to `1.0`.
998    ghost: f32,
999    /// Set by the panel's reset button, since its click lands in a frame
1000    /// rather than a tick; read and cleared on the next tick.
1001    reset_requested: bool,
1002}
1003
1004impl Keep {
1005    /// Prepares every startup-cataloged mesh and resumes wherever the last
1006    /// run left the player.
1007    fn init(ctx: &mut InitContext<'_, Keep>) -> Result<Self, Error> {
1008        let startup = ctx.startup();
1009        let gem_taken = startup.saved(Flag::GemTaken);
1010        let area = if startup.saved(Flag::InCave) {
1011            Area::Cave
1012        } else {
1013            Area::Overworld
1014        };
1015        let position = Vec3::new(
1016            startup.saved(Position::X) as f32,
1017            0.0,
1018            startup.saved(Position::Z) as f32,
1019        );
1020
1021        Ok(Self {
1022            area,
1023            position,
1024            previous: position,
1025            facing: Facing::Toward,
1026            walk_ticks: 0,
1027            simulated: Duration::ZERO,
1028            door_opening: gem_taken,
1029            swing_ticks: if gem_taken { DOOR_SWING_TICKS } else { 0 },
1030            gem_taken,
1031            ghost: 0.0,
1032            reset_requested: false,
1033        })
1034    }
1035
1036    fn camera(position: Vec3, offset: Vec3) -> Camera {
1037        Camera::new(
1038            View::look_at(position + offset, position),
1039            Projection::perspective(CAMERA_FOV),
1040        )
1041    }
1042
1043    /// Obstacles from the overworld's props: the crates, turned as they are
1044    /// drawn, the well's rim, the open water the shoreline rings, the
1045    /// mouth's pillars, and each flora's base.
1046    fn overworld_obstacles() -> impl Iterator<Item = Obstacle> + Clone {
1047        CRATE_POSITIONS
1048            .into_iter()
1049            .map(|(x, z, turn)| {
1050                Obstacle::footprint(Vec2::new(x, z), Vec2::splat(CRATE_SIZE * turned_span(turn)))
1051            })
1052            .chain([
1053                Obstacle::footprint(WELL_POSITION.xz(), WELL_SIZE.xz()),
1054                Obstacle::footprint(POND_CENTER.xz(), Vec2::splat(POND_WATER_HALF * 2.0)),
1055            ])
1056            .chain(
1057                ENTRANCE
1058                    .pillars()
1059                    .map(|at| Obstacle::footprint(at.xz(), MOUTH_PILLAR_SIZE.xz())),
1060            )
1061            .chain(FLORA.into_iter().map(|(x, z, rock)| {
1062                let base = if rock { ROCK_FOOTPRINT } else { BUSH_FOOTPRINT };
1063                Obstacle::footprint(Vec2::new(x, z), Vec2::splat(base))
1064            }))
1065    }
1066
1067    /// Obstacles from the cave: the torch posts, its own mouth's pillars,
1068    /// the runs of wall either side of the doorway and of the mouth, and the
1069    /// `door` leaf.
1070    fn cave_obstacles(door: Obstacle) -> impl Iterator<Item = Obstacle> + Clone {
1071        TORCH_POSITIONS
1072            .into_iter()
1073            .map(|(x, z)| Obstacle::footprint(Vec2::new(x, z), Vec2::splat(TORCH_STAND_WIDTH)))
1074            .chain(
1075                EXIT.pillars()
1076                    .map(|at| Obstacle::footprint(at.xz(), MOUTH_PILLAR_SIZE.xz())),
1077            )
1078            .chain(SIDES.into_iter().flat_map(|side| {
1079                [
1080                    Self::wall_run(side, DOOR_Z),
1081                    Self::wall_run(side, CAVE_LIP_Z),
1082                ]
1083            }))
1084            .chain([door])
1085    }
1086
1087    /// One of the two runs of wall either side of a one-tile opening on the
1088    /// room's axis, at `z`.
1089    fn wall_run(side: f32, z: f32) -> Obstacle {
1090        Obstacle::footprint(
1091            Vec2::new(side * (DOORWAY_HALF + DOOR_WALL_END) * 0.5, z),
1092            Vec2::new(DOOR_WALL_END - DOORWAY_HALF, TILE_SIZE),
1093        )
1094    }
1095
1096    /// Obstacle from the door leaf's own footprint: the box over its four
1097    /// corners, swung back against the wall once the door is opened.
1098    fn door_obstacle(&self) -> Obstacle {
1099        let hinge = DOOR_HINGE.xz();
1100        let across = DOOR_THICKNESS * 0.5;
1101        let corner = |along: f32, aside: f32| {
1102            let (x, z) = if self.door_opening {
1103                (aside, -along)
1104            } else {
1105                (along, aside)
1106            };
1107            hinge + Vec3::new(x, 0.0, z).xz()
1108        };
1109
1110        Obstacle::over([
1111            corner(0.0, -across),
1112            corner(0.0, across),
1113            corner(DOOR_WIDTH, -across),
1114            corner(DOOR_WIDTH, across),
1115        ])
1116    }
1117
1118    /// Pushes the player out of every obstacle their circle has walked into,
1119    /// over as many passes as it takes for one to leave them where the last
1120    /// one did — overlapping obstacles need more than one.
1121    fn push_out_of(&mut self, obstacles: impl Iterator<Item = Obstacle> + Clone) {
1122        /// Passes an overlap is given to settle before the frame takes what
1123        /// it has; ones this game builds settle in two.
1124        const PASSES: u32 = 4;
1125
1126        let mut standing = self.position.xz();
1127        for _ in 0..PASSES {
1128            let settled = obstacles.clone().fold(standing, |point, obstacle| {
1129                obstacle.push_out(point, PLAYER_RADIUS)
1130            });
1131            if settled == standing {
1132                break;
1133            }
1134            standing = settled;
1135        }
1136
1137        self.position.x = standing.x;
1138        self.position.z = standing.y;
1139    }
1140
1141    fn tick_overworld(&mut self, ctx: &mut TickContext<'_, Keep>) {
1142        self.push_out_of(Self::overworld_obstacles());
1143        self.position.x = self.position.x.clamp(-CLEARING_HALF, CLEARING_HALF);
1144        self.position.z = self.position.z.clamp(-CLEARING_HALF, CLEARING_HALF);
1145
1146        if ENTRANCE.holds(self.position) {
1147            if ENTRANCE.holds(self.previous) {
1148                self.position.z = self.previous.z;
1149            } else {
1150                self.enter_cave(ctx);
1151            }
1152        }
1153    }
1154
1155    fn tick_cave(&mut self, ctx: &mut TickContext<'_, Keep>) {
1156        self.push_out_of(Self::cave_obstacles(self.door_obstacle()));
1157        self.position.x = self.position.x.clamp(-CAVE_HALF_WIDTH, CAVE_HALF_WIDTH);
1158        self.position.z = self.position.z.clamp(CAVE_WALK_FAR_Z, CAVE_WALK_NEAR_Z);
1159
1160        let target = if self.position.z < DOOR_WALL_NEAR_Z {
1161            1.0
1162        } else {
1163            0.0
1164        };
1165        let step = 1.0 / GHOST_RAMP_TICKS as f32;
1166        self.ghost += (target - self.ghost).clamp(-step, step);
1167
1168        if !self.door_opening
1169            && ctx.pressed(Button::Interact)
1170            && self.position.distance(INTERACT_POINT) < INTERACT_RADIUS
1171        {
1172            self.door_opening = true;
1173            self.swing_ticks = 0;
1174            ctx.play(Sound::Interact);
1175        }
1176        if self.door_opening && self.swing_ticks < DOOR_SWING_TICKS {
1177            self.swing_ticks += 1;
1178        }
1179
1180        if !self.gem_taken && self.position.distance(GEM_POSITION) < PICKUP_RADIUS {
1181            self.gem_taken = true;
1182            ctx.play(Sound::Gem);
1183            ctx.save(Flag::GemTaken, true);
1184            ctx.save(Position::X, self.position.x as f64);
1185            ctx.save(Position::Z, self.position.z as f64);
1186        }
1187
1188        if EXIT.holds(self.position) {
1189            if EXIT.holds(self.previous) {
1190                self.position.z = self.previous.z;
1191            } else {
1192                self.exit_cave(ctx);
1193            }
1194        }
1195    }
1196
1197    /// Puts the player back at [`PLAYER_SPAWN`] with the cave and the gem
1198    /// returned to their saved fallbacks, all in this tick: a reset saves
1199    /// every key's own fallback, since there is nothing to clear it to.
1200    fn reset(&mut self, ctx: &mut TickContext<'_, Keep>) {
1201        ctx.save(Position::X, Position::X.fallback());
1202        ctx.save(Position::Z, Position::Z.fallback());
1203        ctx.save(Flag::InCave, Flag::InCave.fallback());
1204        ctx.save(Flag::GemTaken, Flag::GemTaken.fallback());
1205
1206        self.area = Area::Overworld;
1207        self.position = PLAYER_SPAWN;
1208        self.previous = PLAYER_SPAWN;
1209        self.gem_taken = false;
1210        self.door_opening = false;
1211        self.swing_ticks = 0;
1212        self.ghost = 0.0;
1213    }
1214
1215    /// Steps into the cave at [`CAVE_SPAWN`], saving the transition.
1216    fn enter_cave(&mut self, ctx: &mut TickContext<'_, Keep>) {
1217        self.area = Area::Cave;
1218        self.position = CAVE_SPAWN;
1219        self.previous = CAVE_SPAWN;
1220        ctx.save(Flag::InCave, true);
1221        ctx.save(Position::X, CAVE_SPAWN.x as f64);
1222        ctx.save(Position::Z, CAVE_SPAWN.z as f64);
1223    }
1224
1225    /// Steps back out to the mouth at [`RETURN_SPAWN`], saving the
1226    /// transition.
1227    fn exit_cave(&mut self, ctx: &mut TickContext<'_, Keep>) {
1228        self.area = Area::Overworld;
1229        self.position = RETURN_SPAWN;
1230        self.previous = RETURN_SPAWN;
1231        ctx.save(Flag::InCave, false);
1232        ctx.save(Position::X, RETURN_SPAWN.x as f64);
1233        ctx.save(Position::Z, RETURN_SPAWN.z as f64);
1234    }
1235
1236    fn draw_ground(&self, ctx: &mut FrameContext<'_, Keep>) {
1237        for col in -GROUND_DRAW_HALF..=GROUND_DRAW_HALF {
1238            for row in -GROUND_DRAW_HALF..=GROUND_DRAW_HALF {
1239                ctx.draw(
1240                    Ground
1241                        .at(Vec3::new(
1242                            col as f32 * TILE_SIZE,
1243                            0.0,
1244                            row as f32 * TILE_SIZE,
1245                        ))
1246                        .frame(ground_cell(col, row)),
1247                );
1248            }
1249        }
1250    }
1251
1252    /// Two staggered rows of bushes around the clearing, open where the path
1253    /// leaves it, drawn between the camera and the ground's edge. The rows
1254    /// running along `Z` skip their two ends, which the rows running along
1255    /// `X` already cover.
1256    fn draw_hedgerow(&self, ctx: &mut FrameContext<'_, Keep>) {
1257        for (row, half) in [HEDGE_INNER_HALF, HEDGE_OUTER_HALF].into_iter().enumerate() {
1258            let row = row as i32;
1259            // The inner row covers both corners; the outer one is half a
1260            // span in from each, backing the gaps the inner row leaves.
1261            let spans = ((2.0 * half / HEDGE_STEP).round() as i32).max(1);
1262            let span = 2.0 * half / spans as f32;
1263            let steps = spans - row;
1264            for step in 0..=steps {
1265                let along = -half + (step as f32 + 0.5 * row as f32) * span;
1266                let scale = if (step + row) % 2 == 0 { 1.0 } else { 0.8 };
1267                let (width, height) = (BUSH_WIDTH * scale, BUSH_HEIGHT * scale);
1268                // The path leaves through the rows running along `X`, so only
1269                // those two open around it.
1270                let gated = along.abs() < HEDGE_GATE_HALF;
1271                let corner = step == 0 || step == steps;
1272                let places = [
1273                    (along, -half, gated),
1274                    (along, half, gated),
1275                    (-half, along, corner),
1276                    (half, along, corner),
1277                ];
1278                for (x, z, skip) in places {
1279                    if skip {
1280                        continue;
1281                    }
1282                    ctx.draw(
1283                        Bush.at(Transform::from_scale_rotation_translation(
1284                            Vec3::new(width, height, width),
1285                            Quat::IDENTITY,
1286                            Vec3::new(x, height * 0.5, z),
1287                        ))
1288                        .upright(),
1289                    );
1290                }
1291            }
1292        }
1293    }
1294
1295    /// The pond: a square of styled water, and the shoreline sprite laid over
1296    /// it, which rings the open middle and hides the water's own edges.
1297    fn draw_pond(&self, ctx: &mut FrameContext<'_, Keep>) {
1298        ctx.draw(
1299            Plane
1300                .at(Transform::from_scale_rotation_translation(
1301                    Vec3::splat(POND_WATER_HALF * 2.0),
1302                    Quat::IDENTITY,
1303                    POND_CENTER,
1304                ))
1305                .material(Material::shaded(WATER_COLOR, WATER_LITNESS))
1306                .surface_style::<Water>(),
1307        );
1308        ctx.draw(
1309            Shore
1310                .at(Transform::from_scale_rotation_translation(
1311                    Vec3::splat(POND_HALF * 2.0),
1312                    Quat::IDENTITY,
1313                    Vec3::new(POND_CENTER.x, 0.0, POND_CENTER.z),
1314                ))
1315                .frame(Sheet::new(UVec2::new(POND_CELLS, 1)).cell(POND_SHORE_CELL)),
1316        );
1317    }
1318
1319    fn draw_crates(&self, ctx: &mut FrameContext<'_, Keep>) {
1320        for &(x, z, turn) in &CRATE_POSITIONS {
1321            ctx.draw(Crate.at(Transform::from_scale_rotation_translation(
1322                Vec3::splat(CRATE_SIZE),
1323                Quat::from_rotation_y(turn),
1324                Vec3::new(x, CRATE_SIZE * 0.5, z),
1325            )));
1326        }
1327    }
1328
1329    /// The well: its rim in grey masonry, and the mouth cell laid over the
1330    /// rim's top face.
1331    fn draw_well(&self, ctx: &mut FrameContext<'_, Keep>) {
1332        let cells = Sheet::new(UVec2::new(WELL_CELLS, 1));
1333        ctx.draw(
1334            Well.at(Transform::from_scale_rotation_translation(
1335                WELL_SIZE,
1336                Quat::IDENTITY,
1337                WELL_POSITION + Vec3::Y * (WELL_SIZE.y * 0.5),
1338            ))
1339            .frame(cells.cell(WELL_RIM_CELL)),
1340        );
1341        ctx.draw(
1342            WellMouth
1343                .at(Transform::from_scale_rotation_translation(
1344                    Vec3::new(WELL_SIZE.x, 1.0, WELL_SIZE.z),
1345                    Quat::IDENTITY,
1346                    WELL_POSITION + Vec3::Y * (WELL_SIZE.y + WELL_MOUTH_LIFT),
1347                ))
1348                .frame(cells.cell(WELL_MOUTH_CELL)),
1349        );
1350    }
1351
1352    fn draw_flora(&self, ctx: &mut FrameContext<'_, Keep>) {
1353        for &(x, z, rock) in &FLORA {
1354            let (width, height) = if rock {
1355                (ROCK_WIDTH, ROCK_HEIGHT)
1356            } else {
1357                (BUSH_WIDTH, BUSH_HEIGHT)
1358            };
1359            let standing = Transform::from_scale_rotation_translation(
1360                Vec3::new(width, height, width),
1361                Quat::IDENTITY,
1362                Vec3::new(x, height * 0.5, z),
1363            );
1364            let flora: Instance<Shape, _> = if rock {
1365                Rock.at(standing).into_set()
1366            } else {
1367                Bush.at(standing).into_set()
1368            };
1369            ctx.draw(flora.upright());
1370        }
1371    }
1372
1373    /// One stone box drawn on the ground at `at`, `size` across, sampling
1374    /// the part of the sheet `frame` covers.
1375    fn draw_stone(ctx: &mut FrameContext<'_, Keep>, at: Vec3, size: Vec3, frame: Frame) {
1376        ctx.draw(
1377            Stone
1378                .at(Transform::from_scale_rotation_translation(
1379                    size,
1380                    Quat::IDENTITY,
1381                    at + Vec3::Y * (size.y * 0.5),
1382                ))
1383                .frame(frame),
1384        );
1385    }
1386
1387    /// Two stone pillars drawn where `mouth` blocks the player, each a
1388    /// capital over its own course of masonry, and, on the one the camera
1389    /// looks into, the lintel across their tops and the dark filling
1390    /// the opening under it.
1391    fn draw_mouth(ctx: &mut FrameContext<'_, Keep>, mouth: Mouth) {
1392        for at in mouth.pillars() {
1393            Self::draw_stone(ctx, at, MOUTH_PILLAR_SIZE, Frame::default());
1394        }
1395        if !mouth.looked_into() {
1396            return;
1397        }
1398
1399        Self::draw_stone(
1400            ctx,
1401            mouth.at + Vec3::Y * MOUTH_PILLAR_SIZE.y,
1402            MOUTH_LINTEL_SIZE,
1403            masonry(MOUTH_LINTEL_TILES),
1404        );
1405        ctx.draw(
1406            Quad.at(Transform::from_scale_rotation_translation(
1407                Vec3::new(MOUTH_PILLAR_OFFSET * 2.0, MOUTH_DARK_HEIGHT, 1.0),
1408                Quat::IDENTITY,
1409                mouth.at + Vec3::Y * (MOUTH_DARK_HEIGHT * 0.5),
1410            ))
1411            .material(Material::color(Color::BLACK)),
1412        );
1413    }
1414
1415    fn draw_cave_floor(&self, ctx: &mut FrameContext<'_, Keep>) {
1416        let half = CAVE_HALF_WIDTH as i32;
1417        let near = CAVE_NEAR_Z as i32;
1418        let far = CAVE_FAR_Z as i32;
1419        for col in -half..=half {
1420            for row in far..=near {
1421                let variant = (col * 13 + row * 7).rem_euclid(CAVE_COLUMNS as i32) as u32;
1422                ctx.draw(
1423                    CaveFloor
1424                        .at(Vec3::new(
1425                            col as f32 * TILE_SIZE,
1426                            0.0,
1427                            row as f32 * TILE_SIZE,
1428                        ))
1429                        .frame(
1430                            Sheet::new(UVec2::new(CAVE_COLUMNS, CAVE_ROWS))
1431                                .cell_at(UVec2::new(variant, CAVE_FLOOR_ROW)),
1432                        ),
1433                );
1434            }
1435        }
1436    }
1437
1438    /// The wall drawn at `at` over the meters `standing`, in courses
1439    /// [`WALL_HEIGHT`] tall from the floor up, each cut to the part of it the
1440    /// span leaves; its faces are picked by `seed` and its stone faded to
1441    /// `fade`, which is `1.0` wherever it is solid.
1442    fn draw_wall(
1443        ctx: &mut FrameContext<'_, Keep>,
1444        at: Vec2,
1445        standing: Range<f32>,
1446        seed: i32,
1447        fade: f32,
1448    ) {
1449        for course in 0..WALL_COURSES {
1450            let base = course as f32 * WALL_HEIGHT;
1451            let low = (standing.start - base).max(0.0);
1452            let high = (standing.end - base).min(WALL_HEIGHT);
1453            if high <= low {
1454                continue;
1455            }
1456
1457            let variant = (seed + course).rem_euclid(CAVE_COLUMNS as i32) as u32;
1458            ctx.draw(
1459                CaveWall
1460                    .at(Transform::from_scale_rotation_translation(
1461                        Vec3::new(TILE_SIZE, high - low, TILE_SIZE),
1462                        Quat::IDENTITY,
1463                        Vec3::new(at.x, base + (low + high) * 0.5, at.y),
1464                    ))
1465                    .frame(cave_wall_face(variant, low..high))
1466                    .faded(fade),
1467            );
1468        }
1469    }
1470
1471    /// The room's two side walls and its back wall, full height, and the low
1472    /// wall closing its near end between the side walls and the mouth. The
1473    /// back wall stops short of the corners the side walls already fill, and
1474    /// the near one leaves the mouth's own tile open.
1475    fn draw_cave_walls(&self, ctx: &mut FrameContext<'_, Keep>) {
1476        let half = CAVE_HALF_WIDTH as i32 + 1;
1477        let near = CAVE_NEAR_Z as i32;
1478        let far = CAVE_FAR_Z as i32;
1479
1480        for row in far..=near {
1481            let z = row as f32 * TILE_SIZE;
1482            let west = Vec2::new(-half as f32 * TILE_SIZE, z);
1483            let east = Vec2::new(half as f32 * TILE_SIZE, z);
1484            Self::draw_wall(ctx, west, 0.0..WALL_TOP, row * 5, SOLID);
1485            Self::draw_wall(ctx, east, 0.0..WALL_TOP, row * 5 + 1, SOLID);
1486        }
1487        for col in (-half + 1)..half {
1488            let x = col as f32 * TILE_SIZE;
1489            let back = Vec2::new(x, far as f32 * TILE_SIZE);
1490            Self::draw_wall(ctx, back, 0.0..WALL_TOP, col * 5 + 2, SOLID);
1491            if col != 0 {
1492                let lip = Vec2::new(x, CAVE_LIP_Z);
1493                Self::draw_wall(ctx, lip, 0.0..CAVE_LIP_HEIGHT, col * 5 + 4, SOLID);
1494            }
1495        }
1496    }
1497
1498    /// The wall the door hangs in, run across the room between the side walls
1499    /// with one tile left open on the room's axis for the doorway and stone
1500    /// filling the column over the door. A player behind the wall is drawn
1501    /// through the stacks between them and the camera, at `seen_through`,
1502    /// faded by `ghost`; the rest of it stays solid, and keeps casting.
1503    fn draw_door_wall(ctx: &mut FrameContext<'_, Keep>, seen_through: Option<f32>, ghost: f32) {
1504        let stone = |x: f32| match seen_through {
1505            Some(at) if (x - at).abs() < GHOST_CORRIDOR_HALF => ghost_alpha(ghost),
1506            _ => SOLID,
1507        };
1508        let half = CAVE_HALF_WIDTH as i32;
1509
1510        for col in (-half..=half).filter(|&col| col != 0) {
1511            let x = col as f32 * TILE_SIZE;
1512            Self::draw_wall(
1513                ctx,
1514                Vec2::new(x, DOOR_Z),
1515                0.0..WALL_TOP,
1516                col * 5 + 3,
1517                stone(x),
1518            );
1519        }
1520        Self::draw_wall(
1521            ctx,
1522            Vec2::new(0.0, DOOR_Z),
1523            DOOR_HEIGHT..WALL_TOP,
1524            3,
1525            stone(0.0),
1526        );
1527    }
1528
1529    /// The two torches: an upright cutout post apiece, the flame's loop
1530    /// burning over its binding, and the light that flame casts.
1531    fn draw_torches(&self, ctx: &mut FrameContext<'_, Keep>) {
1532        let elapsed = self.simulated.as_secs_f32();
1533        let loop_cells = Sheet::new(UVec2::new(FLAME_CELLS, 1));
1534
1535        for (index, &(x, z)) in TORCH_POSITIONS.iter().enumerate() {
1536            let base = Vec3::new(x, 0.0, z);
1537            ctx.draw(
1538                Torch
1539                    .at(Transform::from_scale_rotation_translation(
1540                        Vec3::new(TORCH_SPRITE_WIDTH, TORCH_STAND_HEIGHT, 1.0),
1541                        Quat::IDENTITY,
1542                        base + Vec3::Y * (TORCH_STAND_HEIGHT * 0.5),
1543                    ))
1544                    .upright(),
1545            );
1546
1547            let phase = index as f32 * 2.1;
1548            let flicker = (elapsed * FLAME_FLICKER_SPEED + phase).sin();
1549            let flame_pos =
1550                base + Vec3::Y * (TORCH_STAND_HEIGHT + FLAME_LIFT + flicker * FLAME_BOB);
1551
1552            let light_pos = flame_pos + Vec3::new(0.0, TORCH_LIGHT_LIFT, TORCH_LIGHT_STANDOFF);
1553            ctx.light(Light::point(light_pos, TORCH_LIGHT_COLOR, TORCH_LIGHT_RANGE).shadow());
1554            // The pair burn an even share of the loop apart.
1555            let offset = index as u32 * FLAME_CELLS / TORCH_POSITIONS.len() as u32;
1556            ctx.draw(
1557                Flame
1558                    .at(Transform::from_scale_rotation_translation(
1559                        Vec3::splat(FLAME_SIZE),
1560                        Quat::IDENTITY,
1561                        flame_pos,
1562                    ))
1563                    .billboard()
1564                    .roll(flicker * FLAME_ROLL)
1565                    .frame(loop_cells.cell((elapsed * FLAME_RATE) as u32 + offset)),
1566            );
1567        }
1568    }
1569
1570    /// The door at its hinge — swung back against the wall once opened —
1571    /// drawn through alongside its wall, faded by `ghost`.
1572    fn draw_door(&self, ctx: &mut FrameContext<'_, Keep>, ghost: f32) {
1573        let fade = ghost_alpha(ghost);
1574        let swung = if self.door_opening {
1575            Quat::from_rotation_y(core::f32::consts::FRAC_PI_2)
1576        } else {
1577            Quat::IDENTITY
1578        };
1579
1580        ctx.draw(
1581            Door.at(Transform::from_rotation_translation(swung, DOOR_HINGE))
1582                .material(Material::shaded(DOOR_COLOR, DOOR_LITNESS))
1583                .faded(fade),
1584        );
1585    }
1586
1587    /// The posts and lintel framing the doorway, in a color the stone never
1588    /// is, standing clear of the wall so the opening reads as a door from
1589    /// across the chamber. Glowing of their own while the door is closed and
1590    /// within [`INTERACT_RADIUS`], the cue that it opens.
1591    fn draw_door_frame(&self, ctx: &mut FrameContext<'_, Keep>, ghost: f32) {
1592        let reachable =
1593            !self.door_opening && self.position.distance(INTERACT_POINT) < INTERACT_RADIUS;
1594        let material =
1595            Material::shaded(DOOR_FRAME_COLOR, DOOR_FRAME_LITNESS).emissive(if reachable {
1596                DOOR_FRAME_GLOW
1597            } else {
1598                Color::BLACK
1599            });
1600        let fade = ghost_alpha(ghost);
1601        let z = DOOR_WALL_NEAR_Z + DOOR_FRAME_STANDOFF;
1602        let jamb_height = DOOR_HEIGHT + DOOR_FRAME_THICKNESS;
1603
1604        for side in SIDES {
1605            ctx.draw(
1606                Cube.at(Transform::from_scale_rotation_translation(
1607                    Vec3::new(DOOR_FRAME_THICKNESS, jamb_height, DOOR_FRAME_THICKNESS),
1608                    Quat::IDENTITY,
1609                    Vec3::new(
1610                        side * (DOORWAY_HALF + DOOR_FRAME_THICKNESS * 0.5),
1611                        jamb_height * 0.5,
1612                        z,
1613                    ),
1614                ))
1615                .material(material)
1616                .faded(fade),
1617            );
1618        }
1619        ctx.draw(
1620            Cube.at(Transform::from_scale_rotation_translation(
1621                Vec3::new(
1622                    DOOR_WIDTH + DOOR_FRAME_THICKNESS * 2.0,
1623                    DOOR_FRAME_THICKNESS,
1624                    DOOR_FRAME_THICKNESS,
1625                ),
1626                Quat::IDENTITY,
1627                Vec3::new(0.0, DOOR_HEIGHT + DOOR_FRAME_THICKNESS * 0.5, z),
1628            ))
1629            .material(material)
1630            .faded(fade),
1631        );
1632    }
1633
1634    /// A world prompt over the door: what opens it while the player is
1635    /// within [`INTERACT_RADIUS`] and it is closed, and that it swings while
1636    /// it does; gone once it has swung [`DOOR_SWING_TICKS`]. Laid out and
1637    /// placed like `examples/animation.rs`'s own prompt.
1638    fn draw_door_prompt(&self, ctx: &mut FrameContext<'_, Keep>, camera: Camera) {
1639        let near = self.position.distance(INTERACT_POINT) < INTERACT_RADIUS;
1640        let swinging = self.door_opening && self.swing_ticks < DOOR_SWING_TICKS;
1641        let text = if swinging {
1642            "opening"
1643        } else if near && !self.door_opening {
1644            "e opens the door"
1645        } else {
1646            return;
1647        };
1648
1649        let galley = ctx.text_layout(text, egui::FontId::proportional(DOOR_PROMPT_SIZE));
1650        let point = INTERACT_POINT + Vec3::Y * (DOOR_HEIGHT + DOOR_PROMPT_LIFT);
1651        let window_size = ctx.window_size();
1652        let pixels_per_point = ctx.pixels_per_point();
1653        let Some(pixel) = camera.pixel_of(point, window_size) else {
1654            return;
1655        };
1656
1657        ctx.ui(|ui| {
1658            let painter = ui.painter();
1659            let at = logical(pixel, pixels_per_point);
1660            let ink = galley.mesh_bounds;
1661            let pos = egui::pos2(at.x - ink.center().x, at.y - ink.center().y);
1662            let backdrop = egui::Rect::from_center_size(
1663                at,
1664                ink.size() + egui::Vec2::splat(DOOR_PROMPT_PADDING * 2.0),
1665            );
1666            painter.rect_filled(
1667                backdrop,
1668                DOOR_PROMPT_PADDING,
1669                egui::Color32::from_black_alpha(DOOR_PROMPT_BACKDROP),
1670            );
1671            painter.galley(pos, galley, DOOR_PROMPT_COLOR);
1672        });
1673    }
1674
1675    /// The gem, spinning and bobbing over the chamber's floor, and the light
1676    /// it casts over it.
1677    fn draw_gem(&self, ctx: &mut FrameContext<'_, Keep>) {
1678        let t = self.simulated.as_secs_f32();
1679        let bob = (t * 2.0).sin() * GEM_BOB_HEIGHT;
1680        ctx.light(
1681            Light::point(
1682                GEM_POSITION + Vec3::Y * (bob + GEM_LIGHT_LIFT),
1683                GEM_LIGHT_COLOR,
1684                GEM_LIGHT_RANGE,
1685            )
1686            .shadow(),
1687        );
1688        ctx.draw(
1689            Gem.at(Transform::from_scale_rotation_translation(
1690                Vec3::ONE,
1691                Quat::from_rotation_y(t * GEM_SPIN_SPEED),
1692                GEM_POSITION + Vec3::Y * bob,
1693            ))
1694            .material(Material::shaded(GEM_COLOR, 0.7).emissive(GEM_COLOR.dimmed(1.6))),
1695        );
1696    }
1697
1698    /// The player: upright so it always faces the camera about `+Y`,
1699    /// windowed to its facing's row and the walk cycle's current frame.
1700    fn draw_walker(&self, ctx: &mut FrameContext<'_, Keep>, ground: Vec3) {
1701        let step = if self.walk_ticks > 0 {
1702            (self.walk_ticks / TICKS_PER_WALK_FRAME) % WALKER_COLUMNS
1703        } else {
1704            0
1705        };
1706        let cell = Sheet::new(UVec2::new(WALKER_COLUMNS, WALKER_ROWS))
1707            .cell_at(UVec2::new(step, self.facing as u32));
1708        let size = Vec2::new(WALKER_WIDTH, WALKER_HEIGHT);
1709
1710        ctx.draw(
1711            Walker
1712                .at(Transform::from_scale_rotation_translation(
1713                    size.extend(1.0),
1714                    Quat::IDENTITY,
1715                    ground + Vec3::Y * (WALKER_HEIGHT * 0.5),
1716                ))
1717                .upright()
1718                .frame(cell),
1719        );
1720    }
Source

pub const fn splat(v: u32) -> UVec2

Creates a vector with all elements set to v.

Source

pub fn map<F>(self, f: F) -> UVec2
where F: FnMut(u32) -> u32,

Returns a vector containing each element of self modified by a mapping function f.

Source

pub fn select(mask: BVec2, if_true: UVec2, if_false: UVec2) -> UVec2

Creates a vector from the elements in if_true and if_false, selecting which to use for each element of self.

A true element in the mask uses the corresponding element from if_true, and false uses the element from if_false.

Source

pub const fn from_array(a: [u32; 2]) -> UVec2

Creates a new vector from an array.

Source

pub const fn to_array(&self) -> [u32; 2]

Converts self to [x, y]

Source

pub const fn from_slice(slice: &[u32]) -> UVec2

Creates a vector from the first 2 values in slice.

§Panics

Panics if slice is less than 2 elements long.

Source

pub fn write_to_slice(self, slice: &mut [u32])

Writes the elements of self to the first 2 elements in slice.

§Panics

Panics if slice is less than 2 elements long.

Source

pub const fn extend(self, z: u32) -> UVec3

Creates a 3D vector from self and the given z value.

Source

pub fn with_x(self, x: u32) -> UVec2

Creates a 2D vector from self with the given value of x.

Source

pub fn with_y(self, y: u32) -> UVec2

Creates a 2D vector from self with the given value of y.

Source

pub fn dot(self, rhs: UVec2) -> u32

Computes the dot product of self and rhs.

Source

pub fn dot_into_vec(self, rhs: UVec2) -> UVec2

Returns a vector where every component is the dot product of self and rhs.

Source

pub fn min(self, rhs: UVec2) -> UVec2

Returns a vector containing the minimum values for each element of self and rhs.

In other words this computes [min(x, rhs.x), min(self.y, rhs.y), ..].

Source

pub fn max(self, rhs: UVec2) -> UVec2

Returns a vector containing the maximum values for each element of self and rhs.

In other words this computes [max(self.x, rhs.x), max(self.y, rhs.y), ..].

Source

pub fn clamp(self, min: UVec2, max: UVec2) -> UVec2

Component-wise clamping of values, similar to u32::clamp.

Each element in min must be less-or-equal to the corresponding element in max.

§Panics

Will panic if min is greater than max when glam_assert is enabled.

Source

pub fn min_element(self) -> u32

Returns the horizontal minimum of self.

In other words this computes min(x, y, ..).

Source

pub fn max_element(self) -> u32

Returns the horizontal maximum of self.

In other words this computes max(x, y, ..).

Source

pub fn min_position(self) -> usize

Returns the index of the first minimum element of self.

Source

pub fn max_position(self) -> usize

Returns the index of the first maximum element of self.

Source

pub fn element_sum(self) -> u32

Returns the sum of all elements of self.

In other words, this computes self.x + self.y + ...

Source

pub fn element_product(self) -> u32

Returns the product of all elements of self.

In other words, this computes self.x * self.y * ...

Source

pub fn cmpeq(self, rhs: UVec2) -> BVec2

Returns a vector mask containing the result of a == comparison for each element of self and rhs.

In other words, this computes [self.x == rhs.x, self.y == rhs.y, ..] for all elements.

Source

pub fn cmpne(self, rhs: UVec2) -> BVec2

Returns a vector mask containing the result of a != comparison for each element of self and rhs.

In other words this computes [self.x != rhs.x, self.y != rhs.y, ..] for all elements.

Source

pub fn cmpge(self, rhs: UVec2) -> BVec2

Returns a vector mask containing the result of a >= comparison for each element of self and rhs.

In other words this computes [self.x >= rhs.x, self.y >= rhs.y, ..] for all elements.

Source

pub fn cmpgt(self, rhs: UVec2) -> BVec2

Returns a vector mask containing the result of a > comparison for each element of self and rhs.

In other words this computes [self.x > rhs.x, self.y > rhs.y, ..] for all elements.

Source

pub fn cmple(self, rhs: UVec2) -> BVec2

Returns a vector mask containing the result of a <= comparison for each element of self and rhs.

In other words this computes [self.x <= rhs.x, self.y <= rhs.y, ..] for all elements.

Source

pub fn cmplt(self, rhs: UVec2) -> BVec2

Returns a vector mask containing the result of a < comparison for each element of self and rhs.

In other words this computes [self.x < rhs.x, self.y < rhs.y, ..] for all elements.

Source

pub fn length_squared(self) -> u32

Computes the squared length of self.

Source

pub fn manhattan_distance(self, rhs: UVec2) -> u32

Computes the manhattan distance between two points.

§Overflow

This method may overflow if the result is greater than u32::MAX.

See also checked_manhattan_distance.

Source

pub fn checked_manhattan_distance(self, rhs: UVec2) -> Option<u32>

Computes the manhattan distance between two points.

This will returns None if the result is greater than u32::MAX.

Source

pub fn chebyshev_distance(self, rhs: UVec2) -> u32

Computes the chebyshev distance between two points.

Source

pub fn as_vec2(self) -> Vec2

Casts all elements of self to f32.

Source

pub fn as_dvec2(self) -> DVec2

Casts all elements of self to f64.

Source

pub fn as_i8vec2(self) -> I8Vec2

Casts all elements of self to i8.

Source

pub fn as_u8vec2(self) -> U8Vec2

Casts all elements of self to u8.

Source

pub fn as_i16vec2(self) -> I16Vec2

Casts all elements of self to i16.

Source

pub fn as_u16vec2(self) -> U16Vec2

Casts all elements of self to u16.

Source

pub fn as_ivec2(self) -> IVec2

Casts all elements of self to i32.

Source

pub fn as_i64vec2(self) -> I64Vec2

Casts all elements of self to i64.

Source

pub fn as_u64vec2(self) -> U64Vec2

Casts all elements of self to u64.

Source

pub fn as_isizevec2(self) -> ISizeVec2

Casts all elements of self to isize.

Source

pub fn as_usizevec2(self) -> USizeVec2

Casts all elements of self to usize.

Source

pub const fn checked_add(self, rhs: UVec2) -> Option<UVec2>

Returns a vector containing the wrapping addition of self and rhs.

In other words this computes Some([self.x + rhs.x, self.y + rhs.y, ..]) but returns None on any overflow.

Source

pub const fn checked_sub(self, rhs: UVec2) -> Option<UVec2>

Returns a vector containing the wrapping subtraction of self and rhs.

In other words this computes Some([self.x - rhs.x, self.y - rhs.y, ..]) but returns None on any overflow.

Source

pub const fn checked_mul(self, rhs: UVec2) -> Option<UVec2>

Returns a vector containing the wrapping multiplication of self and rhs.

In other words this computes Some([self.x * rhs.x, self.y * rhs.y, ..]) but returns None on any overflow.

Source

pub const fn checked_div(self, rhs: UVec2) -> Option<UVec2>

Returns a vector containing the wrapping division of self and rhs.

In other words this computes Some([self.x / rhs.x, self.y / rhs.y, ..]) but returns None on any division by zero.

Source

pub const fn wrapping_add(self, rhs: UVec2) -> UVec2

Returns a vector containing the wrapping addition of self and rhs.

In other words this computes [self.x.wrapping_add(rhs.x), self.y.wrapping_add(rhs.y), ..].

Source

pub const fn wrapping_sub(self, rhs: UVec2) -> UVec2

Returns a vector containing the wrapping subtraction of self and rhs.

In other words this computes [self.x.wrapping_sub(rhs.x), self.y.wrapping_sub(rhs.y), ..].

Source

pub const fn wrapping_mul(self, rhs: UVec2) -> UVec2

Returns a vector containing the wrapping multiplication of self and rhs.

In other words this computes [self.x.wrapping_mul(rhs.x), self.y.wrapping_mul(rhs.y), ..].

Source

pub const fn wrapping_div(self, rhs: UVec2) -> UVec2

Returns a vector containing the wrapping division of self and rhs.

In other words this computes [self.x.wrapping_div(rhs.x), self.y.wrapping_div(rhs.y), ..].

Source

pub const fn saturating_add(self, rhs: UVec2) -> UVec2

Returns a vector containing the saturating addition of self and rhs.

In other words this computes [self.x.saturating_add(rhs.x), self.y.saturating_add(rhs.y), ..].

Source

pub const fn saturating_sub(self, rhs: UVec2) -> UVec2

Returns a vector containing the saturating subtraction of self and rhs.

In other words this computes [self.x.saturating_sub(rhs.x), self.y.saturating_sub(rhs.y), ..].

Source

pub const fn saturating_mul(self, rhs: UVec2) -> UVec2

Returns a vector containing the saturating multiplication of self and rhs.

In other words this computes [self.x.saturating_mul(rhs.x), self.y.saturating_mul(rhs.y), ..].

Source

pub const fn saturating_div(self, rhs: UVec2) -> UVec2

Returns a vector containing the saturating division of self and rhs.

In other words this computes [self.x.saturating_div(rhs.x), self.y.saturating_div(rhs.y), ..].

Source

pub const fn checked_add_signed(self, rhs: IVec2) -> Option<UVec2>

Returns a vector containing the wrapping addition of self and signed vector rhs.

In other words this computes Some([self.x + rhs.x, self.y + rhs.y, ..]) but returns None on any overflow.

Source

pub const fn wrapping_add_signed(self, rhs: IVec2) -> UVec2

Returns a vector containing the wrapping addition of self and signed vector rhs.

In other words this computes [self.x.wrapping_add_signed(rhs.x), self.y.wrapping_add_signed(rhs.y), ..].

Source

pub const fn saturating_add_signed(self, rhs: IVec2) -> UVec2

Returns a vector containing the saturating addition of self and signed vector rhs.

In other words this computes [self.x.saturating_add_signed(rhs.x), self.y.saturating_add_signed(rhs.y), ..].

Trait Implementations§

Source§

impl Add for UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: UVec2) -> UVec2

Performs the + operation. Read more
Source§

impl Add<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &UVec2) -> UVec2

Performs the + operation. Read more
Source§

impl Add<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &UVec2) -> UVec2

Performs the + operation. Read more
Source§

impl Add<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u32) -> UVec2

Performs the + operation. Read more
Source§

impl Add<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u32) -> UVec2

Performs the + operation. Read more
Source§

impl Add<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: UVec2) -> UVec2

Performs the + operation. Read more
Source§

impl Add<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u32) -> UVec2

Performs the + operation. Read more
Source§

impl Add<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u32) -> UVec2

Performs the + operation. Read more
Source§

impl AddAssign for UVec2

Source§

fn add_assign(&mut self, rhs: UVec2)

Performs the += operation. Read more
Source§

impl AddAssign<&UVec2> for UVec2

Source§

fn add_assign(&mut self, rhs: &UVec2)

Performs the += operation. Read more
Source§

impl AddAssign<&u32> for UVec2

Source§

fn add_assign(&mut self, rhs: &u32)

Performs the += operation. Read more
Source§

impl AddAssign<u32> for UVec2

Source§

fn add_assign(&mut self, rhs: u32)

Performs the += operation. Read more
Source§

impl AsMut<[u32; 2]> for UVec2

Source§

fn as_mut(&mut self) -> &mut [u32; 2]

Converts this type into a mutable reference of the (usually inferred) input type.
Source§

impl AsRef<[u32; 2]> for UVec2

Source§

fn as_ref(&self) -> &[u32; 2]

Converts this type into a shared reference of the (usually inferred) input type.
Source§

impl BitAnd for UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: UVec2) -> <UVec2 as BitAnd>::Output

Performs the & operation. Read more
Source§

impl BitAnd<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: &UVec2) -> UVec2

Performs the & operation. Read more
Source§

impl BitAnd<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: &UVec2) -> UVec2

Performs the & operation. Read more
Source§

impl BitAnd<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: &u32) -> UVec2

Performs the & operation. Read more
Source§

impl BitAnd<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: &u32) -> UVec2

Performs the & operation. Read more
Source§

impl BitAnd<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: UVec2) -> UVec2

Performs the & operation. Read more
Source§

impl BitAnd<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: u32) -> <UVec2 as BitAnd<u32>>::Output

Performs the & operation. Read more
Source§

impl BitAnd<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the & operator.
Source§

fn bitand(self, rhs: u32) -> UVec2

Performs the & operation. Read more
Source§

impl BitAndAssign for UVec2

Source§

fn bitand_assign(&mut self, rhs: UVec2)

Performs the &= operation. Read more
Source§

impl BitAndAssign<&UVec2> for UVec2

Source§

fn bitand_assign(&mut self, rhs: &UVec2)

Performs the &= operation. Read more
Source§

impl BitAndAssign<&u32> for UVec2

Source§

fn bitand_assign(&mut self, rhs: &u32)

Performs the &= operation. Read more
Source§

impl BitAndAssign<u32> for UVec2

Source§

fn bitand_assign(&mut self, rhs: u32)

Performs the &= operation. Read more
Source§

impl BitOr for UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: UVec2) -> <UVec2 as BitOr>::Output

Performs the | operation. Read more
Source§

impl BitOr<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: &UVec2) -> UVec2

Performs the | operation. Read more
Source§

impl BitOr<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: &UVec2) -> UVec2

Performs the | operation. Read more
Source§

impl BitOr<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: &u32) -> UVec2

Performs the | operation. Read more
Source§

impl BitOr<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: &u32) -> UVec2

Performs the | operation. Read more
Source§

impl BitOr<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: UVec2) -> UVec2

Performs the | operation. Read more
Source§

impl BitOr<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: u32) -> <UVec2 as BitOr<u32>>::Output

Performs the | operation. Read more
Source§

impl BitOr<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the | operator.
Source§

fn bitor(self, rhs: u32) -> UVec2

Performs the | operation. Read more
Source§

impl BitOrAssign for UVec2

Source§

fn bitor_assign(&mut self, rhs: UVec2)

Performs the |= operation. Read more
Source§

impl BitOrAssign<&UVec2> for UVec2

Source§

fn bitor_assign(&mut self, rhs: &UVec2)

Performs the |= operation. Read more
Source§

impl BitOrAssign<&u32> for UVec2

Source§

fn bitor_assign(&mut self, rhs: &u32)

Performs the |= operation. Read more
Source§

impl BitOrAssign<u32> for UVec2

Source§

fn bitor_assign(&mut self, rhs: u32)

Performs the |= operation. Read more
Source§

impl BitXor for UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: UVec2) -> <UVec2 as BitXor>::Output

Performs the ^ operation. Read more
Source§

impl BitXor<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: &UVec2) -> UVec2

Performs the ^ operation. Read more
Source§

impl BitXor<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: &UVec2) -> UVec2

Performs the ^ operation. Read more
Source§

impl BitXor<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: &u32) -> UVec2

Performs the ^ operation. Read more
Source§

impl BitXor<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: &u32) -> UVec2

Performs the ^ operation. Read more
Source§

impl BitXor<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: UVec2) -> UVec2

Performs the ^ operation. Read more
Source§

impl BitXor<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: u32) -> <UVec2 as BitXor<u32>>::Output

Performs the ^ operation. Read more
Source§

impl BitXor<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, rhs: u32) -> UVec2

Performs the ^ operation. Read more
Source§

impl BitXorAssign for UVec2

Source§

fn bitxor_assign(&mut self, rhs: UVec2)

Performs the ^= operation. Read more
Source§

impl BitXorAssign<&UVec2> for UVec2

Source§

fn bitxor_assign(&mut self, rhs: &UVec2)

Performs the ^= operation. Read more
Source§

impl BitXorAssign<&u32> for UVec2

Source§

fn bitxor_assign(&mut self, rhs: &u32)

Performs the ^= operation. Read more
Source§

impl BitXorAssign<u32> for UVec2

Source§

fn bitxor_assign(&mut self, rhs: u32)

Performs the ^= operation. Read more
Source§

impl Clone for UVec2

Source§

fn clone(&self) -> UVec2

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for UVec2

Source§

impl Debug for UVec2

Source§

fn fmt(&self, fmt: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Default for UVec2

Source§

fn default() -> UVec2

Returns the “default value” for a type. Read more
Source§

impl Display for UVec2

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Div for UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: UVec2) -> UVec2

Performs the / operation. Read more
Source§

impl Div<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &UVec2) -> UVec2

Performs the / operation. Read more
Source§

impl Div<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &UVec2) -> UVec2

Performs the / operation. Read more
Source§

impl Div<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u32) -> UVec2

Performs the / operation. Read more
Source§

impl Div<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u32) -> UVec2

Performs the / operation. Read more
Source§

impl Div<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: UVec2) -> UVec2

Performs the / operation. Read more
Source§

impl Div<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u32) -> UVec2

Performs the / operation. Read more
Source§

impl Div<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u32) -> UVec2

Performs the / operation. Read more
Source§

impl DivAssign for UVec2

Source§

fn div_assign(&mut self, rhs: UVec2)

Performs the /= operation. Read more
Source§

impl DivAssign<&UVec2> for UVec2

Source§

fn div_assign(&mut self, rhs: &UVec2)

Performs the /= operation. Read more
Source§

impl DivAssign<&u32> for UVec2

Source§

fn div_assign(&mut self, rhs: &u32)

Performs the /= operation. Read more
Source§

impl DivAssign<u32> for UVec2

Source§

fn div_assign(&mut self, rhs: u32)

Performs the /= operation. Read more
Source§

impl Eq for UVec2

Source§

impl From<(u32, u32)> for UVec2

Source§

fn from(t: (u32, u32)) -> UVec2

Converts to this type from the input type.
Source§

impl From<BVec2> for UVec2

Source§

fn from(v: BVec2) -> UVec2

Converts to this type from the input type.
Source§

impl From<U8Vec2> for UVec2

Available on crate feature u8 only.
Source§

fn from(v: U8Vec2) -> UVec2

Converts to this type from the input type.
Source§

impl From<U16Vec2> for UVec2

Available on crate feature u16 only.
Source§

fn from(v: U16Vec2) -> UVec2

Converts to this type from the input type.
Source§

impl From<UVec2> for DVec2

Available on crate feature u32 only.
Source§

fn from(v: UVec2) -> DVec2

Converts to this type from the input type.
Source§

impl From<UVec2> for I64Vec2

Available on crate feature u32 only.
Source§

fn from(v: UVec2) -> I64Vec2

Converts to this type from the input type.
Source§

impl From<UVec2> for U64Vec2

Available on crate feature u32 only.
Source§

fn from(v: UVec2) -> U64Vec2

Converts to this type from the input type.
Source§

impl From<[u32; 2]> for UVec2

Source§

fn from(a: [u32; 2]) -> UVec2

Converts to this type from the input type.
Source§

impl Hash for UVec2

Source§

fn hash<__H>(&self, state: &mut __H)
where __H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Index<usize> for UVec2

Source§

type Output = u32

The returned type after indexing.
Source§

fn index(&self, index: usize) -> &<UVec2 as Index<usize>>::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl IndexMut<usize> for UVec2

Source§

fn index_mut(&mut self, index: usize) -> &mut <UVec2 as Index<usize>>::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl Mul for UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: UVec2) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &UVec2) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &UVec2) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u32) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u32) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: UVec2) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u32) -> UVec2

Performs the * operation. Read more
Source§

impl Mul<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u32) -> UVec2

Performs the * operation. Read more
Source§

impl MulAssign for UVec2

Source§

fn mul_assign(&mut self, rhs: UVec2)

Performs the *= operation. Read more
Source§

impl MulAssign<&UVec2> for UVec2

Source§

fn mul_assign(&mut self, rhs: &UVec2)

Performs the *= operation. Read more
Source§

impl MulAssign<&u32> for UVec2

Source§

fn mul_assign(&mut self, rhs: &u32)

Performs the *= operation. Read more
Source§

impl MulAssign<u32> for UVec2

Source§

fn mul_assign(&mut self, rhs: u32)

Performs the *= operation. Read more
Source§

impl Not for UVec2

Source§

type Output = UVec2

The resulting type after applying the ! operator.
Source§

fn not(self) -> UVec2

Performs the unary ! operation. Read more
Source§

impl Not for &UVec2

Source§

type Output = UVec2

The resulting type after applying the ! operator.
Source§

fn not(self) -> UVec2

Performs the unary ! operation. Read more
Source§

impl PartialEq for UVec2

Source§

fn eq(&self, other: &UVec2) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Pod for UVec2

Source§

impl Product for UVec2

Source§

fn product<I>(iter: I) -> UVec2
where I: Iterator<Item = UVec2>,

Takes an iterator and generates Self from the elements by multiplying the items.
Source§

impl<'a> Product<&'a UVec2> for UVec2

Source§

fn product<I>(iter: I) -> UVec2
where I: Iterator<Item = &'a UVec2>,

Takes an iterator and generates Self from the elements by multiplying the items.
Source§

impl Rem for UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: UVec2) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &UVec2) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &UVec2) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u32) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u32) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: UVec2) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u32) -> UVec2

Performs the % operation. Read more
Source§

impl Rem<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u32) -> UVec2

Performs the % operation. Read more
Source§

impl RemAssign for UVec2

Source§

fn rem_assign(&mut self, rhs: UVec2)

Performs the %= operation. Read more
Source§

impl RemAssign<&UVec2> for UVec2

Source§

fn rem_assign(&mut self, rhs: &UVec2)

Performs the %= operation. Read more
Source§

impl RemAssign<&u32> for UVec2

Source§

fn rem_assign(&mut self, rhs: &u32)

Performs the %= operation. Read more
Source§

impl RemAssign<u32> for UVec2

Source§

fn rem_assign(&mut self, rhs: u32)

Performs the %= operation. Read more
Source§

impl Shl for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&IVec2> for UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &IVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&IVec2> for &UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &IVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> I8Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> I8Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> U8Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> U8Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> I16Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> I16Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> U16Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> U16Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> IVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> IVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> I64Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> I64Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> U64Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> U64Vec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> USizeVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> USizeVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> ISizeVec2

Performs the << operation. Read more
Source§

impl Shl<&UVec2> for &ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &UVec2) -> ISizeVec2

Performs the << operation. Read more
Source§

impl Shl<&i8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i8) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i8) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i16) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i16) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i32) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i32) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i64) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&i64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &i64) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u8) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u8) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u16) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u16) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u32) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u32) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u64) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<&u64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: &u64) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<IVec2> for UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: IVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<IVec2> for &UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: IVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> I8Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> I8Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> U8Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> U8Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> I16Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> I16Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> U16Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> U16Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> IVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> IVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> I64Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> I64Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> U64Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> U64Vec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> USizeVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> USizeVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> ISizeVec2

Performs the << operation. Read more
Source§

impl Shl<UVec2> for &ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: UVec2) -> ISizeVec2

Performs the << operation. Read more
Source§

impl Shl<i8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i8) -> <UVec2 as Shl<i8>>::Output

Performs the << operation. Read more
Source§

impl Shl<i8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i8) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<i16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i16) -> <UVec2 as Shl<i16>>::Output

Performs the << operation. Read more
Source§

impl Shl<i16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i16) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<i32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i32) -> <UVec2 as Shl<i32>>::Output

Performs the << operation. Read more
Source§

impl Shl<i32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i32) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<i64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i64) -> <UVec2 as Shl<i64>>::Output

Performs the << operation. Read more
Source§

impl Shl<i64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: i64) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<u8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u8) -> <UVec2 as Shl<u8>>::Output

Performs the << operation. Read more
Source§

impl Shl<u8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u8) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<u16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u16) -> <UVec2 as Shl<u16>>::Output

Performs the << operation. Read more
Source§

impl Shl<u16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u16) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u32) -> <UVec2 as Shl<u32>>::Output

Performs the << operation. Read more
Source§

impl Shl<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u32) -> UVec2

Performs the << operation. Read more
Source§

impl Shl<u64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u64) -> <UVec2 as Shl<u64>>::Output

Performs the << operation. Read more
Source§

impl Shl<u64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the << operator.
Source§

fn shl(self, rhs: u64) -> UVec2

Performs the << operation. Read more
Source§

impl ShlAssign<&i8> for UVec2

Source§

fn shl_assign(&mut self, rhs: &i8)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&i16> for UVec2

Source§

fn shl_assign(&mut self, rhs: &i16)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&i32> for UVec2

Source§

fn shl_assign(&mut self, rhs: &i32)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&i64> for UVec2

Source§

fn shl_assign(&mut self, rhs: &i64)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&u8> for UVec2

Source§

fn shl_assign(&mut self, rhs: &u8)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&u16> for UVec2

Source§

fn shl_assign(&mut self, rhs: &u16)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&u32> for UVec2

Source§

fn shl_assign(&mut self, rhs: &u32)

Performs the <<= operation. Read more
Source§

impl ShlAssign<&u64> for UVec2

Source§

fn shl_assign(&mut self, rhs: &u64)

Performs the <<= operation. Read more
Source§

impl ShlAssign<i8> for UVec2

Source§

fn shl_assign(&mut self, rhs: i8)

Performs the <<= operation. Read more
Source§

impl ShlAssign<i16> for UVec2

Source§

fn shl_assign(&mut self, rhs: i16)

Performs the <<= operation. Read more
Source§

impl ShlAssign<i32> for UVec2

Source§

fn shl_assign(&mut self, rhs: i32)

Performs the <<= operation. Read more
Source§

impl ShlAssign<i64> for UVec2

Source§

fn shl_assign(&mut self, rhs: i64)

Performs the <<= operation. Read more
Source§

impl ShlAssign<u8> for UVec2

Source§

fn shl_assign(&mut self, rhs: u8)

Performs the <<= operation. Read more
Source§

impl ShlAssign<u16> for UVec2

Source§

fn shl_assign(&mut self, rhs: u16)

Performs the <<= operation. Read more
Source§

impl ShlAssign<u32> for UVec2

Source§

fn shl_assign(&mut self, rhs: u32)

Performs the <<= operation. Read more
Source§

impl ShlAssign<u64> for UVec2

Source§

fn shl_assign(&mut self, rhs: u64)

Performs the <<= operation. Read more
Source§

impl Shr for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&IVec2> for UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &IVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&IVec2> for &UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &IVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> I8Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> I8Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> U8Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> U8Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> I16Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> I16Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> U16Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> U16Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> IVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> IVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> I64Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> I64Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> U64Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> U64Vec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> USizeVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> USizeVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> ISizeVec2

Performs the >> operation. Read more
Source§

impl Shr<&UVec2> for &ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &UVec2) -> ISizeVec2

Performs the >> operation. Read more
Source§

impl Shr<&i8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i8) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i8) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i16) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i16) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i32) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i32) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i64) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&i64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &i64) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u8) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u8) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u16) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u16) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u32) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u32) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u64) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<&u64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: &u64) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<IVec2> for UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: IVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<IVec2> for &UVec2

Available on crate feature i32 only.
Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: IVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> I8Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &I8Vec2

Available on crate feature u32 only.
Source§

type Output = I8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> I8Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> U8Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &U8Vec2

Available on crate feature u32 only.
Source§

type Output = U8Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> U8Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> I16Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &I16Vec2

Available on crate feature u32 only.
Source§

type Output = I16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> I16Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> U16Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &U16Vec2

Available on crate feature u32 only.
Source§

type Output = U16Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> U16Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> IVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &IVec2

Available on crate feature u32 only.
Source§

type Output = IVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> IVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> I64Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &I64Vec2

Available on crate feature u32 only.
Source§

type Output = I64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> I64Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> U64Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &U64Vec2

Available on crate feature u32 only.
Source§

type Output = U64Vec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> U64Vec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> USizeVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &USizeVec2

Available on crate feature u32 only.
Source§

type Output = USizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> USizeVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> ISizeVec2

Performs the >> operation. Read more
Source§

impl Shr<UVec2> for &ISizeVec2

Available on crate feature u32 only.
Source§

type Output = ISizeVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: UVec2) -> ISizeVec2

Performs the >> operation. Read more
Source§

impl Shr<i8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i8) -> <UVec2 as Shr<i8>>::Output

Performs the >> operation. Read more
Source§

impl Shr<i8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i8) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<i16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i16) -> <UVec2 as Shr<i16>>::Output

Performs the >> operation. Read more
Source§

impl Shr<i16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i16) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<i32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i32) -> <UVec2 as Shr<i32>>::Output

Performs the >> operation. Read more
Source§

impl Shr<i32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i32) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<i64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i64) -> <UVec2 as Shr<i64>>::Output

Performs the >> operation. Read more
Source§

impl Shr<i64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: i64) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<u8> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u8) -> <UVec2 as Shr<u8>>::Output

Performs the >> operation. Read more
Source§

impl Shr<u8> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u8) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<u16> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u16) -> <UVec2 as Shr<u16>>::Output

Performs the >> operation. Read more
Source§

impl Shr<u16> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u16) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u32) -> <UVec2 as Shr<u32>>::Output

Performs the >> operation. Read more
Source§

impl Shr<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u32) -> UVec2

Performs the >> operation. Read more
Source§

impl Shr<u64> for UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u64) -> <UVec2 as Shr<u64>>::Output

Performs the >> operation. Read more
Source§

impl Shr<u64> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the >> operator.
Source§

fn shr(self, rhs: u64) -> UVec2

Performs the >> operation. Read more
Source§

impl ShrAssign<&i8> for UVec2

Source§

fn shr_assign(&mut self, rhs: &i8)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&i16> for UVec2

Source§

fn shr_assign(&mut self, rhs: &i16)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&i32> for UVec2

Source§

fn shr_assign(&mut self, rhs: &i32)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&i64> for UVec2

Source§

fn shr_assign(&mut self, rhs: &i64)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&u8> for UVec2

Source§

fn shr_assign(&mut self, rhs: &u8)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&u16> for UVec2

Source§

fn shr_assign(&mut self, rhs: &u16)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&u32> for UVec2

Source§

fn shr_assign(&mut self, rhs: &u32)

Performs the >>= operation. Read more
Source§

impl ShrAssign<&u64> for UVec2

Source§

fn shr_assign(&mut self, rhs: &u64)

Performs the >>= operation. Read more
Source§

impl ShrAssign<i8> for UVec2

Source§

fn shr_assign(&mut self, rhs: i8)

Performs the >>= operation. Read more
Source§

impl ShrAssign<i16> for UVec2

Source§

fn shr_assign(&mut self, rhs: i16)

Performs the >>= operation. Read more
Source§

impl ShrAssign<i32> for UVec2

Source§

fn shr_assign(&mut self, rhs: i32)

Performs the >>= operation. Read more
Source§

impl ShrAssign<i64> for UVec2

Source§

fn shr_assign(&mut self, rhs: i64)

Performs the >>= operation. Read more
Source§

impl ShrAssign<u8> for UVec2

Source§

fn shr_assign(&mut self, rhs: u8)

Performs the >>= operation. Read more
Source§

impl ShrAssign<u16> for UVec2

Source§

fn shr_assign(&mut self, rhs: u16)

Performs the >>= operation. Read more
Source§

impl ShrAssign<u32> for UVec2

Source§

fn shr_assign(&mut self, rhs: u32)

Performs the >>= operation. Read more
Source§

impl ShrAssign<u64> for UVec2

Source§

fn shr_assign(&mut self, rhs: u64)

Performs the >>= operation. Read more
Source§

impl StructuralPartialEq for UVec2

Source§

impl Sub for UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: UVec2) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<&UVec2> for UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &UVec2) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<&UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &UVec2) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<&u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u32) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<&u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u32) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<UVec2> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: UVec2) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<u32> for UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u32) -> UVec2

Performs the - operation. Read more
Source§

impl Sub<u32> for &UVec2

Source§

type Output = UVec2

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u32) -> UVec2

Performs the - operation. Read more
Source§

impl SubAssign for UVec2

Source§

fn sub_assign(&mut self, rhs: UVec2)

Performs the -= operation. Read more
Source§

impl SubAssign<&UVec2> for UVec2

Source§

fn sub_assign(&mut self, rhs: &UVec2)

Performs the -= operation. Read more
Source§

impl SubAssign<&u32> for UVec2

Source§

fn sub_assign(&mut self, rhs: &u32)

Performs the -= operation. Read more
Source§

impl SubAssign<u32> for UVec2

Source§

fn sub_assign(&mut self, rhs: u32)

Performs the -= operation. Read more
Source§

impl Sum for UVec2

Source§

fn sum<I>(iter: I) -> UVec2
where I: Iterator<Item = UVec2>,

Takes an iterator and generates Self from the elements by “summing up” the items.
Source§

impl<'a> Sum<&'a UVec2> for UVec2

Source§

fn sum<I>(iter: I) -> UVec2
where I: Iterator<Item = &'a UVec2>,

Takes an iterator and generates Self from the elements by “summing up” the items.
Source§

impl TryFrom<I8Vec2> for UVec2

Available on crate feature i8 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: I8Vec2) -> Result<UVec2, <UVec2 as TryFrom<I8Vec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<I16Vec2> for UVec2

Available on crate feature i16 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: I16Vec2) -> Result<UVec2, <UVec2 as TryFrom<I16Vec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<I64Vec2> for UVec2

Available on crate feature i64 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: I64Vec2) -> Result<UVec2, <UVec2 as TryFrom<I64Vec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<ISizeVec2> for UVec2

Available on crate feature isize only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: ISizeVec2) -> Result<UVec2, <UVec2 as TryFrom<ISizeVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<IVec2> for UVec2

Available on crate feature i32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: IVec2) -> Result<UVec2, <UVec2 as TryFrom<IVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<U64Vec2> for UVec2

Available on crate feature u64 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: U64Vec2) -> Result<UVec2, <UVec2 as TryFrom<U64Vec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<USizeVec2> for UVec2

Available on crate feature usize only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: USizeVec2) -> Result<UVec2, <UVec2 as TryFrom<USizeVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for I8Vec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<I8Vec2, <I8Vec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for U8Vec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<U8Vec2, <U8Vec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for I16Vec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<I16Vec2, <I16Vec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for U16Vec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<U16Vec2, <U16Vec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for IVec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<IVec2, <IVec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for USizeVec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<USizeVec2, <USizeVec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl TryFrom<UVec2> for ISizeVec2

Available on crate feature u32 only.
Source§

type Error = TryFromIntError

The type returned in the event of a conversion error.
Source§

fn try_from(v: UVec2) -> Result<ISizeVec2, <ISizeVec2 as TryFrom<UVec2>>::Error>

Performs the conversion.
Source§

impl Vec2Swizzles for UVec2

Source§

type Vec3 = UVec3

Source§

type Vec4 = UVec4

Source§

fn xx(self) -> UVec2

Source§

fn yx(self) -> UVec2

Source§

fn yy(self) -> UVec2

Source§

fn xxx(self) -> UVec3

Source§

fn xxy(self) -> UVec3

Source§

fn xyx(self) -> UVec3

Source§

fn xyy(self) -> UVec3

Source§

fn yxx(self) -> UVec3

Source§

fn yxy(self) -> UVec3

Source§

fn yyx(self) -> UVec3

Source§

fn yyy(self) -> UVec3

Source§

fn xxxx(self) -> UVec4

Source§

fn xxxy(self) -> UVec4

Source§

fn xxyx(self) -> UVec4

Source§

fn xxyy(self) -> UVec4

Source§

fn xyxx(self) -> UVec4

Source§

fn xyxy(self) -> UVec4

Source§

fn xyyx(self) -> UVec4

Source§

fn xyyy(self) -> UVec4

Source§

fn yxxx(self) -> UVec4

Source§

fn yxxy(self) -> UVec4

Source§

fn yxyx(self) -> UVec4

Source§

fn yxyy(self) -> UVec4

Source§

fn yyxx(self) -> UVec4

Source§

fn yyxy(self) -> UVec4

Source§

fn yyyx(self) -> UVec4

Source§

fn yyyy(self) -> UVec4

Source§

fn xy(self) -> Self

Source§

impl Zeroable for UVec2

Source§

fn zeroed() -> Self

Auto Trait Implementations§

§

impl Freeze for UVec2

§

impl RefUnwindSafe for UVec2

§

impl Send for UVec2

§

impl Sync for UVec2

§

impl Unpin for UVec2

§

impl UnsafeUnpin for UVec2

§

impl UnwindSafe for UVec2

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> AnyBitPattern for T
where T: Pod,

Source§

impl<T> AsId for T
where T: Hash + Debug,

Source§

impl<T> AsIdSalt for T
where T: Hash + Debug,

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CheckedBitPattern for T
where T: AnyBitPattern,

Source§

type Bits = T

Self must have the same layout as the specified Bits except for the possible invalid bit patterns being checked during is_valid_bit_pattern.
Source§

fn is_valid_bit_pattern(_bits: &T) -> bool

If this function returns true, then it must be valid to reinterpret bits as &Self.
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> Downcast for T
where T: Any,

Source§

fn into_any(self: Box<T>) -> Box<dyn Any>

Convert Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.
Source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
Source§

fn as_any(&self) -> &(dyn Any + 'static)

Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
Source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
Source§

impl<T> Downcast<T> for T

Source§

fn downcast(&self) -> &T

Source§

impl<T> DowncastSync for T
where T: Any + Send + Sync,

Source§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Sync + Send>

Convert Arc<Trait> (where Trait: Downcast) to Arc<Any>. Arc<Any> can then be further downcast into Arc<ConcreteType> where ConcreteType implements Trait.
Source§

impl<S, T> Duplex<S> for T
where T: FromSample<S> + ToSample<S>,

Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<S> FromSample<S> for S

Source§

fn from_sample_(s: S) -> S

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> NoUninit for T
where T: Pod,

Source§

impl<T, Rhs> NumAssignOps<Rhs> for T
where T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,

Source§

impl<T, Rhs, Output> NumOps<Rhs, Output> for T
where T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,

Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T, Base> RefNum<Base> for T
where T: NumOps<Base, Base> + for<'r> NumOps<&'r Base, Base>,

Source§

impl<T> SerializableAny for T
where T: 'static + Any + Clone + for<'a> Send + Sync,

Source§

impl<T, S> SimdFrom<T, S> for T
where S: Simd,

Source§

fn simd_from(_simd: S, value: T) -> T

Source§

impl<F, T, S> SimdInto<T, S> for F
where T: SimdFrom<F, S>, S: Simd,

Source§

fn simd_into(self, simd: S) -> T

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> ToSample<U> for T
where U: FromSample<T>,

Source§

fn to_sample_(self) -> U

Source§

impl<T> ToSmolStr for T
where T: Display + ?Sized,

Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> Upcast<T> for T

Source§

fn upcast(&self) -> Option<&T>

Source§

impl<T> WasmNotSend for T
where T: Send,

Source§

impl<T> WasmNotSendSync for T

Source§

impl<T> WasmNotSync for T
where T: Sync,

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more