feat(capture): toggle mouse pointer via capture.video.show_pointer (#691)

* feat(capture): toggle mouse pointer via capture.video.show_pointer

- config: register capture.video.show_pointer config option
- config: default pointer to visible (ShowPointer: true) on the
hardcoded fallback pipeline, override applies only when the flag is
explicitly set, so per-pipeline YAML overrides stay untouched
- compose: document NEKO_CAPTURE_VIDEO_SHOW_POINTER example

* fix(capture): apply show_pointer to all pipelines

- capture: thread capture.video.show_pointer into broadcast and
  screencast gstreamer pipelines, previously hardcoded show-pointer=true
  and silently ignored the flag
- config: resolve capture.video.show_pointer once into
  Capture.VideoShowPointer so all pipeline builders share one value
- docs: document capture.video.show_pointer in configuration/capture.md,
  including its reach into broadcast and screencast, and regenerate
  help.txt/help.json
- compose: drop stray commented-out example, default compose file is
  not meant to list every option
This commit is contained in:
ycsi
2026-08-29 19:47:04 +08:00
committed by GitHub
parent a7a217e607
commit b0f01cedea
5 changed files with 37 additions and 9 deletions
+4 -4
View File
@@ -101,12 +101,12 @@ func New(desktop types.DesktopManager, config *config.Capture) *CaptureManagerCt
"! queue "+
"! voaacenc bitrate=%d "+
"! mux. "+
"ximagesrc display-name=%s show-pointer=true use-damage=false "+
"ximagesrc display-name=%s show-pointer=%v use-damage=false "+
"! video/x-raw "+
"! videoconvert "+
"! queue "+
"! x264enc threads=4 bitrate=%d key-int-max=15 byte-stream=true tune=zerolatency speed-preset=%s "+
"! mux.", url, config.AudioDevice, config.BroadcastAudioBitrate*1000, config.Display, config.BroadcastVideoBitrate, config.BroadcastPreset,
"! mux.", url, config.AudioDevice, config.BroadcastAudioBitrate*1000, config.Display, config.VideoShowPointer, config.BroadcastVideoBitrate, config.BroadcastPreset,
), nil
}, config.BroadcastUrl, config.BroadcastAutostart),
screencast: screencastNew(config.ScreencastEnabled, func() string {
@@ -116,12 +116,12 @@ func New(desktop types.DesktopManager, config *config.Capture) *CaptureManagerCt
}
return fmt.Sprintf(
"ximagesrc display-name=%s show-pointer=true use-damage=false "+
"ximagesrc display-name=%s show-pointer=%v use-damage=false "+
"! video/x-raw,framerate=%s "+
"! videoconvert "+
"! queue "+
"! jpegenc quality=%s "+
"! appsink name=appsink", config.Display, config.ScreencastRate, config.ScreencastQuality,
"! appsink name=appsink", config.Display, config.VideoShowPointer, config.ScreencastRate, config.ScreencastQuality,
)
}()),