OpenCV

From ImageWiki

(Difference between revisions)
Jump to: navigation, search
(Hvordan benyttes OpenCV?)
Line 16: Line 16:
  pkg-config --libs opencv
  pkg-config --libs opencv
-
Der henvises til billedgruppens SVN server for et simpelt eksempel til OpenCV. XXX: .
+
Her gives et mindre eksempeltil dit eget projekt.
 +
 
 +
# Compile and link flags
 +
CXX      =  g++
 +
CXXFLAGS = `pkg-config ersp --cflags` -Wall
 +
LIBS    = `pkg-config ersp --libs`
 +
 
 +
# Main executable
 +
EXECUTABLE = myprogram
 +
 
 +
# Files
 +
SOURCES = myprogram.cc myauxilaryfunction.cc
 +
OBJECTS = $(patsubst %.cc, %.o, $(SOURCES))
 +
 
 +
## Compile everything ##
 +
all: $(OBJECTS)
 +
$(CXX) $(LIBS) $(OBJECTS) -o $(EXECUTABLE)
 +
 
 +
# Compilation.
 +
%.o : %.cc
 +
$(CXX) $(CXXFLAGS) -c $^
== Eksempel 1 ==
== Eksempel 1 ==

Revision as of 11:49, 9 July 2006

Personal tools