I am generating png images of concentration maps, resulting from air quality modelling. Resulting files are croped and coverted to tiff files and than loaded into QGIS in Python:
rlayer = QgsRasterLayer(data_folder+parametr+'.tif',opis_txt) projectInstance.addMapLayer(rlayer)
Then I load a pre-defiend QgsPrintoutLayout and export the results to a pdf file. Everything works fine, however by default raster is interpolated using Nearest Neighborhood which creates pixelized results.
In QGIS interface I can switch the resampling method for each layer to cubic or bilnear and this solves my problem, however I would like to do it automatically. So my question is can I do the same in Python script?