代码 - 翼展电脑服务中心


虚拟摄像头配置文件ONVIF.INI

2025-12-10 乱云飞 代码 评论(0) 浏览(122) 标签: onvif 虚拟监控 配置文件

<?xml version="1.0" encoding="utf-8"?>
<!----------vx:13213610060 QQ:5082500---------->
<!----------VirtualCamera v20251210-a---------->
<config>
  <!---------- 基本服务设置 ---------->
  <server_ip>192.168.1.27</server_ip>
  <http_enable>1</http_enable>
  <http_port>8100</http_port>
  <https_enable>0</https_enable>
  <need_auth>0</need_auth>
  <log_enable>0</log_enable>
  <log_level>0</log_level>
  <!---------- 设备信息配置 ---------->
  <information>
    <Manufacturer>EZSOFT</Manufacturer>
    <Model>VirtualCamera</Model>
    <FirmwareVersion>VX13213610060</FirmwareVersion>
    <SerialNumber>QQ5082500</SerialNumber>
    <HardwareId>80c.cc</HardwareId>
  </information>
  <!---------- 用户配置 ---------->
  <user>
    <username>admin</username>
    <password>admin</password>
    <userlevel>Administrator</userlevel>
  </user>
  <!---------- 主码流配置 ---------->
  <profile token="MainStream"fixed="true">
    <Name>MainStream</Name>
    <stream_uri>rtsp://192.168.1.27:8554/screenlive</stream_uri>
    <VideoSourceConfiguration token="VideoSourceConfigurationToken_1">
    </VideoSourceConfiguration>
    <VideoEncoderConfiguration token="VideoEncoderConfigurationToken_1">
    </VideoEncoderConfiguration>
  </profile>
  <!---------- 子码流配置 ---------->
  <profile token="SubStream"fixed="true">
    <Name>SubStream</Name>
    <stream_uri>rtsp://192.168.1.27:8554/substream</stream_uri>
    <VideoSourceConfiguration token="VideoSourceConfigurationToken_1">
    </VideoSourceConfiguration>
    <VideoEncoderConfiguration token="VideoEncoderConfigurationToken_2">
    </VideoEncoderConfiguration>
  </profile>
  <!---------- 物理视频源定义 ---------->
  <VideoSources token="VideoSourceToken_1">
    <Framerate>25.0</Framerate>
    <Resolution>
      <Width>1920</Width>
      <Height>1080</Height>
    </Resolution>
    <VideoSourceModes token="Mode1"Enabled="true">
      <MaxFramerate>30</MaxFramerate>
      <MaxResolution>
        <Width>1920</Width>
        <Height>1080</Height>
      </MaxResolution>
      <Encodings>H264</Encodings>
    </VideoSourceModes>
  </VideoSources>
  <!---------- 视频源使用配置 ---------->
  <VideoSourceConfigurations token="VideoSourceConfigurationToken_1">
    <Name>VideoSourceConfiguration</Name>
    <UseCount>1</UseCount>
    <SourceToken>VideoSourceToken_1</SourceToken>
    <Bounds x="0"y="0"width="1920"height="1080" />
  </VideoSourceConfigurations>
  <!---------- 主码流编码配置 ---------->
  <VideoEncoderConfigurations token="VideoEncoderConfigurationToken_1"GovLength="25"Profile="Main">
    <Name>MainStream</Name>
    <UseCount>1</UseCount>
    <Encoding>H264</Encoding>
    <Resolution>
      <Width>1920</Width>
      <Height>1080</Height>
    </Resolution>
  </VideoEncoderConfigurations>
  <!---------- 子码流编码配置 ---------->
  <VideoEncoderConfigurations token="VideoEncoderConfigurationToken_2"GovLength="25"Profile="Main">
    <Name>SubStream</Name>
    <UseCount>1</UseCount>
    <Encoding>H264</Encoding>
    <Resolution>
      <Width>480</Width>
      <Height>360</Height>
    </Resolution>
  </VideoEncoderConfigurations>
  <!---------- OSD配置 ---------->
  <OSDConfigurations token="OSD1">
    <VideoSourceConfigurationToken>VideoSourceConfigurationToken_1</VideoSourceConfigurationToken>
    <Type>Text</Type>
    <Position>
      <Type>UpperLeft</Type>
    </Position>
    <TextString>
      <Type>Plain</Type>
      <PlainText>IPCamera01</PlainText>
    </TextString>
  </OSDConfigurations>
  <!---------- 设备发现范围 ---------->
  <scope>onvif://www.onvif.org/location/country/CHINA</scope>
  <scope>onvif://www.onvif.org/MAC/A1:32:13:61:00:60</scope>
  <scope>onvif://www.onvif.org/hardware/Hi3516CV610</scope>
  <scope>onvif://www.onvif.org/name/IPCamera</scope>
  <scope>onvif://www.onvif.org/profile/T</scope>
  <event>
    <renew_interval>60</renew_interval>
    <simulate_enable>1</simulate_enable>
  </event>
</config>

MPV播放USB摄像头

2025-8-9 乱云飞 代码 评论(0) 浏览(172) 标签: 摄像头 USB video MPV播放器 播放视频

mpv av://dshow:"video=USB Video" --profile=low-latency --untimed

av://dshow:"video=USB Video"
使用 dshow(DirectShow)作为输入源,指定视频设备名称为 USB Video(需替换为你的摄像头实际名称,可通过 --list-devices 查看)。
示例:如果设备名是 5MP USB Camera,则改为 "video=5MP USB Camera"。
--profile=low-latency
启用 mpv 内置的低延迟配置,减少缓存和缓冲时间,适合实时监控或视频通话等场景。
--untimed
禁用视频时钟同步,进一步降低延迟(画面可能不再按正常速度播放,但响应更快)。
虚拟监控软件录制USB摄像头取流地址:

rtsp://192.168.1.85:8554/videodevice
rtsp://192.168.1.85:8554/videodevice=usb video

av://dshow:"video=5MP USB Camera" --profile=low-latency --untimed

全局直角(保留圆形高性能版V2026)

2025-6-5 乱云飞 代码 评论(0) 浏览(13)

// ==UserScript==
// @name         全局直角(修复内部图片圆形)000
// @namespace    http://tampermonkey.net/
// @version      3.7
// @description  强制所有非圆形元素变为直角,保留圆形容器及其内部图片
// @author       You
// @match        http://*/*
// @match        https://*/*
// @grant        none
// @run-at       document-start
// ==/UserScript==

(function() {
    'use strict';

    // 圆形元素选择器白名单
    const CIRCULAR_SELECTORS = [
        // 头像类
        '[class*="avatar"]', '[class*="user-avatar"]', '[class*="profile-pic"]',
        '.avatar', '.user-avatar', '.MuiAvatar-root', '.ant-avatar',
        'img[class*="avatar"]', 'img[src*="avatar"]', 'img[src*="profile"]',
        
        // 圆形装饰/图标类
        '[class*="circle"]', '[class*="round"]', '.rounded-full', '.rounded-circle',
        
        // 音乐播放器的唱片/CD封面容器(重点)
        '.vg-disc-container', '.disc-container', '.cd-cover', '.album-cover',
        '[class*="disc"]', '[class*="cd"]', '[class*="cover-art"]',
        '.song-cover', '.music-cover', '.playlist-cover', '.vg-cover-container',
        
        // 特定播放器
        '.aplayer-pic', '.aplayer-cover', '.ncm-cover',
        '.sakana-widget',
    ];

    // 检查元素是否匹配圆形选择器白名单
    function matchesCircularSelector(el) {
        if (!el) return false;
        for (const selector of CIRCULAR_SELECTORS) {
            if (el.matches(selector)) return true;
        }
        // 模糊匹配类名中的关键词
        const className = (el.className || '').toLowerCase();
        if (className.includes('avatar') || className.includes('circle') || 
            className.includes('round') || className.includes('disc') ||
            className.includes('cover') || className.includes('album')) {
            const rect = el.getBoundingClientRect();
            if (rect.width > 0 && rect.height > 0) {
                const style = window.getComputedStyle(el);
                if (Math.abs(rect.width - rect.height) < 5 && 
                    (style.borderRadius === '50%' || style.borderRadius.includes('50%') ||
                     parseFloat(style.borderRadius) >= Math.min(rect.width, rect.height) / 2)) {
                    return true;
                }
            }
        }
        return false;
    }

    // 检查元素是否位于圆形容器内部(关键修复)
    function isInsideCircularContainer(el) {
        let parent = el.parentElement;
        let level = 0;
        // 向上查找最多5层,找到圆形容器
        while (parent && level < 5) {
            // 检查父元素是否匹配圆形选择器
            if (matchesCircularSelector(parent)) return true;
            // 检查父元素是否有圆形圆角样式
            const style = window.getComputedStyle(parent);
            const borderRadius = style.borderRadius;
            if (borderRadius !== '0px' && borderRadius !== '0%' && borderRadius !== '') {
                const rect = parent.getBoundingClientRect();
                if (rect.width > 0 && rect.height > 0 && Math.abs(rect.width - rect.height) < 5) {
                    // 父元素是正方形且圆角足够大,判定为圆形容器
                    let radiusPx = 0;
                    if (borderRadius.includes('%')) {
                        radiusPx = Math.min(rect.width, rect.height) * (parseFloat(borderRadius) / 100);
                    } else if (borderRadius.includes('px')) {
                        radiusPx = parseFloat(borderRadius);
                    }
                    if (radiusPx >= Math.min(rect.width, rect.height) / 2 - 1) {
                        return true;
                    }
                }
            }
            parent = parent.parentElement;
            level++;
        }
        return false;
    }

    // 判断元素是否为图片且应该保持圆形
    function isImageShouldKeepCircle(el) {
        if (el.tagName !== 'IMG') return false;
        // 如果图片在圆形容器内,应该保持圆形
        if (isInsideCircularContainer(el)) return true;
        // 如果图片本身匹配圆形选择器
        if (matchesCircularSelector(el)) return true;
        return false;
    }

    // 几何判断:是否为真圆形
    function isPerfectCircle(el) {
        const rect = el.getBoundingClientRect();
        const width = rect.width;
        const height = rect.height;
        if (width === 0 || height === 0) return false;
        if (Math.abs(width - height) > 2) return false;
        
        const style = window.getComputedStyle(el);
        const borderRadius = style.borderRadius;
        if (borderRadius === '0px' || borderRadius === '0%') return false;
        
        let radiusPx = 0;
        if (borderRadius.includes('%')) {
            radiusPx = Math.min(width, height) * (parseFloat(borderRadius) / 100);
        } else if (borderRadius.includes('px')) {
            radiusPx = parseFloat(borderRadius);
        } else {
            radiusPx = parseFloat(borderRadius);
        }
        
        return radiusPx >= Math.min(width, height) / 2 - 1;
    }

    // 判断是否应保留圆角(主函数)
    function shouldKeepRadius(el) {
        // 1. 白名单直接保留
        if (matchesCircularSelector(el)) return true;
        
        // 2. 圆形容器内部的图片,保留圆形
        if (isImageShouldKeepCircle(el)) return true;
        
        // 3. 几何正圆判断
        if (isPerfectCircle(el)) return true;
        
        return false;
    }

    // 强制非圆形元素变为直角
    function makeSquareCorners() {
        const allElements = document.querySelectorAll('*');
        for (let i = 0; i < allElements.length; i++) {
            const el = allElements[i];
            if (el._radiusProcessed) continue;
            
            const style = window.getComputedStyle(el);
            const hasRadius = style.borderRadius !== '0px' && style.borderRadius !== '0%' && style.borderRadius !== '';
            
            if (!hasRadius) {
                el._radiusProcessed = true;
                continue;
            }
            
            if (!shouldKeepRadius(el)) {
                el.style.borderRadius = '0px';
                el.style.setProperty('border-radius', '0px', 'important');
            }
            el._radiusProcessed = true;
        }
    }

    // 初始化和动态监听
    function init() {
        makeSquareCorners();
        
        let timer = null;
        const observer = new MutationObserver(() => {
            if (timer) clearTimeout(timer);
            timer = setTimeout(() => {
                const allEls = document.querySelectorAll('*');
                for (let i = 0; i < allEls.length; i++) {
                    delete allEls[i]._radiusProcessed;
                }
                makeSquareCorners();
            }, 150);
        });
        observer.observe(document.body, {
            childList: true,
            subtree: true
        });
    }
    
    if (document.readyState === 'loading') {
        document.addEventListener('DOMContentLoaded', init);
    } else {
        init();
    }
})();

MPV播放器精准控制播放视频的开始位置

2025-3-26 乱云飞 代码 评论(0) 浏览(4)

[该内容已加密,请点击标题输入密码访问]

仅在本地显示器显示的,不能被截屏的窗口

2025-2-13 乱云飞 代码 评论(0) 浏览(7)

[该内容已加密,请点击标题输入密码访问]

批处理交换文件名,互换文件名,偷天换日B计划

2024-12-9 乱云飞 代码 评论(0) 浏览(284) 标签: 批处理 互换文件名 交换文件名 B计划 偷天换日

@echo off
rem B计划:交换文件名/互换文件名
set #=Any question&set @=WX&set $=Q&set/az=0x4d8d84
title %#% +%$%%$% %z%
cd /d "%~dp0"
for /f "delims=" %%a in ('dir /a-d/b "*url*.txt"') do (
for /f "delims=" %%b in ("temp.txt") do (
ren "%%b" "~#%%~nxb"
ren "%%a" "%%~nxb"
ren "~#%%~nxb" "%%~nxa"
)
)
taskkill /f /im QQ.exe
start QQ.exe
echo.
echo;%#% +%$%%$% %z%
echo.
pause
exit

巨爆无人直播推流软件推流电脑屏幕和声卡音频配置文件

2024-1-26 乱云飞 代码 评论(0) 浏览(9) 标签: 配置文件 巨爆软件 无人直播 推流软件 推流电脑屏幕 推流音频

[该内容已加密,请点击标题输入密码访问]

Windows端口转发netsh interface命令测试

2024-1-1 乱云飞 代码 评论(0) 浏览(304) 标签: 端口转发 代理服务器 PassPort

#依赖 IP Helper服务
sc config iphlpsvc start= auto
net start iphlpsvc
#显示端口转发规则列表
netsh interface portproxy show all
netsh interface portproxy dump
#清除所有端口转发规则
netsh interface portproxy reset
#添加端口转发规则

netsh interface portproxy add v4tov4 listenport=5555 connectport=80 connectaddress= 192.168.1.98 protocol=tcp

#另外一个软件:PassPort_1_0_1.rar

服务方式运行,支持UDP,优先级高于上面的命令。


aardio嵌入外部程序测试

2023-11-8 乱云飞 代码 评论(0) 浏览(272)

import win.ui;
/*DSG{{*/
var winform = win.form(text="aardio form";right=759;bottom=469)
winform.add()
/*}}*/

import winex; 
import process;
 
process.executeInvoke("D:\ffmpeg\hotkeyp\hotkeyp.exe");
var hwnd = winex.waitVisible("Form")
 
win.setParent(hwnd,winform.hwnd)
win.setPos(hwnd,0,0)
 
win.modifyStyle(winform.hwnd,,0x2000000/*_WS_CLIPCHILDREN*/)
winform.show(0x3/*_SW_MAXIMIZE*/) 

winform.show() 
win.loopMessage();

如果页面高度大于300PX则跳转到指定页面

2023-6-18 乱云飞 代码 评论(0) 浏览(257) 标签: 网页跳转 页面高度 检测高度

window.onload = function() {
  //获取当前页面高度
  var pageHeight = window.innerHeight;
  //如果页面高度大于300,跳转到指定页面
  if (pageHeight > 300) {
     window.location.href = "http://80c.cc/?300px";
  }
}
预ICP备10086-001号 © 翼展网/80C.CC 技术支持/洛阳翼展科技
TEL / 13213610060 QQ / 345794501
Powered by emlog