mirror of
https://github.com/opencv/opencv.git
synced 2025-06-12 20:42:53 +08:00
Remove useless C headers
This commit is contained in:
parent
6931a4cc06
commit
bfb54aa691
@ -1,5 +1,4 @@
|
|||||||
#include "opencv2/core.hpp"
|
#include "opencv2/core.hpp"
|
||||||
#include "opencv2/core/core_c.h"
|
|
||||||
#include "opencv2/imgproc.hpp"
|
#include "opencv2/imgproc.hpp"
|
||||||
#include "opencv2/imgcodecs.hpp"
|
#include "opencv2/imgcodecs.hpp"
|
||||||
|
|
||||||
|
@ -49,7 +49,6 @@
|
|||||||
#define OPENCV_CALIB3D_UPNP_H_
|
#define OPENCV_CALIB3D_UPNP_H_
|
||||||
|
|
||||||
#include "precomp.hpp"
|
#include "precomp.hpp"
|
||||||
#include "opencv2/core/core_c.h"
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
#if 0 // fix buffer overflow first (FIXIT mark in .cpp file)
|
#if 0 // fix buffer overflow first (FIXIT mark in .cpp file)
|
||||||
|
@ -40,7 +40,6 @@
|
|||||||
//M*/
|
//M*/
|
||||||
|
|
||||||
#include "test_precomp.hpp"
|
#include "test_precomp.hpp"
|
||||||
#include "opencv2/calib3d/calib3d_c.h"
|
|
||||||
|
|
||||||
namespace opencv_test { namespace {
|
namespace opencv_test { namespace {
|
||||||
|
|
||||||
@ -754,7 +753,7 @@ void CV_CameraCalibrationTest_CPP::calibrate(Size imageSize,
|
|||||||
Mat(_objectPoints[i]).convertTo(objectPoints[i], CV_32F);
|
Mat(_objectPoints[i]).convertTo(objectPoints[i], CV_32F);
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t nstddev0 = CV_CALIB_NINTRINSIC + imageCount*6, nstddev1 = nstddev0 + _imagePoints[0].size()*3;
|
size_t nstddev0 = CALIB_NINTRINSIC + imageCount*6, nstddev1 = nstddev0 + _imagePoints[0].size()*3;
|
||||||
for( i = nstddev0; i < nstddev1; i++ )
|
for( i = nstddev0; i < nstddev1; i++ )
|
||||||
{
|
{
|
||||||
stdDevs[i] = 0.0;
|
stdDevs[i] = 0.0;
|
||||||
@ -1433,12 +1432,12 @@ void CV_StereoCalibrationTest::run( int )
|
|||||||
double rmsErrorFromStereoCalib = calibrateStereoCamera(objpt, imgpt1, imgpt2, M1, D1, M2, D2, imgsize, R, T, E, F,
|
double rmsErrorFromStereoCalib = calibrateStereoCamera(objpt, imgpt1, imgpt2, M1, D1, M2, D2, imgsize, R, T, E, F,
|
||||||
rotMats1, transVecs1, rmsErrorPerView1, rmsErrorPerView2,
|
rotMats1, transVecs1, rmsErrorPerView1, rmsErrorPerView2,
|
||||||
TermCriteria(TermCriteria::MAX_ITER+TermCriteria::EPS, 30, 1e-6),
|
TermCriteria(TermCriteria::MAX_ITER+TermCriteria::EPS, 30, 1e-6),
|
||||||
CV_CALIB_SAME_FOCAL_LENGTH
|
CALIB_SAME_FOCAL_LENGTH
|
||||||
//+ CV_CALIB_FIX_ASPECT_RATIO
|
//+ CALIB_FIX_ASPECT_RATIO
|
||||||
+ CV_CALIB_FIX_PRINCIPAL_POINT
|
+ CALIB_FIX_PRINCIPAL_POINT
|
||||||
+ CV_CALIB_ZERO_TANGENT_DIST
|
+ CALIB_ZERO_TANGENT_DIST
|
||||||
+ CV_CALIB_FIX_K3
|
+ CALIB_FIX_K3
|
||||||
+ CV_CALIB_FIX_K4 + CV_CALIB_FIX_K5 //+ CV_CALIB_FIX_K6
|
+ CALIB_FIX_K4 + CALIB_FIX_K5 //+ CALIB_FIX_K6
|
||||||
);
|
);
|
||||||
/* rmsErrorFromStereoCalib /= nframes*npoints; */
|
/* rmsErrorFromStereoCalib /= nframes*npoints; */
|
||||||
if (rmsErrorFromStereoCalib > maxReprojErr)
|
if (rmsErrorFromStereoCalib > maxReprojErr)
|
||||||
|
@ -41,7 +41,6 @@
|
|||||||
|
|
||||||
#include "test_precomp.hpp"
|
#include "test_precomp.hpp"
|
||||||
#include "test_chessboardgenerator.hpp"
|
#include "test_chessboardgenerator.hpp"
|
||||||
#include "opencv2/core/types_c.h"
|
|
||||||
|
|
||||||
namespace opencv_test { namespace {
|
namespace opencv_test { namespace {
|
||||||
|
|
||||||
@ -232,8 +231,6 @@ protected:
|
|||||||
|
|
||||||
void run(int /* start_from */ )
|
void run(int /* start_from */ )
|
||||||
{
|
{
|
||||||
Mat zeros(1, sizeof(CvMat), CV_8U, Scalar(0));
|
|
||||||
|
|
||||||
Mat src_cpp(3, 1, CV_32F);
|
Mat src_cpp(3, 1, CV_32F);
|
||||||
Mat dst_cpp(3, 3, CV_32F);
|
Mat dst_cpp(3, 3, CV_32F);
|
||||||
|
|
||||||
|
@ -41,7 +41,6 @@
|
|||||||
|
|
||||||
#include "test_precomp.hpp"
|
#include "test_precomp.hpp"
|
||||||
#include "test_chessboardgenerator.hpp"
|
#include "test_chessboardgenerator.hpp"
|
||||||
#include "opencv2/calib3d/calib3d_c.h"
|
|
||||||
|
|
||||||
namespace opencv_test { namespace {
|
namespace opencv_test { namespace {
|
||||||
|
|
||||||
@ -89,7 +88,7 @@ void CV_ChessboardDetectorBadArgTest::run( int /*start_from */)
|
|||||||
|
|
||||||
/* /*//*/ */
|
/* /*//*/ */
|
||||||
int errors = 0;
|
int errors = 0;
|
||||||
flags = CV_CALIB_CB_ADAPTIVE_THRESH | CV_CALIB_CB_NORMALIZE_IMAGE;
|
flags = CALIB_CB_ADAPTIVE_THRESH | CALIB_CB_NORMALIZE_IMAGE;
|
||||||
|
|
||||||
img = cb.clone();
|
img = cb.clone();
|
||||||
initArgs();
|
initArgs();
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
#include "perf_precomp.hpp"
|
#include "perf_precomp.hpp"
|
||||||
#include "opencv2/core/core_c.h"
|
|
||||||
|
|
||||||
namespace opencv_test
|
namespace opencv_test
|
||||||
{
|
{
|
||||||
|
@ -4,7 +4,6 @@
|
|||||||
|
|
||||||
#include "precomp.hpp"
|
#include "precomp.hpp"
|
||||||
#include "opencv2/core/mat.hpp"
|
#include "opencv2/core/mat.hpp"
|
||||||
#include "opencv2/core/types_c.h"
|
|
||||||
#include "opencl_kernels_core.hpp"
|
#include "opencl_kernels_core.hpp"
|
||||||
|
|
||||||
#undef HAVE_IPP
|
#undef HAVE_IPP
|
||||||
|
@ -4,7 +4,6 @@
|
|||||||
|
|
||||||
#include "precomp.hpp"
|
#include "precomp.hpp"
|
||||||
#include "opencv2/core/mat.hpp"
|
#include "opencv2/core/mat.hpp"
|
||||||
#include "opencv2/core/types_c.h"
|
|
||||||
|
|
||||||
namespace cv {
|
namespace cv {
|
||||||
|
|
||||||
|
@ -6,7 +6,6 @@
|
|||||||
#ifndef SRC_PERSISTENCE_HPP
|
#ifndef SRC_PERSISTENCE_HPP
|
||||||
#define SRC_PERSISTENCE_HPP
|
#define SRC_PERSISTENCE_HPP
|
||||||
|
|
||||||
#include "opencv2/core/types_c.h"
|
|
||||||
#include <deque>
|
#include <deque>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
@ -44,7 +44,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "precomp.hpp"
|
#include "precomp.hpp"
|
||||||
#include "opencv2/imgproc/imgproc_c.h"
|
|
||||||
#include <limits>
|
#include <limits>
|
||||||
#include "../3rdparty/mscr/chi_table.h"
|
#include "../3rdparty/mscr/chi_table.h"
|
||||||
|
|
||||||
|
@ -40,7 +40,6 @@
|
|||||||
//M*/
|
//M*/
|
||||||
|
|
||||||
#include "test_precomp.hpp"
|
#include "test_precomp.hpp"
|
||||||
#include "opencv2/core/core_c.h"
|
|
||||||
|
|
||||||
namespace opencv_test { namespace {
|
namespace opencv_test { namespace {
|
||||||
|
|
||||||
|
@ -6,7 +6,6 @@
|
|||||||
|
|
||||||
#include "opencv2/ts.hpp"
|
#include "opencv2/ts.hpp"
|
||||||
#include "opencv2/imgcodecs.hpp"
|
#include "opencv2/imgcodecs.hpp"
|
||||||
#include "opencv2/imgproc/imgproc_c.h"
|
|
||||||
|
|
||||||
namespace cv {
|
namespace cv {
|
||||||
|
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
// It is subject to the license terms in the LICENSE file found in the top-level directory
|
// It is subject to the license terms in the LICENSE file found in the top-level directory
|
||||||
// of this distribution and at http://opencv.org/license.html.
|
// of this distribution and at http://opencv.org/license.html.
|
||||||
#include "perf_precomp.hpp"
|
#include "perf_precomp.hpp"
|
||||||
#include "opencv2/imgproc/types_c.h"
|
|
||||||
|
|
||||||
namespace opencv_test {
|
namespace opencv_test {
|
||||||
|
|
||||||
|
@ -573,8 +573,8 @@ public:
|
|||||||
Mat bufferMat(image.rows, image.cols, CV_8UC4, buffer.bits, buffer.stride * 4);
|
Mat bufferMat(image.rows, image.cols, CV_8UC4, buffer.bits, buffer.stride * 4);
|
||||||
switch (image.type()) {
|
switch (image.type()) {
|
||||||
case CV_8UC4: image.copyTo(bufferMat); break;
|
case CV_8UC4: image.copyTo(bufferMat); break;
|
||||||
case CV_8UC3: cvtColor(image, bufferMat, CV_BGR2RGBA); break;
|
case CV_8UC3: cvtColor(image, bufferMat, COLOR_BGR2RGBA); break;
|
||||||
case CV_8UC1: cvtColor(image, bufferMat, CV_GRAY2RGBA); break;
|
case CV_8UC1: cvtColor(image, bufferMat, COLOR_GRAY2RGBA); break;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
LOGE("Unknown surface buffer format: 0x%x", buffer.format);
|
LOGE("Unknown surface buffer format: 0x%x", buffer.format);
|
||||||
@ -585,8 +585,8 @@ public:
|
|||||||
//OpenCV doesn't support RGB to NV12 so we need to convert to YV12 and then manually changed it to NV12
|
//OpenCV doesn't support RGB to NV12 so we need to convert to YV12 and then manually changed it to NV12
|
||||||
Mat imageYV12;
|
Mat imageYV12;
|
||||||
switch (image.type()) {
|
switch (image.type()) {
|
||||||
case CV_8UC4: cvtColor(image, imageYV12, CV_RGBA2YUV_YV12); break;
|
case CV_8UC4: cvtColor(image, imageYV12, COLOR_RGBA2YUV_YV12); break;
|
||||||
case CV_8UC3: cvtColor(image, imageYV12, CV_BGR2YUV_YV12); break;
|
case CV_8UC3: cvtColor(image, imageYV12, COLOR_BGR2YUV_YV12); break;
|
||||||
case CV_8UC1: imageYV12.create(image.rows + image.rows/2, image.cols, CV_8UC1);
|
case CV_8UC1: imageYV12.create(image.rows + image.rows/2, image.cols, CV_8UC1);
|
||||||
image.copyTo(imageYV12.rowRange(0, image.rows));
|
image.copyTo(imageYV12.rowRange(0, image.rows));
|
||||||
imageYV12.rowRange(image.rows, imageYV12.rows) = 128;
|
imageYV12.rowRange(image.rows, imageYV12.rows) = 128;
|
||||||
|
@ -73,7 +73,6 @@
|
|||||||
#include "opencv2/imgcodecs.hpp"
|
#include "opencv2/imgcodecs.hpp"
|
||||||
|
|
||||||
#include "opencv2/imgproc.hpp"
|
#include "opencv2/imgproc.hpp"
|
||||||
#include "opencv2/imgproc/imgproc_c.h"
|
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
Loading…
Reference in New Issue
Block a user