www/webcam-ng.php

Thu, 25 Apr 2024 15:10:37 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Thu, 25 Apr 2024 15:10:37 +0200
changeset 710
abe60578d695
permissions
-rw-r--r--

Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).

710
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
1 <?php
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
2 /*****************************************************************************
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
3 * Copyright (C) 2022
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
4 *
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
5 * Michiel Broek <mbroek at mbse dot eu>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
6 *
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
7 * This file is part of ThermFerm
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
8 *
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
9 * This is free software; you can redistribute it and/or modify it
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
10 * under the terms of the GNU General Public License as published by the
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
11 * Free Software Foundation; either version 2, or (at your option) any
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
12 * later version.
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
13 *
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
14 * ThermFerm is distributed in the hope that it will be useful, but
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
15 * WITHOUT ANY WARRANTY; without even the implied warranty of
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
17 * General Public License for more details.
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
18 *
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
19 * You should have received a copy of the GNU General Public License
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
20 * along with ThermFerm; see the file COPYING. If not, write to the Free
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
21 * Software Foundation, 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
22 *****************************************************************************/
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
23
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
24 /*
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
25 * Look for the style names in the jqwidgets/styles directory.
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
26 */
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
27 $my_style = 'ui-darkness';
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
28 if (file_exists('/srv/http/streamer')) {
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
29 shell_exec('/srv/http/streamer start');
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
30 } else if (file_exists('/var/www/streamer')) {
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
31 shell_exec('/var/www/streamer start');
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
32 } else {
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
33 // exit;
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
34 }
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
35 sleep(1);
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
36 ?>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
37
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
38 <!DOCTYPE html>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
39 <html>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
40 <head>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
41 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
42 <title>ThermFerm - Web Camera</title>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
43 <link type="text/css" href="css/webcam-ng.css" rel="stylesheet" media="all" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
44 <link type="text/css" href="jqwidgets/styles/jqx.base.css" rel="stylesheet" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
45 <link type="text/css" href="jqwidgets/styles/jqx.<?php echo $my_style; ?>.css" rel="stylesheet" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
46 <meta name="viewport" content="width=device-width, initial-scale=1 maximum-scale=1 minimum-scale=1" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
47 <script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
48 var theme = "<?php echo $my_style; ?>";
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
49 </script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
50 <script src="js/jquery-2.1.1.min.js"></script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
51 <script src="jqwidgets/jqxcore.js"></script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
52 <script src="jqwidgets/jqxwindow.js"></script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
53 <script src="jqwidgets/jqxbuttons.js"></script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
54 <script src="js/webcam-ng.js"></script>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
55 </head>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
56 <body class="default">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
57 <div id="jqxWidget">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
58 <div id="content">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
59
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
60 <div id="camera_display">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
61 <div id="streamwrap" class="xform-p">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
62 <img id="streamimage" class="xform" src="<?php echo "http://".$_SERVER['SERVER_NAME'].":8090/?action=stream"; ?>" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
63 </div>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
64 </div>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
65
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
66 <div id="camera_controls">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
67 <table style="width: 100%; padding: 7px;">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
68 <tr>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
69 <td>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
70 <input style="float: left; margin-left: 0px;" type="button" id="rotate" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
71 <input style="float: left; margin-left: 5px;" type="button" id="mirror" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
72 <input style="float: left; margin-left: 5px;" type="button" id="flip" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
73 </td>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
74 </tr>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
75 <tr>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
76 <td>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
77 <div id="camera_panel_buttons">
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
78 <input style="margin-top: 250px; margin-left: 18px;" type="button" id="Close" value="Sluiten" />
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
79 </div>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
80 </td>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
81 </tr>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
82 </table>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
83 </div>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
84 </div>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
85 </div> <!-- jqxWidget -->
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
86 </body>
abe60578d695 Moved webcam scripts over to this www directory. Upgraded jquery to 2.1.1 (still old).
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
87 </html>

mercurial