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
721b2be0
Commit
721b2be0
authored
17 years ago
by
Thomas Feuvrier
Browse files
Options
Downloads
Patches
Plain Diff
Correction : ajout itkGenericExceptionMacro et EXIT_FAILURE
parent
f62e242f
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Testing/Utilities/ossimIntegrationTest.cxx
+25
-7
25 additions, 7 deletions
Testing/Utilities/ossimIntegrationTest.cxx
with
25 additions
and
7 deletions
Testing/Utilities/ossimIntegrationTest.cxx
+
25
−
7
View file @
721b2be0
...
...
@@ -43,6 +43,8 @@
// without this alll the important factories are not created.
#include
"init/ossimInit.h"
#include
"itkMacro.h"
using
namespace
std
;
void
usage
();
...
...
@@ -52,6 +54,9 @@ ossimProjection* newUtmView(const ossimGpt& centerGround,
int
ossimIntegrationTest
(
int
argc
,
char
*
argv
[])
{
try
{
ossimInit
::
instance
()
->
initialize
(
argc
,
argv
);
if
(
argc
!=
4
)
...
...
@@ -72,14 +77,14 @@ int ossimIntegrationTest(int argc, char* argv[])
if
(
!
handler
)
{
cout
<<
"Unable to open input image: "
<<
argv
[
2
]
<<
endl
;
return
1
;
itkGenericExceptionMacro
(
<<
"Unable to open input image: "
<<
std
::
string
(
argv
[
2
])
)
;
return
EXIT_FAILURE
;
}
if
(
!
writer
)
{
cout
<<
"Unable to create writer of type: "
<<
argv
[
1
]
<<
endl
;
delete
handler
;
return
1
;
itkGenericExceptionMacro
(
<<
"Unable to create writer of type: "
<<
std
::
string
(
argv
[
1
])
);
return
EXIT_FAILURE
;
}
ossimKeywordlist
geom
;
...
...
@@ -91,10 +96,10 @@ int ossimIntegrationTest(int argc, char* argv[])
if
(
!
inputProjection
)
{
cout
<<
"the input image has no input projection and can't be reprojected"
<<
endl
;
delete
handler
;
delete
writer
;
return
1
;
itkGenericExceptionMacro
(
<<
"the input image has no input projection and can't be reprojected
\n
"
);
return
EXIT_FAILURE
;
}
// --------------------- SETUP The Resampleing process -------------
...
...
@@ -137,7 +142,20 @@ int ossimIntegrationTest(int argc, char* argv[])
delete
handler
;
}
return
EXIT_SUCCESS
;
}
catch
(
itk
::
ExceptionObject
&
err
)
{
std
::
cout
<<
"Exception itk::ExceptionObject levee !"
<<
std
::
endl
;
std
::
cout
<<
err
<<
std
::
endl
;
return
EXIT_FAILURE
;
}
catch
(...)
{
std
::
cerr
<<
"Unknowed exception thrown"
<<
std
::
endl
;
return
EXIT_FAILURE
;
}
return
EXIT_SUCCESS
;
}
...
...
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