Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
otb
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
David Youssefi
otb
Commits
0af647de
Commit
0af647de
authored
15 years ago
by
Emmanuel Christophe
Browse files
Options
Downloads
Patches
Plain Diff
OTB classes (WIP)
parent
413f19e8
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
CMakeLists.txt
+4
-1
4 additions, 1 deletion
CMakeLists.txt
mapnikOTBClasses.cxx
+3
-1
3 additions, 1 deletion
mapnikOTBClasses.cxx
otbVectorDataToImageFilter.h
+47
-0
47 additions, 0 deletions
otbVectorDataToImageFilter.h
otbVectorDataToImageFilter.txx
+30
-0
30 additions, 0 deletions
otbVectorDataToImageFilter.txx
with
84 additions
and
2 deletions
CMakeLists.txt
+
4
−
1
View file @
0af647de
...
...
@@ -22,4 +22,7 @@ ADD_EXECUTABLE(myOwnMapnik myOwnMapnik.cxx)
TARGET_LINK_LIBRARIES
(
myOwnMapnik mapnik
)
ADD_EXECUTABLE
(
mapnikFromVectorData mapnikFromVectorData.cxx
)
TARGET_LINK_LIBRARIES
(
mapnikFromVectorData OTBCommon OTBIO mapnik
)
\ No newline at end of file
TARGET_LINK_LIBRARIES
(
mapnikFromVectorData OTBCommon OTBIO mapnik
)
ADD_EXECUTABLE
(
mapnikOTBClasses mapnikOTBClasses.cxx
)
TARGET_LINK_LIBRARIES
(
mapnikOTBClasses OTBCommon OTBIO
)
This diff is collapsed.
Click to expand it.
mapnikOTBClasses.cxx
+
3
−
1
View file @
0af647de
#include
"otbVectorDataFileReader.h"
#include
"otbImageFileWriter.h"
#include
"otbVectorData.h"
#include
"otbVectorDataProjectionFilter.h"
#include
<fstream>
...
...
@@ -12,6 +13,7 @@ int main(int argc, char * argv[])
{
//Read the vector data
typedef
otb
::
VectorData
<>
VectorDataType
;
typedef
otb
::
VectorDataFileReader
<
VectorDataType
>
VectorDataFileReaderType
;
VectorDataFileReaderType
::
Pointer
reader
=
VectorDataFileReaderType
::
New
();
...
...
@@ -25,7 +27,7 @@ int main(int argc, char * argv[])
//Convert the vector data into an image
typedef
itk
::
RGBAPixel
<
unsigned
char
>
PixelType
;
typedef
otb
::
Image
<
PixelType
>
ImageType
;
typedef
otb
::
Image
<
PixelType
,
2
>
ImageType
;
typedef
otb
::
VectorDataToImageFilter
<
VectorDataType
,
ImageType
>
VectorDataToImageFilterType
;
VectorDataToImageFilterType
::
Pointer
vectorDataRendering
=
VectorDataToImageFilterType
::
New
();
vectorDataRendering
->
SetInput
(
projection
->
GetOutput
());
...
...
This diff is collapsed.
Click to expand it.
otbVectorDataToImageFilter.h
0 → 100644
+
47
−
0
View file @
0af647de
/*=========================================================================
Program: ORFEO Toolbox
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) Centre National d'Etudes Spatiales. All rights reserved.
See OTBCopyright.txt for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notices for more information.
=========================================================================*/
#ifndef __otbVectorDataToImageFilter_h
#define __otbVectorDataToImageFilter_h
#include
"itkImageSource.h"
namespace
otb
{
/** \class VectorDataToImageFilter
* \brief Render a vector data into an image
*
*/
template
<
class
TVectorData
,
class
TImage
>
class
VectorDataToImageFilter
:
public
itk
::
ImageSource
{
};
// end class
}
// end namespace otb
#ifndef OTB_MANUAL_INSTANTIATION
#include
"otbVectorDataToImageFilter.txx"
#endif
#endif
\ No newline at end of file
This diff is collapsed.
Click to expand it.
otbVectorDataToImageFilter.txx
0 → 100644
+
30
−
0
View file @
0af647de
/*=========================================================================
Program: ORFEO Toolbox
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) Centre National d'Etudes Spatiales. All rights reserved.
See OTBCopyright.txt for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notices for more information.
=========================================================================*/
#ifndef __otbVectorDataToImageFilter_txx
#define __otbVectorDataToImageFilter_txx
namespace otb
{
}
#endif
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment