I need to run some calculations on some raster points, as I'm trying to find the highest point in a given radius around where the mouse is clicked. So far I've managed to get the X and Y coordinates clicked by the mouse, and a radius value specified by the user. I've also been able to create a QgsCircle object around this point with the given radius as shown below:
pointX = clickedPoint[0]
pointY = clickedPoint[1]
point = QgsPoint(pointX, pointY)
radius = self.sbRadius.value()
mainRaster = self.cbTerrainLayer.currentLayer()
circleToChooseFrom = QgsCircle(point, radius)
Where would I go next from here, if I was wanting to get this circular portion of the main raster, with all of the point and elevation values in the radius? I was thinking of using the qgis drape (setzfromraster) processing tool, on the QgsCircle, but this seems to require a vector layer (not a QgsCircle) and I'm not entirely sure if it would do what is needed.