Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion CHANGELOG.unreleased.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ For upgrade instructions, please check the [migration guide](MIGRATIONS.released
[Commits](https://github.com/scalableminds/webknossos/compare/25.01.0...HEAD)

### Added
- Added the possibility to configure a rotation for a dataset, which can be toggled off and on when viewing and annotating data. [#8159](https://github.com/scalableminds/webknossos/pull/8159)

### Changed

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@ import _ from "lodash";
import messages from "messages";
import { WkDevFlags } from "oxalis/api/wk_dev";
import type { Vector3 } from "oxalis/constants";
import { getReadableURLPart } from "oxalis/model/accessors/dataset_accessor";
import { flatToNestedMatrix } from "oxalis/model/accessors/dataset_layer_transformation_accessor";
import { flatToNestedMatrix, getReadableURLPart } from "oxalis/model/accessors/dataset_accessor";
import { checkLandmarksForThinPlateSpline } from "oxalis/model/helpers/transformation_helpers";
import type { OxalisState } from "oxalis/store";
import React, { useState } from "react";
Expand Down
191 changes: 0 additions & 191 deletions frontend/javascripts/dashboard/dataset/dataset_rotation_form_item.tsx

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ import { type APIDataLayer, type APIDataset, APIJobType } from "types/api_flow_t
import type { ArbitraryObject } from "types/globals";
import type { DataLayer } from "types/schemas/datasource.types";
import { isValidJSON, syncValidator, validateDatasourceJSON } from "types/validation";
import { AxisRotationSettingForDataset } from "./dataset_rotation_form_item";

const FormItem = Form.Item;

Expand Down Expand Up @@ -268,12 +267,6 @@ function SimpleDatasetForm({
</FormItemWithInfo>
</Col>
</Row>
<Row gutter={48}>
<Col span={24} xl={12} />
<Col span={24} xl={6}>
<AxisRotationSettingForDataset form={form} />
</Col>
</Row>
</div>
</List.Item>
</List>
Expand Down
33 changes: 0 additions & 33 deletions frontend/javascripts/dashboard/dataset/dataset_settings_view.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,6 @@ import _ from "lodash";
import messages from "messages";
import { Unicode } from "oxalis/constants";
import { getReadableURLPart } from "oxalis/model/accessors/dataset_accessor";
import {
EXPECTED_TRANSFORMATION_LENGTH,
doAllLayersHaveTheSameRotation,
getRotationFromTransformationIn90DegreeSteps,
} from "oxalis/model/accessors/dataset_layer_transformation_accessor";
import type { DatasetConfiguration, OxalisState } from "oxalis/store";
import * as React from "react";
import { connect } from "react-redux";
Expand All @@ -42,7 +37,6 @@ import type {
MutableAPIDataset,
} from "types/api_flow_types";
import { enforceValidatedDatasetViewConfiguration } from "types/schemas/dataset_view_configuration_defaults";
import type { DatasetRotation } from "./dataset_rotation_form_item";
import DatasetSettingsDataTab, { syncDataSourceFields } from "./dataset_settings_data_tab";
import DatasetSettingsDeleteTab from "./dataset_settings_delete_tab";
import DatasetSettingsMetadataTab from "./dataset_settings_metadata_tab";
Expand Down Expand Up @@ -82,7 +76,6 @@ export type FormData = {
dataset: APIDataset;
defaultConfiguration: DatasetConfiguration;
defaultConfigurationLayersJson: string;
datasetRotation?: DatasetRotation;
};

class DatasetSettingsView extends React.PureComponent<PropsWithFormAndRouter, State> {
Expand Down Expand Up @@ -201,32 +194,6 @@ class DatasetSettingsView extends React.PureComponent<PropsWithFormAndRouter, St
form.setFieldsValue({
dataSource,
});
// Retrieve the initial dataset rotation settings from the data source config.
if (doAllLayersHaveTheSameRotation(dataSource.dataLayers)) {
const firstLayerTransformations = dataSource.dataLayers[0].coordinateTransformations;
let initialDatasetRotationSettings: DatasetRotation;
if (
!firstLayerTransformations ||
firstLayerTransformations.length !== EXPECTED_TRANSFORMATION_LENGTH
) {
initialDatasetRotationSettings = {
x: 0,
y: 0,
z: 0,
};
} else {
initialDatasetRotationSettings = {
// First transformation is a translation to the coordinate system origin.
x: getRotationFromTransformationIn90DegreeSteps(firstLayerTransformations[1], "x"),
y: getRotationFromTransformationIn90DegreeSteps(firstLayerTransformations[2], "y"),
z: getRotationFromTransformationIn90DegreeSteps(firstLayerTransformations[3], "z"),
// Fifth transformation is a translation back to the original position.
};
}
form.setFieldsValue({
datasetRotation: initialDatasetRotationSettings,
});
}
const datasetDefaultConfiguration = await getDatasetDefaultConfiguration(
this.props.datasetId,
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,8 +223,8 @@ export default function DatasetSettingsViewConfigTab(props: {
<Col span={6}>
<FormItemWithInfo
name={["defaultConfiguration", "rotation"]}
label="Rotation - Arbitrary View Modes"
info="The default rotation that will be used in oblique and flight view mode."
label="Rotation"
info="The default rotation that will be used in oblique and arbitrary view mode."
>
<Vector3Input />
</FormItemWithInfo>
Expand Down
4 changes: 0 additions & 4 deletions frontend/javascripts/libs/mjs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -220,10 +220,6 @@ const M4x4 = {
r[2] = m[14];
return r;
},

identity(): Matrix4x4 {
return BareM4x4.identity;
},
};

const V2 = {
Expand Down
2 changes: 1 addition & 1 deletion frontend/javascripts/oxalis/api/api_latest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,13 @@ import {
import UrlManager from "oxalis/controller/url_manager";
import type { OxalisModel } from "oxalis/model";
import {
flatToNestedMatrix,
getLayerBoundingBox,
getLayerByName,
getMagInfo,
getMappingInfo,
getVisibleSegmentationLayer,
} from "oxalis/model/accessors/dataset_accessor";
import { flatToNestedMatrix } from "oxalis/model/accessors/dataset_layer_transformation_accessor";
import {
getActiveMagIndexForLayer,
getPosition,
Expand Down
2 changes: 0 additions & 2 deletions frontend/javascripts/oxalis/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ export type Vector4 = [number, number, number, number];
export type Vector5 = [number, number, number, number, number];
export type Vector6 = [number, number, number, number, number, number];

export type NestedMatrix4 = [Vector4, Vector4, Vector4, Vector4]; // Represents a row major matrix.

// For 3D data BucketAddress = x, y, z, mag
// For higher dimensional data, BucketAddress = x, y, z, mag, [{name: "t", value: t}, ...]
export type BucketAddress =
Expand Down
Loading