Add earthcam publication service

This commit is contained in:
Jan Stabenow 2024-10-14 15:02:23 +02:00
parent 4c2a772457
commit 65426e0229
4 changed files with 116 additions and 1 deletions

View File

@ -1,8 +1,14 @@
# Restreamer-UI
## v1.14.0 > v1.15.0
- Add EarthCam publication service
- Add other RTSP transport modes
- Fix wetter.com category
## v1.13.0 > v1.14.0
- Add wettercom service
- Add wetter.com service
- Add option to select which channels will be displayed on the playersite ([#392](https://github.com/datarhei/restreamer/issues/392), [#800](https://github.com/datarhei/restreamer/issues/800))
- Mod updates public videojs >v8
- Fix erroneous filter setting

View File

@ -0,0 +1,102 @@
import React from 'react';
import { Trans } from '@lingui/macro';
import Grid from '@mui/material/Grid';
import Link from '@mui/material/Link';
import TextField from '@mui/material/TextField';
import Logo from './logos/earthcam.svg';
import FormInlineButton from '../../../misc/FormInlineButton';
const id = 'earthcam';
const name = 'EarthCam';
const version = '1.0';
const stream_key_link = 'https://www.earthcam.com/myearthcam/settings.php';
const description = (
<Trans>
Transmit your Livestream to an EarthCam RTMP service.{' '}
<Link color="secondary" target="_blank" href="https://www.earthcam.com/myearthcam/help/gettingstarted.php">
Here{' '}
</Link>
you can find more details about the settings.
</Trans>
);
const image_copyright = <Trans>Please get in touch with the operator of the service and check what happens.</Trans>;
const author = {
creator: {
name: 'datarhei',
link: 'https://github.com/datarhei',
},
maintainer: {
name: 'datarhei',
link: 'https://github.com/datarhei',
},
};
const category = 'platform';
const requires = {
protocols: ['rtmp'],
formats: ['flv'],
codecs: {
audio: ['aac'],
video: ['h264'],
},
};
function ServiceIcon(props) {
return <img src={Logo} alt="EarthCam.com Logo" {...props} />;
}
function init(settings) {
const initSettings = {
server_url: 'rtmp://video1.earthcam.com/myearthcam',
stream_key: '',
...settings,
};
return initSettings;
}
function Service({ settings = {}, skills = {}, metadata = {}, streams = [], onChange = function (output, settings) {} }) {
settings = init(settings);
const handleChange = (what) => (event) => {
const value = event.target.value;
settings[what] = value;
const output = createOutput(settings);
onChange([output], settings);
};
const createOutput = (settings) => {
const output = {
address: settings.server_url + '/' + settings.stream_key,
//options: ['-rtmp_playpath', settings.stream_key, '-f', 'flv'],
};
return output;
};
return (
<Grid container spacing={2}>
<Grid item xs={12} md={9}>
<TextField
variant="outlined"
fullWidth
placeholder="abc123"
label={<Trans>Stream key</Trans>}
value={settings.stream_key}
onChange={handleChange('stream_key')}
/>
</Grid>
<Grid item xs={12} md={3}>
<FormInlineButton target="blank" href={stream_key_link} component="a">
<Trans>GET</Trans>
</FormInlineButton>
</Grid>
</Grid>
);
}
export { id, name, version, stream_key_link, description, image_copyright, author, category, requires, ServiceIcon as icon, Service as component };

View File

@ -7,6 +7,7 @@ import * as DaCast from './DaCast';
import * as Dailymotion from './Dailymotion';
import * as DASH from './DASH';
import * as DLive from './DLive';
import * as EarthCam from './EarthCam';
import * as Facebook from './Facebook';
import * as Framebuffer from './Framebuffer';
import * as HLS from './HLS';
@ -95,6 +96,7 @@ registry.Register(PeerTube);
registry.Register(MediaNetwork);
registry.Register(Livespotting);
registry.Register(Wettercom);
registry.Register(EarthCam);
registry.Register(Azure);
registry.Register(Brightcove);
registry.Register(Akamai);

View File

@ -0,0 +1,5 @@
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" baseProfile="tiny" overflow="visible" version="1.2" viewBox="0 0 140 128.5">
<path fill="#FFF" d="m122.5 110.8-11-8.5C53.3 115.3 26 98 22.4 84.1L10 89.4c-2.4-6.9-1.4-18.7 10-33l1.7-6.8C11.1 59.9-.9 75.6.1 93.2c1.7 30.9 66.2 29.2 66.2 29.2 27 0 56.2-11.6 56.2-11.6z"/>
<path fill="#FFF" d="M96.7 122.8c-5.4 1.1-11.2 2-17.1 2.4 0 0-2.1.2-5.6.3 24.4 6.2 50.7-1.9 66.3-22.4-12.7 13.2-30 18-43.6 19.7zm-17-19c-21.5-6.5-39.2-22.6-44.9-43.5C26.3 29.1 44.4 6.5 79.3.4c1-.2 1.9-.3 2.9-.4-18.4 1.1-35.8 10-47.1 25.8-11.4 15.9-14.1 35.6-9 53.4 1 3.5 2.3 6.9 3.8 10.2.5 1 1 2.1 1.6 3.1 9.3 7.1 24.9 12.1 48.2 11.3z"/>
<path fill="#FFF" d="M100.2 12.4c-12.7-.4-26.5 2.4-41.3 8.4-.8.3-1.6.7-2.5 1l-3.1 1.3 1.9 4.3c-6.7 3-12.8 6.3-18.3 9.9-.1 1-.2 2-.2 3.1.3-.2.5-.4.6-.5 4.7-3.2 9.6-5.7 15.5-8.3l2.6-1.1c.3-.1.6-.3.9-.4 12.7-5.3 24.5-7.8 35.4-7.4 11.2.3 18.3 3.5 21.2 9.5l7.6-3.3.5 1.2c2.4 6.3-.1 13.6-7.5 22.1C106 60.7 95.4 68 81.9 74c-1.8.8-3.6 1.5-5.4 2.2-3.1 1.2-6.2 2.2-9.2 3.1-.5 1.8-.1 3.2 1.7 3.6 5.1-2.2 8.7-4 8.7-4l3.1-1.3c15.6-7 27.8-15.6 36.6-25.7 9.2-10.5 12-19.6 8.7-27.3-3.4-7.8-12-11.8-25.9-12.2z"/>
</svg>

After

Width:  |  Height:  |  Size: 1.1 KiB