feat: Integrate ProductsDuplicate component into ComparisonScene and update Project to use SceneProvider
This commit is contained in:
@@ -9,45 +9,42 @@ import background from "../../assets/textures/hdr/mudroadpuresky2k.hdr";
|
||||
import ControlsDuplicate from "./duplicateSetup/controlsDuplicate";
|
||||
import PostProcessingDuplicate from "./duplicateSetup/postProcessingDuplicate";
|
||||
import { Color } from "three";
|
||||
import { SceneProvider } from "../scene/sceneContext";
|
||||
import SimulationDuplicate from "./duplicateSimulation/duplicateSimulation";
|
||||
|
||||
export default function DuplicateScene() {
|
||||
const projectId = "684bcd620a64bc2a815a88d6";
|
||||
|
||||
return (
|
||||
<SceneProvider layout='Comparison Layout'>
|
||||
<Canvas
|
||||
id="sceneCanvas"
|
||||
shadows
|
||||
color="#aaaa"
|
||||
eventPrefix="client"
|
||||
style={{
|
||||
pointerEvents: 'none'
|
||||
}}
|
||||
onContextMenu={(e) => {
|
||||
e.preventDefault();
|
||||
}}
|
||||
onCreated={(e) => {
|
||||
e.scene.background = new Color(0x19191d);
|
||||
}}
|
||||
gl={{ powerPreference: "high-performance", antialias: true, preserveDrawingBuffer: true }}
|
||||
>
|
||||
<Canvas
|
||||
id="sceneCanvas"
|
||||
shadows
|
||||
color="#aaaa"
|
||||
eventPrefix="client"
|
||||
style={{
|
||||
pointerEvents: 'none'
|
||||
}}
|
||||
onContextMenu={(e) => {
|
||||
e.preventDefault();
|
||||
}}
|
||||
onCreated={(e) => {
|
||||
e.scene.background = new Color(0x19191d);
|
||||
}}
|
||||
gl={{ powerPreference: "high-performance", antialias: true, preserveDrawingBuffer: true }}
|
||||
>
|
||||
|
||||
<Sun />
|
||||
<Sun />
|
||||
|
||||
<Shadows />
|
||||
<Shadows />
|
||||
|
||||
<ControlsDuplicate />
|
||||
<ControlsDuplicate />
|
||||
|
||||
<PostProcessingDuplicate />
|
||||
<PostProcessingDuplicate />
|
||||
|
||||
<Environment files={background} environmentIntensity={1.5} />
|
||||
<Environment files={background} environmentIntensity={1.5} />
|
||||
|
||||
<BuilderDuplicate projectId={projectId} />
|
||||
<BuilderDuplicate projectId={projectId} />
|
||||
|
||||
<SimulationDuplicate projectId={projectId} />
|
||||
</Canvas>
|
||||
</SceneProvider>
|
||||
<SimulationDuplicate />
|
||||
</Canvas>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user