Skip to content

Commit

Permalink
PROJECTNAME -> PROJECT_NAME, unsigned int correctly compared. Warning…
Browse files Browse the repository at this point in the history
… and error debug for windows in progress..
  • Loading branch information
giuliavezzani committed Apr 28, 2016
1 parent f86eefe commit 05b2be2
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
4 changes: 1 addition & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,12 @@ add_executable(${PROJECT_NAME} ${sources} src/idl.thrift ${PROJECT_NAME}.xml ${I
#add_executable(${PROJECT_NAME} ${sources} src/idl.thrift ${IDL_GEN_FILES})
target_link_libraries(${PROJECT_NAME} ${YARP_LIBRARIES} ${OpenCV_LIBRARIES} ${IPOPT_LIBRARIES})

add_subdirectory(app)

install(TARGETS ${PROJECTNAME} DESTINATION bin)
icubcontrib_add_uninstall_target()

# app and conf
file(GLOB conf ${CMAKE_CURRENT_SOURCE_DIR}/conf/*.ini)
yarp_install(FILES ${conf} DESTINATION ${ICUBCONTRIB_CONTEXTS_INSTALL_DIR}/${PROJECTNAME})
yarp_install(FILES ${conf} DESTINATION ${ICUBCONTRIB_CONTEXTS_INSTALL_DIR}/${PROJECT_NAME})
file(GLOB scripts ${CMAKE_CURRENT_SOURCE_DIR}/app/scripts/*.template)
yarp_install(FILES ${scripts} DESTINATION ${ICUBCONTRIB_APPLICATIONS_TEMPLATES_INSTALL_DIR})
yarp_install(FILES ${PROJECT_NAME}.xml DESTINATION ${ICUBCONTRIB_MODULES_INSTALL_DIR})
4 changes: 2 additions & 2 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ class SuperqModule : public RFModule,
double tol, sum;
double max_cpu_time;
int acceptable_iter,max_iter;
int optimizer_points;
unsigned int optimizer_points;
string mu_strategy,nlp_scaling_method;
Vector x;
double t_superq;
Expand Down Expand Up @@ -410,7 +410,7 @@ class SuperqModule : public RFModule,
if (config_ok)
config_ok=configSuperq(rf);

if (config_ok==true)
if ((config_ok==true) && (file_on==false))
config_ok=configViewer(rf);

return config_ok;
Expand Down
4 changes: 2 additions & 2 deletions src/superquadric.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class SuperQuadric_NLP : public Ipopt::TNLP
}

/****************************************************************/
void setPoints(const deque<Vector> &point_cloud, bool &mode_on, const int &optimizer_points)
void setPoints(const deque<Vector> &point_cloud, bool &mode_on, const unsigned int &optimizer_points)
{
if (point_cloud.size()<optimizer_points)
{
Expand All @@ -74,7 +74,7 @@ class SuperQuadric_NLP : public Ipopt::TNLP
{
int count=point_cloud.size()/optimizer_points;

for (int i=0; i<point_cloud.size(); i+=count)
for (size_t i=0; i<point_cloud.size(); i+=count)
{
points_downsampled.push_back(point_cloud[i]);
}
Expand Down

0 comments on commit 05b2be2

Please sign in to comment.