Skip to content
Permalink
Browse files

fix SIP

  • Loading branch information
NEDJIMAbelgacem authored and wonder-sk committed Jan 13, 2021
1 parent 432f29b commit b5e6033a88ae2bc341afffbb067e2c7b0deac549
@@ -92,7 +92,7 @@ the number of points returned to ``pointsLimit`` points

SIP_PYLIST getPointsOnRay( const QVector3D &rayOrigin, const QVector3D &rayDirection, double maxScreenError, double cameraFov, int screenSizePx, double pointAngle, int pointsLimit = 1000 );
%Docstring
Returns the Points that are on a ray
Returns the points that are on a ray

:param rayOrigin: : The origin of the ray in layer coordinates
:param rayDirection: : The direction of the ray in layer coordinates
@@ -102,13 +102,13 @@ Returns the Points that are on a ray
:param pointAngle: : the maximum accepted angle between the point and it's projected point on the ray in degrees
:param pointsLimit: : the maximum number of points returned

:return: a vector of the identified points
:return: a list of the identified points

.. versionadded:: 3.18
%End
%MethodCode
{
QVector<QMap<QString, QVariant>> res = sipCpp->identify( *a0, *a1, a2, a3, a4, a5, a6 );
QVector<QMap<QString, QVariant>> res = sipCpp->getPointsOnRay( *a0, *a1, a2, a3, a4, a5, a6 );
sipRes = PyList_New( res.size() );
for ( int i = 0; i < res.size(); ++i )
{
@@ -198,7 +198,9 @@ class CORE_EXPORT QgsBox3d
*/
bool contains( const QgsPoint &point ) const;

//! Returns shortest distance from the box to a point
/**
* Returns shortest distance from the box to a point
*/
float distanceFromPoint( double x, double y, double z );

/**
@@ -125,24 +125,24 @@ class CORE_EXPORT QgsPointCloudDataProvider: public QgsDataProvider
#ifndef SIP_RUN

/**
* Returns the Points that are on a ray
* Returns the points that are on a ray
*
* \param rayOrigin : The origin of the ray in layer coordinates
* \param rayDirection : The direction of the ray in layer coordinates
* \param maxScreenError : Maximum screen error (as taken from the 3D point cloud layer renderer)
* \param cameraFov : The field of view of the camera in degrees
* \param screenSizePx : The size of the screen's viewport in pixels
* \param pointAngle : the maximum accepted angle between the point and it's projected point on the ray in degrees
* \param pointsLimit : the maximum number of points returned
* \return a list of the identified points
* \param pointAngle : The maximum accepted angle between the point and it's projected point on the ray in degrees
* \param pointsLimit : The maximum number of points returned
* \return a vector of the identified points
*
* \since QGIS 3.18
*/
QVector<QVariantMap> getPointsOnRay( const QVector3D &rayOrigin, const QVector3D &rayDirection, double maxScreenError, double cameraFov, int screenSizePx, double pointAngle, int pointsLimit = 1000 );
#else

/**
* Returns the Points that are on a ray
* Returns the points that are on a ray
*
* \param rayOrigin : The origin of the ray in layer coordinates
* \param rayDirection : The direction of the ray in layer coordinates
@@ -151,14 +151,14 @@ class CORE_EXPORT QgsPointCloudDataProvider: public QgsDataProvider
* \param screenSizePx : The size of the screen's viewport in pixels
* \param pointAngle : the maximum accepted angle between the point and it's projected point on the ray in degrees
* \param pointsLimit : the maximum number of points returned
* \return a vector of the identified points
* \return a list of the identified points
*
* \since QGIS 3.18
*/
SIP_PYLIST getPointsOnRay( const QVector3D &rayOrigin, const QVector3D &rayDirection, double maxScreenError, double cameraFov, int screenSizePx, double pointAngle, int pointsLimit = 1000 );
% MethodCode
{
QVector<QMap<QString, QVariant>> res = sipCpp->identify( *a0, *a1, a2, a3, a4, a5, a6 );
QVector<QMap<QString, QVariant>> res = sipCpp->getPointsOnRay( *a0, *a1, a2, a3, a4, a5, a6 );
sipRes = PyList_New( res.size() );
for ( int i = 0; i < res.size(); ++i )
{

0 comments on commit b5e6033

Please sign in to comment.
You can’t perform that action at this time.