An object-oriented programming language

learn more… | top users | synonyms

1
vote
1answer
40 views

Georeferencing las files using liblas

I am trying to write georeferencing information to a '.las' file using liblas and c++. Here is my code: ofstream ofs; ofs.open("test.las", ios::out | ios::binary); liblas::Header header; ...
3
votes
2answers
60 views

How to create a dashed polygon border in C++?

In my maps I have a symbol, his type is polygon, I want to change the line style of the border, actually is solid , I had to put it in dash Is there a simple way to change it ? i think to the ...
0
votes
1answer
140 views

gdal_contour transparent contour as png

I started using the GDAL Library in a c++ project. It is a great library, but I am a bit stuck right now with different aspects of it. What is the best way to use gdal_contour in my c++ programm? ...
0
votes
0answers
11 views

How can I extract the latitude and longitude from a s57 File [duplicate]

I had to extract the longitude and latitude from a s57 file, in order to superpose a satelite view from the same point. These coordinate will allow me to get the exact position on google map by ...
1
vote
1answer
20 views

Rendering of SVG for layer symbols using QGIS?

I have a little problem with the rendering of SVG for layer symbol. I want to creeate a categorized symbol to show different style of buoy I have for that two icons the first is an half circle ...
0
votes
0answers
18 views

Problem using EPSG:3395

in my application I use OGC:CRS83 for the coordinatereferencesystem, but now I had to change it to EPSG:3395 when I call : mQgsCoordinate->createFromOgcWmsCrs("EPSG:3395") there is nothing in ...
1
vote
1answer
29 views

How to render the Sea depth level in different color?

I would Like to adapt an old code in c++ using the api qgis 1.6 : const QgsRenderer* lrenderer = pLayer->renderer(); if( lrenderer == NULL ) lrenderer = new QgsSingleSymbolRenderer( ...
0
votes
0answers
9 views

Problem on rendering categorizedSymbolRendererV2

Finally my code works but the renderering display just one color instead of 4 I don't know why, I follow the sample code of the snorf.net website and the sample code in the qgis python programming ...
1
vote
0answers
7 views

How can I inject categorizedSymbolRenderer into My QgsFeatureRenderer?

I try to get the categorizedSymbolRenderer value in order to render them In all sample of code I found ( in python but not in c++ ) it said : renderer = QgsCategorizedSymbolRendererV2(expression , ...
0
votes
0answers
7 views

Why I have a SegFault on a newSymbol->setColor?

I am working in C++ and QT, I have to write an application based on the qgis c++ api 2.8.2. So, I try to do the same thing that the sample code in python on the webSite ...
1
vote
1answer
19 views

Information about the setDataDefinedProperty

In the QGis C++ API v1.6 there is a function called setlowerValue to set a value for a specific Symbol In my application i use QGis C++ API 2.8.2, i try to understand how the function ...
1
vote
0answers
34 views

Run C++ DLL in ArcMap 10.3

I've migrated a VB script that uses ArcObjects to a C++ Win32 DLL (using Visual Studio 2013). And now I would like to test my DLL by launching it from my ArcMap 10.3 installation. The problem is that ...
0
votes
0answers
7 views

Problem with the DSID Data Set Identification

In my s57 file, I need to set the extent of the mapcanvas, for that i use : mpMapCanvas->setExtent(mpS57->mMapplay.value(DSID)->extent()); but if I display the value of the extents xmin, ...
0
votes
1answer
20 views

Problem with QgsCoordinateReferenceSystem

I would like to change the coordinatereferencesystem for my application I have this code : QgsMapRenderer* myRender = mapRenderer(); mQgsCoordinate = new ...
1
vote
0answers
19 views

Non-Square Pixel on georeferencing of images using GDAL

I have a image in .jpg format. I have some GCP and also know the pixels values of these GCp in that image. Now i trying to convert this image into geotiff. for that I have coded the following lines. ...
0
votes
0answers
14 views

help for rendering s57 file

I am working on a specific project based on QT 4.5 and QGis API C++ 2.8.2 I have a S57 File, I want to load it, and render it into a canvas My canvas is created, the build and link is ok,no error, ...
0
votes
1answer
22 views

looking for documentation about exploiiting OSM file with c++ API

My application is written in QT4.6, i use the C++ API of QGIS 2.8.2 i had to read and display OpenStreetMap in my canvas in my application so, i am looking for some documentation or tutorial for ...
1
vote
0answers
14 views

How to fill a symbolLayer with a custom texture?

I have this code : pLayer is a QgsVectorLayer * QgsFeatureRendererV2 * lrenderer = pLayer->rendererV2(); QList<QgsSymbolV2 *> lSymbols = lrenderer->symbols(); QgsSymbolLayerV2 * ...
0
votes
0answers
11 views

how can i change property of a symbol using qgis 2.8 c++ api

i have an application written in QT 4.6, and use the C++ API of QGIS the application will display the data of the s57 file in a MapCanvas i managed to read the file but how can i , for a specific ...
1
vote
0answers
26 views

C++ Convert Lat Long to BNG with Proj.4

Im creating a plugin for VBS2. In the program I can output a grid in either LAT LONG,UTM or MGRS. I need to be able to convert to BNG. I have managed to create a TKinter application in python that ...
1
vote
2answers
179 views

GDAL Application crashes when loading GDAL drivers

I'm developing on QT an application that uses GDAL library (which I compiled using MinGW 4.8). When I use the application on my windows 8 laptop, it works fine, but when I tried using it on several ...
0
votes
1answer
19 views

GDAL Truncating/Normalizing Field names

While creating a ESRI-Shapefile using GDAL, it keeps truncating/normalizing my field names. Any reason why it does this? If the Field name is more than 10 characters it seems to do this. For example ...
0
votes
1answer
22 views

Error during building an application c++ using api qgis 2.8

I have an apllication that need an object the object type is QgsSymbolV2 but i cannot do that : QgsSymbolV2 * lSymbol = new QgsSymbolV2(); because in the class qgssymbolv2 there is no constructor ...
1
vote
0answers
12 views

where are old function of qgssymbol

in the new version of qgis 2.8, in the c++ API and in the class QgsSymbolV2, a lot of function has been deleted, by exemple setfillcolor, setcustomtexture, setnamedpoint, setpointsize i would like to ...
0
votes
0answers
16 views

OGRFeature set Multiple fields

Hi all to start off with: Using Gdal compiled with Xerces Coding in C++ with the QT Creator version 5.4.1 So my problem is im trying to use Gdal to create my own Esri shapefile, I get a strange ...
0
votes
1answer
29 views

Convert Polygons,Points,Lines to GML

I've got a vector of Points, Polygons, Lines. And I'm trying to convert the points into a GML file like a Web Feature Service. I've been doing some reading but cant find any methods that can do this? ...
1
vote
1answer
98 views

How to show a QGis map in Qt/C++ custom widget with QgsMapCanvas?

I'm trying to add a QGis map in Qt/C++ widget using QgsMapCanvas, but I have some problems... I'm working with the following environment: - Ubuntu 12.04 - QGis 2.8.1 - Qt Creator 2.4.1 (based on Qt ...
2
votes
1answer
241 views

How to load a *.qgs file in a C++ QGIS standalone app?

I'm using QGIS-2.4.0 API to develop a standalone app by C++. I saved a test.qgs file in QGIS Desktop software, in the project, there was one layer and it was visible. Then I loaded the test.qgs ...
0
votes
3answers
203 views

How to crop Geotiff image in C++ (GDAL or other possibilities)?

I am developing a code to process a geotiff image. But firsly I need to crop a geotiff image preserving its metadata (projection...) in C++. My idea it's to provide the corners and the geotiff image ...
0
votes
0answers
40 views

Is there an open source solution to access raster layers in an ESRI File-GeoDatabase?

I'm looking for a way to access raster layers in an Esri File-GeoDatabase without using ArcObjects or ArcPy, specifically I would like to access the raster layers with GDAL. I understand that the GDAL ...
1
vote
0answers
26 views

C++ QGIS Conditional Label Colouring

I am using QGIS and C++. When I create a layer of polygons with labels in the center I am able to use a RuleBasedRenderer to control the background colour of the polygon. How do I similarly control ...
1
vote
1answer
134 views

Sample for MS Visual Studio C++ using GDAL library

Good day, I need to create a sample console application on c++ that will use *.hdf file as an input and will read it. As I got, I need a GDAL library. I've found a GDAL tutorial on official GDAL ...
1
vote
1answer
49 views

Set up GDAL for C++ in RHEL

I've got GDAL installed from the latest 1.11.2 source, but when I try to make by C++ executable I get undefined references to "GDALAllRegister" and basically all the GDAL functions I call. The same ...
0
votes
1answer
14 views

Gdal/OGR LayerMetaData not parsing its value

To start off with: Using Gdal/Ogr compiled with Xerces to read a WFS Reading from a WFS version 1.0.0 Compiler is QT version 5.4.1 ( C++ ) So I'm trying to get all the capabilities of a WFS via ...
2
votes
1answer
653 views

Looking for QGIS 2.4 C++ Hello World example?

In the project I'm working on (C/C++/Qt application), we are trying to integrate QGIS (latest version desirable, 2.4 for the moment). But there is very little information in the web on how to use QGIS ...
1
vote
0answers
18 views

C++ Get Capabilities from a WFS

To start off with: Coding in C++ Using the QT Creator Reading from WFS Version 1.1.0 Using Gdal/OGR compiled with Xerces Hi all so I'm trying to get all of the Capabilities from a WFS. I know how ...
1
vote
1answer
42 views

Getting Feature names from WFS in C++

to start off with: Coding in C++ Using WFS Version 1.0.0 Using QT 5.4.1 Windows 8 Latest versions I'm trying to read in a WFS in code via Gdal compiled with Xerces - I'm able to read the GML ...
0
votes
0answers
51 views

How to remove a QgsMapCanvasLayer from QgsMapCanvas with PyQGIS || C++?

I try to find a way to remove a QgsMapCanvasLayer from the QgsMapCanvas. At the moment I only can delete the MapLayer from the QgsMapLayerRegistry with: ...
1
vote
0answers
41 views

QGis Application Debugging - missing source problem at setScene method in QgsMapCanvas class [closed]

I develop a app in C++ with Qgis components with VS2010 Prof on Windows 7. Compiling a release succeeded and the app´s behaviour is as expected. Nevertheless I would like to take advantage of the ...
0
votes
1answer
81 views

QGIS C++ Hello World example crashing

I have written a very simple C++/Qt application using QGIS comprised of a single "main.cpp" file as below: #include <qgsapplication.h> int main(int argc, char ** argv) { QgsApplication ...
1
vote
1answer
87 views

Run C++ standalone application in debug mode

I write simple C++ standalone application using QGIS. It works and render vector layers from PostgeSQL database. #define CORE_EXPORT __declspec(dllimport) #define GUI_EXPORT __declspec(dllimport) ...
0
votes
3answers
118 views

Using GDAL/C++ to calculate distance in meters

I'm using GDAL in C++, with WGS84. I want to calculate distance between two points in meters. The code snippet below tries to find the distance between 25N/75E and 25N/76E. The code, as is, returns ...
2
votes
1answer
99 views

Implement r.cross / ArcGIS Combine with GDAL

I am using GDAL to process a lot of rasters. I then need to combine all the arrays to create a single output raster that represents all the unique combinations of values. I.E the same thing as ...
0
votes
1answer
46 views

What packages are required to install C++ API on Linux Mint 17?

What packages are required to install C++ API on Linux Mint 17? I already have access to the Python API (installed via “python-qgis” package), but no C++.
0
votes
1answer
191 views

How to convert latitude, longitude to EPSG 3857?

I'm looking to study the math involved to see how a given latitude and longitude in decimal degrees can be converted to epsg 3857. Can anybody point to a good reference or a possible python/c/c++/java ...
1
vote
2answers
116 views

QGIS Rule Based Rendering

I am looking for an example of how to use the QgsRuleBasedRendererV2 to filter features of a layer based on an attribute value (0 or 1). Has anyone done this in Python or C++?
0
votes
0answers
57 views

GDAL, Georeferencing

I have been trying to use GDAL library to add geoinformation to an image. From the documentation from GDAL web page I could find that I could use GDAlSetGeotransform(), for that I need a six ...
0
votes
0answers
14 views

qgis (WIN): change settings from registry to INI

I have built qgis on windows 7, and need to stop the settings from being written to the registry. Is there a way to have an ini file created and used instead? (Having trouble finding that code)
0
votes
0answers
37 views

Using GDAL with a line layer and points layer, find next point along line layer

With the points layer and line layer, I'm trying to create a graph for path finding. I've got a line layer that I've dissolved, thinking that might make this easier. The points in the points layer lie ...
2
votes
1answer
33 views

Loading Raster using QGIS API in Windows

I am trying to develop a C++ application using QGIS. I have to load a tif file and show it. First I wrote an app similar to samples on the internet. It works on Linux, but it does not work on ...