资源简介

把android手机变成摄像头通过pc端监控,ImageServer.java是电脑pc端 CameraTest是android 端代码 使用 socket

资源截图

代码片段和文件信息

/*
*   @version 1.2 2012-06-29
*   @author wanghai
*/

import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.io.*;

import javax.imageio.*;
import javax.swing.*;
import java.net.Socket;
import java.net.ServerSocket;

/**
*在服务器开启情况下,启动客户端,创建套接字接收图像
*/

public class ImageServer {
    public static ServerSocket ss = null;
    
    public static void main(String args[]) throws IOException{    
     ss = new ServerSocket(6000);
        
        final Imageframe frame = new Imageframe(ss);
        frame.setDefaultCloseOperation(Jframe.EXIT_ON_CLOSE);
        frame.setVisible(true);
       
        while(true){
         frame.panel.getimage();
            frame.repaint();
        }        
    }
       
}

/**

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-05-07 23:03  CameraTest\
     文件         459  2013-09-16 14:16  CameraTest\.classpath
     文件         846  2012-06-20 21:45  CameraTest\.project
     文件        1461  2012-07-03 18:49  CameraTest\AndroidManifest.xml
     目录           0  2019-05-07 23:03  CameraTest\bin\
     文件        1461  2013-09-16 14:16  CameraTest\bin\AndroidManifest.xml
     文件       42956  2013-09-16 14:17  CameraTest\bin\CameraTest.apk
     目录           0  2019-05-07 23:03  CameraTest\bin\classes\
     目录           0  2019-05-07 23:03  CameraTest\bin\classes\org\
     目录           0  2019-05-07 23:03  CameraTest\bin\classes\org\wanghai\
     目录           0  2019-05-07 23:03  CameraTest\bin\classes\org\wanghai\CameraTest\
     文件         353  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\BuildConfig.class
     文件        1404  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\CameraTest$1.class
     文件        3167  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\CameraTest.class
     文件        1676  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\GetIP$1.class
     文件         885  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\GetIP$2.class
     文件        2231  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\GetIP.class
     文件        1540  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\MyThread.class
     文件         352  2013-09-16 14:17  CameraTest\bin\classes\org\wanghai\CameraTest\R$attr.class
     文件         419  2013-09-16 14:17  CameraTest\bin\classes\org\wanghai\CameraTest\R$drawable.class
     文件         524  2013-09-16 14:17  CameraTest\bin\classes\org\wanghai\CameraTest\R$id.class
     文件         463  2013-09-16 14:17  CameraTest\bin\classes\org\wanghai\CameraTest\R$layout.class
     文件         439  2013-09-16 14:17  CameraTest\bin\classes\org\wanghai\CameraTest\R$string.class
     文件         559  2013-09-16 14:17  CameraTest\bin\classes\org\wanghai\CameraTest\R.class
     文件        2088  2013-09-16 14:16  CameraTest\bin\classes\org\wanghai\CameraTest\StreamIt.class
     文件       11416  2013-09-16 14:17  CameraTest\bin\classes.dex
     目录           0  2019-05-07 23:03  CameraTest\bin\dexedLibs\
     文件         943  2013-09-16 14:17  CameraTest\bin\dexedLibs\annotations-2626851360bb9fc5460fef54dbd031a5.jar
     文件         120  2013-09-16 14:16  CameraTest\bin\jarlist.cache
     目录           0  2019-05-07 23:03  CameraTest\bin\res\
     目录           0  2019-05-07 23:03  CameraTest\bin\res\drawable-hdpi\
............此处省略39个文件信息

评论

共有 条评论