You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have uploaded a 3D-tile asset to https://cesium.com/ion/ and I'm able to render it, but how can I position it based on longitude and latitude on the map?
import {hot} from "react-hot-loader/root";
import React from "react";
import {Viewer,Cesium3DTileset} from "resium";
import {IonResource, ColorBlendMode} from "cesium";
const App = () => {
let viewer;
const handleReady = tileset => {
if (viewer) {
viewer.zoomTo(tileset).otherwise(function (error) {
console.log(error);
});
}
};
return (
<Viewer
full
ref={e => {
viewer = e && e.cesiumElement;
}}
>
<Cesium3DTileset
url={IonResource.fromAssetId(58415)}
onReady={handleReady}
onClick={(position) => console.log(position)}
colorBlendMode={ColorBlendMode.HIGHLIGHT}
/>
</Viewer>
)
};
export default hot(App);
EDIT: Just realised that i could change the tile location in Cesium Ion when I uploaded a collada .dae file. Could not change the location with the .kmz file I tried first. Would be nice if you could overwrite that position in the code though, but adjusting it in Cesium Ion will do:)
The text was updated successfully, but these errors were encountered:
I have not ever used Cesium3DTileset via Cesium Ion, but it seems to be that Cesium doesn't have a function to overwrite positions of a Cesium3DTileset.
Hi there, I'm new to cesium/resium.
I have uploaded a 3D-tile asset to https://cesium.com/ion/ and I'm able to render it, but how can I position it based on longitude and latitude on the map?
EDIT: Just realised that i could change the tile location in Cesium Ion when I uploaded a collada .dae file. Could not change the location with the .kmz file I tried first. Would be nice if you could overwrite that position in the code though, but adjusting it in Cesium Ion will do:)
The text was updated successfully, but these errors were encountered: