Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
otb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
273
Issues
273
List
Boards
Labels
Service Desk
Milestones
Merge Requests
8
Merge Requests
8
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Main Repositories
otb
Commits
01c73bcf
Commit
01c73bcf
authored
Jan 08, 2010
by
Manuel Grizonnet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
DOC: vectorIO example
parent
2cfd35e7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
1 deletion
+16
-1
Examples/IO/VectorDataIOExample.cxx
Examples/IO/VectorDataIOExample.cxx
+15
-0
Examples/OBIA/ShapeAttributeComputation.cxx
Examples/OBIA/ShapeAttributeComputation.cxx
+1
-1
No files found.
Examples/IO/VectorDataIOExample.cxx
View file @
01c73bcf
...
...
@@ -31,6 +31,9 @@
// Even though specific reader/writer for Shapefile and the Google KML
// are available in OTB, we designed a generic approach for the IO of
// this kind of data.
// The reader/writer for VectorData in OTB is able to access to a variety of
// vector file formats (all OGR supported formats)
//
// In section \ref{sec:VectorDataProjection}, you will find more information on
// how projections work for the vector data and how you can export
...
...
@@ -260,4 +263,16 @@ int main(int argc, char * argv[])
// Software Guide : EndCodeSnippet
return
EXIT_SUCCESS
;
// Software Guide : BeginLatex
//
// This example can convert an ESRI Shapefile to
// a MapInfo File but you can also access with the same OTB source code
// to a PostgreSQL datasource,using a connection string as :
// PG:"dbname='databasename' host='addr' port='5432' user='x' password='y'"
// Starting with GDAL 1.6.0, the set of tables to be scanned can be overridden
// by specifying tables=[schema.]table[(geom_column_name)].
// Software Guide : EndLatex
// Software Guide : BeginCodeSnippet
}
Examples/OBIA/ShapeAttributeComputation.cxx
View file @
01c73bcf
...
...
@@ -67,7 +67,7 @@ int main(int argc, char * argv[])
typedef
itk
::
LabelImageToLabelMapFilter
<
ImageType
,
LabelMapType
>
ConverterType
;
ConverterType
::
Pointer
converter
=
ConverterType
::
New
();
converter
->
SetInput
(
reader
->
GetOutput
()
);
// converter->SetForegroundValue( atoi(argv[2]
) );
converter
->
SetBackgroundValue
(
itk
::
NumericTraits
<
LabelType
>::
min
(
)
);
typedef
itk
::
ShapeLabelMapFilter
<
LabelMapType
>
ShapeFilterType
;
ShapeFilterType
::
Pointer
shape
=
ShapeFilterType
::
New
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment