view
Tweet
hifi: #21448 Correctly Size Bounding Boxes for Polylines

Polylines currently have 10m bounding boxes. Implement a correctly sized bounding box. You should calculate the size of the bounding box relative to the actual polyline drawing itself.

Comments & Activity

  • 2 mnths, 13 days ago

    #21448 created by themelissabrown Status set to Bidding.

  • @themelissabrown

    Hi Melissa,

    1. Could you please tell us where in the UI of the Application do Polylines and bounding boxes come into picture, so that we can relate the UI to the code and proceed further with our analysis.

    2. We checked the code directly to find out which part works on polylines and found 2 methods in hifi\libraries\entities\src\PolyLineEntityItem.cpp: PolyLineEntityItem::appendPoint() and PolyLineEntityItem::setLinePoints()

    Both these methods have the logic to check if the point is outside entity's bounding box. So, we right now think that this could be the area where the logic has to be modified. In both these methods, there is a call to getDimensions() to get the dimensions of halfBox. If the point x,y,z is within the halfBox x,y,z then it is appended to the poly line else not.

    So, we think there is a possibility that the logic needs to be changed around this area such that the halfBox dimensions are relative to the polyline drawing itself.

    So, please reply so that we can continue with further analysis and bid accordingly
  • 2 mnths, 12 days ago

    A bid was placed on #21448

  • 2 mnths, 12 days ago

    Bid updated on #21448

  • @themelissabrown
    Hey Melissa,
    I see a bid here already by someone else. So, can I continue working on this issue? Also, if yes, could you please reply on our query above ?
  • You they can find where polyines are surfaced in the Fingerpaint app. The bounding box is calculated as part of the geometry. Image attached.
  • 2 mnths, 8 days ago

    themelissabrown uploaded an attachment to #21448

  • @ravi-raman I haven't accepted a bid yet as I was waiting for you to explore and make a bid, but keep in mind that this task probably requires you to dig into our rendering engine.
  • @themelissabrown
    1. I saw the attached screenshot. My understanding is that in the screenshot the red color outlined box is the bounding box and this bounding box is always 10m i.e. it has x = 10, y = 10 and z = 10 and is not relative w.r.t. the polylines as it should be.

    So, to make the bounding box dimensions relative to the polylines, we need to modify the Fingerpaint app i.e. fingerPaint.js so that the x, y and z values of the dimensions property of the added entity are adjusted according to the polylines.

    So, is my understanding correct ?

    2. Also, if point 1 is correct, then this would cover only one such category i.e. of polylines. There are many other occurrences like for eg. in voxels.js, for type = PolyVox and name = terrain we again have the dimensions as 16m (i.e. x = 16, y = 16 and z = 16), so in that case here too a similar change would be required.

    Do we need to cover all such occurrences ?

    3. Also, please note that in the UI (Create menu option and List tab), I could get entries with type as "PolyVox" and name as "terrain". But I could not manage to get type as "PolyLine" and name as "fingerPainting" . So, how do we get these entries ?

    Kindly reply to the above 3 points.
  • No Ravi, that approach is not correct. We don't specifically want fingerpaint.js edited. That was simply a reference point so you could look in the code and find where/how polylines are. I'm goo to accept the other bid and we can work together to find something for your team to complete.
  • 2 mnths, 7 days ago

    themelissabrown accepted 1000.00 from rickdaniels on #21448 Status set to In Progress.

  • 23 days, 8 hrs ago

    #21448 updated by themelissabrown Changes: Status set to Done.

Labels Saved!

Bids

Login to bid
Who Amount Done in ...
*name hidden*$ ***3 days