Hi,
I’ve read in another topic it could be anisotropic, but this is not my case.
I’m developing an editor plugin. The user should be able to place Boxes as he clicks in the scene. I was using PDI’s DrawPoint in the first place, but I need the box size to be consistent with world dimensions and DrawPoint’s entities change the size as I zoom in the scene.
My plugin’s tool class inherits from UMeshSurfacePointTool and overrides OnUpdateDragMethod, this adds elements to the container:
void UPainterTool::OnUpdateDrag(const FRay& Ray)
{
FHitResult OutHit;
if (HitTest(Ray, OutHit))
{
auto halfThickness = Settings->Thickness / 2;
v1.SetX(OutHit.ImpactPoint.X - halfThickness);
v1.SetY(OutHit.ImpactPoint.Y - halfThickness);
v1.SetZ(OutHit.ImpactPoint.Z - halfThickness);
Vector v2;
v2.SetX(OutHit.ImpactPoint.X + halfThickness);
v2.SetY(OutHit.ImpactPoint.Y + halfThickness);
v2.SetZ(OutHit.ImpactPoint.Z + halfThickness);
//add element to container
m_childInterface->Hit(&v1, &v2, (void*)&Settings->Thickness);
The elements are rendered in the tool’s render class, looping through the container:
DrawDebugBox(GetWorld(), FVector(elem->m_min->X(), elem->m_min->Y(), elem->m_min->Z()), FVector(elem->m_max->X(), elem->m_max->Y(), elem->m_max->Z()), outColor.ToFColor(false), false, 1, 1.0f);
elem = m_childInterface->GetNext();
I’ve been trying rendering options in the editor without any luck
Any ideas?
Best regards.