Skip to content

Commit

Permalink
In render_for_Overlay_picking use pick_begin/pick_end
Browse files Browse the repository at this point in the history
  • Loading branch information
alja committed Nov 9, 2023
1 parent dfdc1e2 commit 3f25f99
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions ui5/eve7/lib/GlViewerRCore.js
Original file line number Diff line number Diff line change
Expand Up @@ -706,7 +706,7 @@ sap.ui.define([

let state = this.rqt.pick(x, y, detect_depth);

console.log("pick state", state);
console.log("pick state object", state.object);

if (state.object === null) {
this.rqt.pick_end();
Expand Down Expand Up @@ -741,18 +741,18 @@ sap.ui.define([

render_for_Overlay_picking(x, y, detect_depth)
{
// console.log("RENDER FOR PICKING", this.scene, this.camera, this.canvas, this.renderer);
// console.log("RENDER FOR OVERLAY PICKING", this.scene, this.camera, this.canvas, this.renderer);

if (this.canvas.width <= 0 || this.canvas.height <= 0) return null;

//this.rqt.pick_begin(x, y);
this.rqt.pick_begin(x, y);

let state_overlay = this.rqt.pick_overlay(x, y, detect_depth);

console.log("Overlay pick state", state_overlay);

if (state_overlay.object === null) {
//this.rqt.pick_end();
this.rqt.pick_end();
return null;
}

Expand All @@ -766,7 +766,7 @@ sap.ui.define([
if (state_overlay.eve_el.fSecondarySelect)
this.rqt.pick_instance_overlay(state_overlay);

//this.rqt.pick_end();
this.rqt.pick_end();

state_overlay.w = this.canvas.width;
state_overlay.h = this.canvas.height;
Expand Down

0 comments on commit 3f25f99

Please sign in to comment.