📄 rtpfile.java
字号:
/*
* 程序员杨龙:本视频会议服务器端代码:根据自己定义的协议:能构穿透nat 需要java jmf框架
* 我开放源代码是为了更好的让java这门程序艺术更好的发展:您可以研究代码,您可以自己使用
* 但是不要使用在商业用途上 让我们更好的把开源事业在中国做下去
* 2008年 3月 杨龙 完成服务器端的框架
* 信箱 :y_flash@163.com
* QQ:274797328
* www.0351soft.com www.lx08.com
*/
package ytp.javaserver.server.dia;
import java.io.File;
import java.net.InetAddress;
import java.net.MalformedURLException;
import java.net.UnknownHostException;
import javax.media.MediaLocator;
import javax.swing.JFileChooser;
import javax.swing.JOptionPane;
import ytp.javaserver.server.RTPsend;
/**
*
* @author Administrator
*/
public class RTPfile extends javax.swing.JFrame {
RTPsend send = null;
/** Creates new form RTPfile */
public RTPfile() {
initComponents();
}
/** This method is called from within the constructor to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
// <editor-fold defaultstate="collapsed" desc=" 生成的代码 ">//GEN-BEGIN:initComponents
private void initComponents() {
jLabel1 = new javax.swing.JLabel();
jPanel1 = new javax.swing.JPanel();
jLabel2 = new javax.swing.JLabel();
jTfilename = new javax.swing.JTextField();
jLabel3 = new javax.swing.JLabel();
jTip1 = new javax.swing.JTextField();
jTip2 = new javax.swing.JTextField();
jTip3 = new javax.swing.JTextField();
jTip4 = new javax.swing.JTextField();
jLabel4 = new javax.swing.JLabel();
jTport = new javax.swing.JTextField();
jCau = new javax.swing.JCheckBox();
jCvu = new javax.swing.JCheckBox();
jCtime = new javax.swing.JComboBox();
jLabel5 = new javax.swing.JLabel();
jLabel6 = new javax.swing.JLabel();
jButton3 = new javax.swing.JButton();
jButton4 = new javax.swing.JButton();
jLabel7 = new javax.swing.JLabel();
jTport1 = new javax.swing.JTextField();
jButton5 = new javax.swing.JButton();
jPanel2 = new javax.swing.JPanel();
jLshow = new javax.swing.JLabel();
jP = new javax.swing.JProgressBar();
jLabel8 = new javax.swing.JLabel();
jScrollPane1 = new javax.swing.JScrollPane();
jTinfo = new javax.swing.JTextArea();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle("\u53d1\u9001\u5a92\u4f53\u6587\u4ef6");
setResizable(false);
addWindowListener(new java.awt.event.WindowAdapter() {
public void windowOpened(java.awt.event.WindowEvent evt) {
formWindowOpened(evt);
}
});
jLabel1.setBackground(new java.awt.Color(255, 255, 255));
jLabel1.setText("\u6587\u4ef6\u7c7b\u578b\u8bf7\u9009\u62e9MPEG\u6587\u4ef6,\u672c\u7cfb\u7edf\u7f16\u7801\u4e3a\u4e86\u91c7\u7528MPEG");
jLabel1.setAlignmentX(10.0F);
jPanel1.setBackground(new java.awt.Color(204, 204, 204));
jLabel2.setText("\u8981\u53d1\u9001\u7684\u6587\u4ef6");
jTfilename.setText("jTextField1");
jLabel3.setText("\u8fdc\u7a0b\u5730\u5740:");
jTip1.setText("jTextField2");
jTip2.setText("jTextField3");
jTip3.setText("jTextField4");
jTip4.setText("jTextField5");
jLabel4.setText("\u7aef\u53e3");
jTport.setText("jTextField6");
jCau.setText("\u97f3\u9891\u6587\u4ef6");
jCau.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
jCau.setMargin(new java.awt.Insets(0, 0, 0, 0));
jCvu.setText("\u89c6\u9891\u6587\u4ef6");
jCvu.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
jCvu.setMargin(new java.awt.Insets(0, 0, 0, 0));
jCtime.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
jLabel5.setText("\u5b9a\u65f6\u53d1\u9001:");
jLabel6.setText("\u53d1\u9001\u786e\u8ba4\u4e4b\u524d\u8bf7\u786e\u8ba4\u672c\u5730\u7aef\u53e3\u662f\u5426\u53ef\u7528");
jButton3.setText("\u786e\u8ba4\u53d1\u9001");
jButton3.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
jButton3MouseClicked(evt);
}
});
jButton4.setText("\u53d6\u6d88\u53d1\u9001");
jButton4.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
jButton4MouseClicked(evt);
}
});
jLabel7.setText("\u79d2\u540e\u53d1\u9001");
jTport1.setText("jTextField1");
jButton5.setText("\u9009\u62e9\u6587\u4ef6");
jButton5.addMouseListener(new java.awt.event.MouseAdapter() {
public void mouseClicked(java.awt.event.MouseEvent evt) {
jButton5MouseClicked(evt);
}
});
org.jdesktop.layout.GroupLayout jPanel1Layout = new org.jdesktop.layout.GroupLayout(jPanel1);
jPanel1.setLayout(jPanel1Layout);
jPanel1Layout.setHorizontalGroup(
jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jLabel2)
.add(jLabel3)
.add(jLabel5))
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jLabel6)
.add(jPanel1Layout.createSequentialGroup()
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false)
.add(jPanel1Layout.createSequentialGroup()
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false)
.add(org.jdesktop.layout.GroupLayout.LEADING, jCtime, 0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.add(org.jdesktop.layout.GroupLayout.LEADING, jPanel1Layout.createSequentialGroup()
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jPanel1Layout.createSequentialGroup()
.add(jTip1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 35, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jTip2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 33, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
.add(jCau))
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jTip3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 31, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
.add(jPanel1Layout.createSequentialGroup()
.add(jTip4, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 33, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(23, 23, 23)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
.add(jTport1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 43, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(jPanel1Layout.createSequentialGroup()
.add(jLabel4)
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jTport, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))))
.add(jCvu)))
.add(org.jdesktop.layout.GroupLayout.TRAILING, jTfilename))
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jPanel1Layout.createSequentialGroup()
.add(14, 14, 14)
.add(jButton5))
.add(jPanel1Layout.createSequentialGroup()
.add(39, 39, 39)
.add(jLabel7)))))
.add(268, 268, 268))
.add(jPanel1Layout.createSequentialGroup()
.add(60, 60, 60)
.add(jButton3)
.add(32, 32, 32)
.add(jButton4))
);
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
.add(jPanel1Layout.createSequentialGroup()
.add(jButton5)
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
.add(jTip1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(jTip2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(jTip3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(jTip4, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(jLabel3)
.add(jLabel4)
.add(jTport, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
.add(jLabel2)
.add(jTfilename, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
.add(23, 23, 23)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
.add(jCau)
.add(jCvu))
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
.add(jLabel5)
.add(jCtime, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
.add(jLabel7)
.add(jTport1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
.add(15, 15, 15)
.add(jLabel6)
.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
.add(jButton4)
.add(jButton3))
.addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
jPanel2.setBackground(new java.awt.Color(204, 204, 204));
jLshow.setText("\u6587\u4ef6\u4f20\u9001\u4fe1\u606f");
jLabel8.setText("\u64ad\u653e\u8fc7\u7a0b\u4e2d \u8bf7\u4e0d\u8981\u5173\u95ed\u7a97\u53e3");
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -