06 2024 档案
摘要:Mat img = Imgcodecs.imread("图片绝对路径");Mat imgCopy = new Mat(img.size(), CvType.CV_8UC1);HighGui.imshow("Ori",img);double alpha = 1.5; // 大于0增加亮度,小于1大于0
阅读全文
摘要:Mat sharpened = new Mat();MatOfDouble kernel = new MatOfDouble(-1,-1,-1,-1,9,-1,-1,-1,-1);Imgproc.filter2D(原始图片的 Mat对象,sharpened,-1,kernel);
阅读全文
摘要://region 异步线程查询测试@Testvoid testThread() { CountThread countThread = new CountThread(); Thread thread = new Thread(countThread); thread.setName("线程1");
阅读全文
摘要:直接上代码块了,导入opencv的步骤就不再赘述了,很多java opencv教程都只写了怎么导入,其他啥都没写,随便搜都是一大把//连接导入并使用opencv包System.setProperty("java.awt.headless", "false");System.out.println(S
阅读全文
摘要:public void connectSQL(){ try { // 加载驱动 Class.forName("com.mysql.cj.jdbc.Driver"); // 连接三板斧 String url = "jdbc:mysql://localhost:3306/test_data"; Stri
阅读全文
摘要:System.out.println(Date.from( (LocalDate.of(2024,6,7) .atStartOfDay() .toInstant(ZoneOffset.ofHours(8))) ). after(Date.from( (LocalDate.now() .atTime(
阅读全文
摘要:public void 方法名() { RestTemplate restTemplate = new RestTemplate(); String url = "http://目标地址"; MultiValueMap<String, String> params = new LinkedMulti
阅读全文