设为首页
收藏本站
用户名
Email
自动登录
找回密码
密码
登录
注册
快捷导航
平台
Portal
论坛
BBS
文库
项目
群组
Group
我的博客
Space
搜索
搜索
热搜:
shell
linux
mysql
本版
用户
LinuxSir.cn,穿越时空的Linuxsir!
»
论坛
›
Linux 综合讨论区 —— LinuxSir.cn
›
开源软件专题讨论
›
一直在寻找sitman的代替软件
返回列表
查看:
1539
|
回复:
3
一直在寻找sitman的代替软件
[复制链接]
styrene
styrene
当前离线
积分
33
IP卡
狗仔卡
发表于 2007-9-23 15:11:22
|
显示全部楼层
|
阅读模式
有那位高手推荐一个。
学习英语也需要阿。
回复
使用道具
举报
提升卡
置顶卡
沉默卡
喧嚣卡
变色卡
显身卡
styrene
styrene
当前离线
积分
33
IP卡
狗仔卡
楼主
|
发表于 2007-10-21 12:17:56
|
显示全部楼层
自顶一下
类似的也行啊
回复
支持
反对
使用道具
举报
显身卡
threedot
threedot
当前离线
积分
331
IP卡
狗仔卡
发表于 2007-10-26 01:20:44
|
显示全部楼层
emacs 的插件,调用mpg321来播放,凑合能用.
将要听的mp3复制到/tmp/voa.mp3
f5播放,Shift-f5退出
f6跳到A-B区间的开头
Shift-f6暂停
f7设置复度区间的结尾B点
f8进入下一个区间
(defvar repeater-process-name "repeater-proc"
"The name of the mpg321 remote player process")
(defvar repeater-music-name "/tmp/voa.mp3"
"The default mp3 to be played")
(defvar var-repeater-insert-end-point 0)
(defvar repeater-begin 0)
(defvar repeater-end 0)
(defun repeater-start-process ()
(interactive)
"Run the mpg321 as the background program."
(let ((process (apply 'start-process
repeater-process-name
nil
"mpg123"
(list "-R" "-"))));;"-o alsa"
(set-process-sentinel process 'repeater-sentinel)
(set-process-filter process 'repeater-filter)
process))
(defun repeater-filter (proc str)
(let* ((data-lines (split-string str "\n" t))
data line cmd)
(dolist (line data-lines)
(setq data (split-string line))
(setq cmd (car data))
(cond
;; stop notice
((and (string= cmd "@P")
(string= (cadr data) "0"))
(repeter-stop-notify)) ;;here~~~~
;; frame notice
((string= cmd "@F")
(repeater-check-functions (string-to-number (nth 1 data)))
)))))
(defun repeater-sentinel (proc str)
"Sentinel for determining the end of process"
(when (or (eq (process-status proc) 'exit)
(eq (process-status proc) 'signal))
;; reset
(setq repeater-ignore-stop 0)
(message "Remote process died!")))
(defun repeter-stop-notify()
"Recevied the stop notice."
(repeater-start repeater-music-name)
)
(defun repeater-check-functions(point)
"Check point to repeat"
;;case
(if (eq var-repeater-insert-end-point 1)
(setq repeater-end point var-repeater-insert-end-point 0)
;//insert end point
)
;;;test
(if (or (< point repeater-begin) (and (> repeater-end 0) (> point repeater-end)))(repeater-jump (number-to-string repeater-begin))))
(defun repeater-send (text)
"Send TEXT to the mpg321 remote process, and add a newline."
(let (proc)
;; we shouldn't be trying to send to a dead process
(unless (repeater-running-p)
(repeater-start-process))
(setq proc (repeater-process))
(process-send-string proc (concat text "\n"))
(message text)
))
(defun repeater-running-p ()
"True if the remote process exists and is running."
(let ((proc (repeater-process)))
(and proc
(eq (process-status proc) 'run))))
(defun repeater-process ()
"Return the remote process, if it exists."
(get-process repeater-process-name))
;;(defun repeater-play-track (track)
(defun repeater-play-track (track)
"Send a play command to the remote, based on TRACK."
(repeater-send
(concat "load " track))
)
(defun repeater-start (track)
(interactive)
"Start playing a song by telling the remote process to play it.
If the remote process is not running, launch it."
(unless (repeater-running-p)
(repeater-start-process))
(repeater-play-track track))
(defun repeater-quit ()
(interactive)
"Quit mpg321"
;;(emms-player-mpg321-remote-notify-emms t)
(repeater-send "quit")
)
(defun repeater-pause ()
(interactive)
"Pause the player."
(repeater-send "pause")
)
(defun repeater-jump(frame)
(interactive)
"Jump to the special frame."
(repeater-send (concat "jump " frame))
)
(defun repeater-default() ;;/test
(interactive)
(setq repeater-begin 0 repeater-end 0)
(repeater-start repeater-music-name)
)
(defun repeater-insert-end-point()
(interactive)
(setq var-repeater-insert-end-point 1)
)
(defun repeater-clear-point()
(interactive)
(setq repeater-begin 0 repeater-end 0)
(message "Clear all point")
)
(defun repeater-other-range()
(interactive)
(if (eq repeater-end 0)(setq repeater-end repeater-begin repeater-begin 0)
(setq repeater-begin repeater-end repeater-end 0)
)
)
(defun repeater-jump-begin()
(interactive)
(repeater-jump (number-to-string repeater-begin))
)
(global-set-key (kbd "<f5>") 'repeater-default)
(global-set-key (kbd "<S-f5>") 'repeater-quit)
(global-set-key (kbd "<S-f6>") 'repeater-pause)
(global-set-key (kbd "<f6>") 'repeater-jump-begin)
(global-set-key (kbd "<f7>") 'repeater-insert-end-point)
(global-set-key (kbd "<f8>") 'repeater-other-range)
复制代码
回复
支持
反对
使用道具
举报
显身卡
styrene
styrene
当前离线
积分
33
IP卡
狗仔卡
楼主
|
发表于 2007-10-29 14:43:18
|
显示全部楼层
厉害阿,可惜我不会,
只想找一个相似的
回复
支持
反对
使用道具
举报
显身卡
返回列表
高级模式
B
Color
Image
Link
Quote
Code
Smilies
您需要登录后才可以回帖
登录
|
注册
本版积分规则
发表回复
回帖后跳转到最后一页
浏览过的版块
Debian Linux
服务器架设、应用、维护
Linux 基础讨论区(新手速成)
Archlinux讨论区
SuSE Linux
Ubuntu Linux 专题讨论
Mandriva Linux
Slackware Linux
Redhat/Fedora/CentOS Linux
Copyright © 2002-2023
LinuxSir.cn
(http://www.linuxsir.cn/) 版权所有 All Rights Reserved.
Powered by
RedflagLinux!
技术支持:
中科红旗
|
京ICP备19024520号
快速回复
返回顶部
返回列表