Files
nerfstudio/pyrad/viewer/app/src/App.js
T
Ethan Weber 1e22984d87 Initial viewer (visualizer) code (#52)
* some initial code for viewer. copying from other repos

* adding electron support

* moving some test files around. need to rewrite these

* camera traj. test cases. starting to transmit images

* still working on vis

* reorganized viewer and figured out websocket sending from client. need to do with camera pose

* black

* temporarily ignore pylinting for viewer

* ignore viewer

* fixed array

* license and fixed ignore in pyproject.toml

* improved syntax
2022-06-16 12:11:40 -07:00

46 lines
762 B
JavaScript

import React, { Component } from "react";
import "./App.css";
import { Viewer } from "./Viewer";
class Image extends Component {
constructor(props) {
super(props);
this.state = {};
}
}
class ColorGUIHelper {
constructor(object, prop) {
this.object = object;
this.prop = prop;
}
get value() {
return `#${this.object[this.prop].getHexString()}`;
}
set value(hexString) {
this.object[this.prop].set(hexString);
}
}
class App extends Component {
constructor(props) {
super(props);
this.state = {
client: null,
};
this.viewer_ref = React.createRef();
}
render() {
return (
<div className="App">
<Viewer ref={this.viewer_ref} />
</div>
);
}
}
export default App;