LuciadCPillar 2023.1.04
luciad::MapNavigator::BoundsConstraintOptions Class Referencefinal

Options to configure the constraint to restrict the navigation to specific bounds. More...

#include <luciad/maps/MapNavigator.h>

Public Member Functions

const std::optional< Bounds > & getBounds () const
 Returns the bounds constraining the camera. More...
 
double getPadding () const
 Returns the padding that is added to the bounds constraint options. More...
 
bool isEnabled () const
 
void setBounds (Bounds bounds)
 Sets the bounds constraining the camera. More...
 
void setEnabled (bool enabled)
 Enables or disables the constraint The default is true. More...
 
void setPadding (double padding)
 Sets the padding that is added to the bounds constraint options. More...
 

Detailed Description

Options to configure the constraint to restrict the navigation to specific bounds.

See MapNavigator::getBoundsConstraint for more information.

Since
2021.1

Member Function Documentation

◆ getBounds()

const std::optional< Bounds > & luciad::MapNavigator::BoundsConstraintOptions::getBounds ( ) const

Returns the bounds constraining the camera.

Returns
the bounds constraining the camera.
See also
setBounds

◆ getPadding()

double luciad::MapNavigator::BoundsConstraintOptions::getPadding ( ) const

Returns the padding that is added to the bounds constraint options.

Returns
the additional padding (in device independent pixels) that is added to the bounds.
See also
setPadding

◆ isEnabled()

bool luciad::MapNavigator::BoundsConstraintOptions::isEnabled ( ) const
Returns
if the constraint is enabled

◆ setBounds()

void luciad::MapNavigator::BoundsConstraintOptions::setBounds ( Bounds  bounds)

Sets the bounds constraining the camera.

The default value is std::nullopt.

Parameters
boundsthe bounds to constrain the main camera.

◆ setEnabled()

void luciad::MapNavigator::BoundsConstraintOptions::setEnabled ( bool  enabled)

Enables or disables the constraint The default is true.

Parameters
enabledtrue to enable the constraint or false to disable it

◆ setPadding()

void luciad::MapNavigator::BoundsConstraintOptions::setPadding ( double  padding)

Sets the padding that is added to the bounds constraint options.

The padding is expressed in device independent pixels. It is applied to the bounds.

This can for example be useful to make sure lines (with a pixel-sized width) or labels (with a pixel width/height), can still be displayed.

The default is 0.

Parameters
paddingthe padding that is added to the bounds.