pull/4/head
gehongbo 3 years ago
parent 997fd8c5d0
commit 947f7d5d0c

@ -78,29 +78,29 @@ void* Tello::udp_response_receiver(void* arg){
void Tello::get_video(sockaddr_in serveraddr){ void Tello::get_video(sockaddr_in serveraddr){
char tmp[10] = {"streamon"}; char tmp[10] = {"streamon"};
send_message(tmp,serveraddr,0);// 0 -> timeout send_message(tmp,serveraddr,0);
// cout << "stream_on successfully!" <<endl; cout << "stream_on successfully!" <<endl;
// this->stream_on = true; this->stream_on = true;
//
// cout << "vid"; cout << "vid";
// VideoCapture cap("udp://@0.0.0.0:11111"); VideoCapture cap("udp://@0.0.0.0:11111");
// cout << "cap"; cout << "cap";
// if(!cap.isOpened()){ if(!cap.isOpened()){
// cout << "fuck off"; cout << "fuck off";
// return; return;
// } }
// Mat frame; Mat frame;
// cout << "continue!"; cout << "continue!";
// while(1){ while(1){
// cap>>frame; cap>>frame;
// if(frame.empty()) if(frame.empty())
// break; break;
// imshow("video",frame); imshow("video",frame);
// waitKey(20); waitKey(20);
//
// } }
// cap.release(); cap.release();
} }

Binary file not shown.

Binary file not shown.

@ -13,7 +13,7 @@ int main(void){
return -1; return -1;
} }
cout << 1 << socket_fd; //cout << 1 << socket_fd;
T.set_conf(socket_fd); T.set_conf(socket_fd);
pthread_t thread_receive; pthread_t thread_receive;

Binary file not shown.

@ -0,0 +1,21 @@
obj = Djitellowhite.o keyboard.cpp Triplet.cpp
CXXFLAGS += -c -Wall $(shell pkg-config --cflags opencv4)
LDFLAGS += $(shell pkg-config --libs --static opencv4)
test : $(obj)
$(CXX) -o test $(obj) $(LDFLAGS)
Djitellowhite.o : Djitellowhite.h
$(CXX) -c Djitellowhite.cpp $(CXXFLAGS)
keyboard.o : Hardwarelistener.h
$(CXX) -c keyboard.cpp $(CXXFLAGS)
Triplet : Djitellowhite.h Hardwarelistener.h
$(CXX) -c Triplet.cpp -lpthread $(CXXFLAGS)
.PHONY : clean
clean :
rm test $(obj)

Binary file not shown.

Binary file not shown.
Loading…
Cancel
Save