-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathnxt_frameprocessing.cpp
More file actions
43 lines (33 loc) · 1.41 KB
/
nxt_frameprocessing.cpp
File metadata and controls
43 lines (33 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//#####################################################################################//
//#####################################################################################//
//#####################################################################################//
//# Please include the Github Repositories web URL if you are using this material. #//
//#####################################################################################//
//#####################################################################################//
//#####################################################################################//
#include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <vector>
#include "opencv2/opencv.hpp"
#include "opencv2/cudaarithm.hpp"
#include "opencv2/cudafilters.hpp"
#include "opencv2/cudaimgproc.hpp"
#include "opencv2/cudawarping.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "all_header.h"
using namespace std;
using namespace cv;
void LANEDETECTION::nxt_frame(cuda::GpuMat& src, vector<float>&polyright_n, vector<float>&polyleft_n)
{
vector<float>leftx;
vector<float>lefty;
vector<float>rightx;
vector<float>righty;
getIndicesOfNonZeroPixelsnext(src, leftx, lefty, rightx, righty);
LANEDETECTION Polyfit;
polyright_n = Polyfit.polyfiteigen(righty, rightx, 2);
polyleft_n = Polyfit.polyfiteigen(lefty, leftx, 2);
}