Skip to content

[BUG] Gizmo #51

@Identity-labs

Description

@Identity-labs

You can't switch from translate to rotate mode it's breaking the gizmo, and you can go back to translate mode after that

"ngx-three": "^0.31.0",
"rxjs": "~7.8.1",
"three": "^0.164.1",
"@types/three": "~0.164.0",
<th-canvas [thStats]="true" [renderOnDemand]="renderOnDemand" #canvas>
    <th-scene>
        <th-mesh #model
            [(position)]="selectedElementPosition"
            [(rotation)]="selectedElementRotation"
            [(scale)]="selectedElementScale">
        </th-mesh>

        <th-perspectiveCamera
            [ngSwitch]="controlType"
            #camera
            [position]="cameraPosition"
            [rotation]="cameraRotation"
        >
            <th-orbitControls *ngSwitchCase="'orbit'" />
            <th-mapControls *ngSwitchCase="'map'" />
            <th-arcballControls *ngSwitchCase="'arcball'" />
            <th-transformControls *ngSwitchCase="'transform'"
                [object]="model.objRef"
                [mode]="editorMode"
                [threeEvents]="transformEvents" />
            <th-dragControls
                *ngSwitchCase="'drag'"
                [args]="[[model.objRef], camera.objRef, canvas.hostElement.nativeElement]"
            />
            <th-flyControls *ngSwitchCase="'fly'" />
            <th-trackballControls *ngSwitchCase="'trackball'" />
            <th-firstPersonControls *ngSwitchCase="'firstpersion'" />
        </th-perspectiveCamera>
    </th-scene>
</th-canvas>

I change editorMode width addEventListener on keydown
You can go back to translate mode without any error but control is not showing

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions