forked from nasa/astrobee
-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ros2 opencv4 from Ana's branch #2
Open
joris997
wants to merge
6
commits into
DISCOWER:main
Choose a base branch
from
joris997:ros2_opencv4
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
7b7b761
fixed import issue for trapezoid planner and ff_common
joris997 c66d026
Merge pull request #1 from DISCOWER/dev-world
joris997 560f12e
Merge pull request #2 from DISCOWER/dev-world
joris997 b4bb167
added installation instructions for opencv4
joris997 51e34d7
added opencv4 installation to docker file
joris997 7f066be
merge with main
joris997 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule astrobee_media
added at
316dd6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
apt-get purge -y libopencv* | ||
|
||
cd /home | ||
mkdir opencv && cd opencv | ||
|
||
wget https://github.com/opencv/opencv/archive/refs/tags/4.2.0.zip | ||
unzip 4.2.0.zip | ||
rm 4.2.0.zip | ||
wget https://github.com/opencv/opencv_contrib/archive/refs/tags/4.2.0.zip | ||
unzip 4.2.0.zip | ||
rm 4.2.0.zip | ||
|
||
sudo apt update | ||
sudo apt install build-essential cmake git pkg-config libgtk-3-dev \ | ||
libavcodec-dev libavformat-dev libswscale-dev libv4l-dev \ | ||
libxvidcore-dev libx264-dev libjpeg-dev libpng-dev libtiff-dev \ | ||
gfortran openexr libatlas-base-dev python3-dev python3-numpy \ | ||
libtbb2 libtbb-dev libdc1394-22-dev libopenexr-dev \ | ||
libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev | ||
|
||
apt-get install opencl-headers | ||
|
||
cd /home/opencv/opencv-4.2.0 | ||
mkdir -p build && cd build | ||
|
||
cmake -D CMAKE_BUILD_TYPE=RELEASE \ | ||
-D CMAKE_INSTALL_PREFIX=/usr/local \ | ||
-D INSTALL_C_EXAMPLES=ON \ | ||
-D INSTALL_PYTHON_EXAMPLES=ON \ | ||
-D OPENCV_GENERATE_PKGCONFIG=ON \ | ||
-D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib-4.2.0/modules \ | ||
-D BUILD_EXAMPLES=ON .. | ||
|
||
|
||
make -j4 | ||
sudo make install | ||
|
||
|
||
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/opencv/opencv-4.2.0/build/lib |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,6 +44,7 @@ include_directories( | |
include | ||
${rclcpp_INCLUDE_DIRS} | ||
${LUAJIT_INCLUDE_DIR} | ||
${ff_common_INCLUDE_DIR} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think this is needed anymore after fixing ff_common |
||
) | ||
|
||
# Declare C++ libraries | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,6 +39,7 @@ include_directories( | |
include | ||
${rclcpp_INCLUDE_DIRS} | ||
${EIGEN3_INCLUDE_DIR} | ||
${ff_common_INCLUDE_DIRS} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why do you need this inside ff_common? |
||
) | ||
|
||
# Declare C++ libraries | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@joris997 if you want to set this env variable, you should use the tag ENV, as in
ENV LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:/home/opencv/opencv-4.2.0/build/lib"