# ============================================================ # RTSP Watchdog 설정 # ============================================================ # # 주석/설명 규칙 # - 줄의 첫 문자가 #, ;, // 중 하나이면 설명으로 처리하고 건너뜁니다. # - 앞쪽 공백 뒤에 #, ;, //가 있어도 설명으로 처리합니다. # - 값 오른쪽에는 주석을 붙이지 마십시오. 설명은 별도 줄에 작성합니다. # - 경로와 장치명은 따옴표 없이 적어도 됩니다. # - 기능 스위치는 1=사용, 0=사용 안 함입니다. # - 명령줄에서 지정한 값은 이 파일보다 우선합니다. ; 세미콜론으로 시작하는 이 줄도 설명으로 처리됩니다. // 슬래시 두 개로 시작하는 이 줄도 설명으로 처리됩니다. # # 실행 # powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\screen-rtsp.ps1 # powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\screen-rtsp.ps1 -ShowConfiguration # # 별도 설정 파일 사용 # powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\screen-rtsp.ps1 -ConfigPath .\config.ini # # 자동 실행 등록 / 상태 확인 / 즉시 실행 / 제거 # powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\screen-rtsp.ps1 -InstallStartup # powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\screen-rtsp.ps1 -StartupStatus # Start-ScheduledTask -TaskName "Screen RTSP Watchdog" # powershell.exe -NoProfile -ExecutionPolicy Bypass -File .\screen-rtsp.ps1 -UninstallStartup # # GPU와 FFmpeg 지원 확인 # Get-CimInstance Win32_VideoController | Select-Object Name,DriverVersion,Status # .\ffmpeg.exe -hide_banner -filters | Select-String ddagrab # .\ffmpeg.exe -hide_banner -encoders | Select-String 'h264_(nvenc|amf|qsv)' # # 모니터 확인 # Add-Type -AssemblyName System.Windows.Forms # [System.Windows.Forms.Screen]::AllScreens | Select-Object DeviceName,Primary,Bounds # # 오디오 장치 확인 # Get-PnpDevice -Class AudioEndpoint | Select-Object Status,FriendlyName,InstanceId # Get-CimInstance Win32_SoundDevice | Select-Object Name,Status,PNPDeviceID # # 네트워크 확인 # Get-NetAdapter | Select-Object Name,InterfaceDescription,ifIndex,Status,LinkSpeed # Get-NetIPAddress -AddressFamily IPv4 | Select-Object InterfaceAlias,InterfaceIndex,IPAddress # Get-NetRoute -AddressFamily IPv4 -DestinationPrefix 0.0.0.0/0 # ping.exe -S 192.168.50.34 192.168.50.1 # # RTSP 포트와 수신 시험 # Get-NetTCPConnection -LocalPort 8554 -State Listen # .\ffmpeg.exe -hide_banner -rtsp_transport tcp -i rtsp://127.0.0.1:8554/monitor1 -t 5 -f null NUL [General] # 생성할 monitor 채널 수. 이 수만큼 캡처 가능한 활성 모니터가 필요합니다. ChannelCount=2 # 모든 조건이 정상인 상태로 유지되어야 하는 시간입니다. StableTimeSec=3 # 모니터, NIC, GPU, 오디오 상태 확인 주기입니다. PollIntervalSec=1 [Video] FrameRate=30 Bitrate=8000k # 앞에 있는 GPU부터 실제 1프레임 인코더 초기화를 시험합니다. EncoderPriority=NVIDIA,AMD,Intel [Audio] # 시스템 재생음 녹음 및 RTSP AAC 트랙: 1=사용, 0=사용 안 함 Enabled=1 Bitrate=192k # 실제 소리가 출력되는 장치를 판별할 peak 최소값입니다. 범위는 0.0~1.0입니다. SignalThreshold=0.0005 [Network] # 비워 두면 IPv4 기본 경로의 활성 NIC를 자동 선택합니다. # 특정 장치를 강제하려면 Get-NetAdapter의 InterfaceDescription을 그대로 적습니다. NicDescription= # 비워 두면 Source IP ping 검사를 하지 않습니다. # 예: 192.168.50.1 HealthTarget= [RTSP] Port=8554