有没有复读机功能的软件
- David50814
- 帖子: 556
- 注册时间: 2007-06-11 4:20
- 来自: 北京
- 联系:
有没有复读机功能的软件
最近在看英文版圣经锻炼英语和听圣经的英语语音(非美语)
想反复的联系一句话(你知道,他们语速很快的)
但没有那样的软件,请问谁知道有这样的软件吗?
想反复的联系一句话(你知道,他们语速很快的)
但没有那样的软件,请问谁知道有这样的软件吗?
- David50814
- 帖子: 556
- 注册时间: 2007-06-11 4:20
- 来自: 北京
- 联系:
- aitilang
- 帖子: 1026
- 注册时间: 2007-04-28 21:38
- stlxv
- 论坛版主
- 帖子: 8275
- 注册时间: 2006-05-03 0:39
- 来自: المريخ
Re: 有没有复读机功能的软件
古兰经学习软件就见过,那个ubuntu穆斯林版就有自带了David50814 写了:最近在看英文版圣经锻炼英语和听圣经的英语语音(非美语)
想反复的联系一句话(你知道,他们语速很快的)
但没有那样的软件,请问谁知道有这样的软件吗?
PHP是最好的语言!不服来战!
-
- 帖子: 3
- 注册时间: 2008-05-26 21:24
修改了mplayer-1.0~rc1,增加了一些代码来支持类似sitman的功能。
F9:插入分段点
F10:播放当前段
F11:播放前一段
F12:播放下一段
附件是我修改并编译过的mplayer以及修改的patch。
附件不能贴上来,奇怪,直接贴代码了。
From d9851731c35256edae502c1b5628fd501e63744d Mon Sep 17 00:00:00 2001
From: mwwang <mwwang@debian.xxx>
Date: Mon, 26 May 2008 21:44:56 +0800
Subject: [PATCH] standman base on mplayer
Signed-off-by: mwwang <mwwang@debian.xxx>
---
input/input.c | 10 +++++++
input/input.h | 4 +++
mplayer.c | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 90 insertions(+), 0 deletions(-)
diff --git a/input/input.c b/input/input.c
index f2b5a83..5a79676 100644
--- a/input/input.c
+++ b/input/input.c
@@ -168,6 +168,11 @@ static mp_cmd_t mp_cmds[] = {
{ MP_CMD_SEEK_CHAPTER, "seek_chapter", 1, { {MP_CMD_ARG_INT,{0}}, {MP_CMD_ARG_INT,{0}}, {-1,{0}} } },
{ MP_CMD_SET_MOUSE_POS, "set_mouse_pos", 2, { {MP_CMD_ARG_INT,{0}}, {MP_CMD_ARG_INT,{0}}, {-1,{0}} } },
+ { MP_CMD_ADD, "standman_add", 0, { {-1,{0}} } },
+ { MP_CMD_CURR, "standman_curr", 0, { {-1,{0}} } },
+ { MP_CMD_PREV, "standman_prev", 0, { {-1,{0}} } },
+ { MP_CMD_NEXT, "standman_next", 0, { {-1,{0}} } },
+
{ 0, NULL, 0, {} }
};
@@ -421,6 +426,11 @@ static mp_cmd_bind_t def_cmd_binds[] = {
{ { '!', 0 }, "seek_chapter -1" },
{ { '@', 0 }, "seek_chapter 1" },
+ { { KEY_F+9, 0 }, "standman_add" },
+ { { KEY_F+10, 0 }, "standman_curr" },
+ { { KEY_F+11, 0 }, "standman_prev" },
+ { { KEY_F+12, 0 }, "standman_next" },
+
{ { 0 }, NULL }
};
diff --git a/input/input.h b/input/input.h
index f220a08..922f006 100644
--- a/input/input.h
+++ b/input/input.h
@@ -90,6 +90,10 @@
#define MP_CMD_RADIO_SET_CHANNEL 88
#define MP_CMD_RADIO_SET_FREQ 89
#define MP_CMD_SET_MOUSE_POS 90
+#define MP_CMD_ADD 91
+#define MP_CMD_CURR 92
+#define MP_CMD_PREV 93
+#define MP_CMD_NEXT 94
#define MP_CMD_GUI_EVENTS 5000
#define MP_CMD_GUI_LOADFILE 5001
diff --git a/mplayer.c b/mplayer.c
index acdfab9..0d9651e 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -433,6 +433,16 @@ static unsigned int inited_flags=0;
#define mp_basename2(s) (strrchr(s,'/')==NULL?(char*)s:(strrchr(s,'/')+1))
+struct thread_list{
+ float point_time;
+ float start_time;
+ struct thread_list *prev;
+ struct thread_list *next;
+};
+
+static struct thread_list *p_head;
+static struct thread_list *p_list;
+
static int is_valid_metadata_type (metadata_t type) {
switch (type)
{
@@ -2821,6 +2831,20 @@ int gui_no_filename=0;
struct {double pts; vo_functions_t *vo;} vf_vo_data;
+ p_head = (struct thread_list *)malloc(sizeof(struct thread_list));
+ if (p_head == NULL) {
+ printf("malloc error.\n");
+ exit(-1);
+ }
+ memset(p_head, 0, sizeof(struct thread_list));
+
+ p_head->next = p_head;
+ p_head->prev = p_head;
+ p_head->point_time = 0.0;
+ p_head->start_time = 0.0;
+
+ p_list = p_head;
+
srand((int) time(NULL));
InitTimer();
@@ -4117,6 +4141,11 @@ if(!sh_video) {
if(!quiet || end_at.type == END_AT_TIME )
a_pos = playing_audio_pts(sh_audio, d_audio, audio_out);
+ if (p_list->next->point_time != 0 && a_pos > p_list->next->point_time) {
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ }
+
if(!quiet)
print_status(a_pos, 0, 0);
@@ -5237,6 +5266,53 @@ if(step_sec>0) {
break;
}
#endif
+ case MP_CMD_ADD: {
+ struct thread_list *p_new, *p_temp;
+
+ p_new = (struct thread_list *)malloc(sizeof(struct thread_list));
+ if (p_new == NULL) {
+ printf("malloc error.\n");
+ exit(-1);
+ }
+ memset(p_new, 0, sizeof(struct thread_list));
+
+ if(sh_video)
+ p_new->point_time = sh_video->pts;
+ else {
+ if(!quiet || end_at.type == END_AT_TIME )
+ p_new->point_time = playing_audio_pts(sh_audio, d_audio, audio_out);
+ }
+ p_new->start_time = p_new->point_time;
+ p_new->start_time -= (p_new->start_time > 1)? 0.7 : 0;
+ printf("add during time: %f ~ %f |\n\n", p_list->start_time, p_new->point_time);
+
+ p_temp = p_head->prev;
+ while(p_new->point_time < p_temp->point_time){
+ p_temp = p_temp->prev;
+ }
+ p_new->next = p_temp->next;
+ p_temp->next->prev = p_new;
+ p_new->prev = p_temp;
+ p_temp->next = p_new;
+ } break;
+ case MP_CMD_CURR: {
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ printf("point time: %f\n\n", p_list->point_time);
+ printf("during time: %f ~ %f |\n\n", p_list->start_time, p_list->next->point_time);
+ } break;
+ case MP_CMD_PREV: {
+ p_list = p_list->prev;
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ printf("during time: %f ~ %f |\n\n", p_list->start_time, p_list->next->point_time);
+ } break;
+ case MP_CMD_NEXT: {
+ p_list = p_list->next;
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ printf("during time: %f ~ %f |\n\n", p_list->start_time, p_list->next->point_time);
+ } break;
default : {
#ifdef HAVE_NEW_GUI
if ( ( use_gui )&&( cmd->id > MP_CMD_GUI_EVENTS ) ) guiGetEvent( guiIEvent,(char *)cmd->id );
--
1.5.5.1
F9:插入分段点
F10:播放当前段
F11:播放前一段
F12:播放下一段
附件是我修改并编译过的mplayer以及修改的patch。
附件不能贴上来,奇怪,直接贴代码了。
From d9851731c35256edae502c1b5628fd501e63744d Mon Sep 17 00:00:00 2001
From: mwwang <mwwang@debian.xxx>
Date: Mon, 26 May 2008 21:44:56 +0800
Subject: [PATCH] standman base on mplayer
Signed-off-by: mwwang <mwwang@debian.xxx>
---
input/input.c | 10 +++++++
input/input.h | 4 +++
mplayer.c | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 90 insertions(+), 0 deletions(-)
diff --git a/input/input.c b/input/input.c
index f2b5a83..5a79676 100644
--- a/input/input.c
+++ b/input/input.c
@@ -168,6 +168,11 @@ static mp_cmd_t mp_cmds[] = {
{ MP_CMD_SEEK_CHAPTER, "seek_chapter", 1, { {MP_CMD_ARG_INT,{0}}, {MP_CMD_ARG_INT,{0}}, {-1,{0}} } },
{ MP_CMD_SET_MOUSE_POS, "set_mouse_pos", 2, { {MP_CMD_ARG_INT,{0}}, {MP_CMD_ARG_INT,{0}}, {-1,{0}} } },
+ { MP_CMD_ADD, "standman_add", 0, { {-1,{0}} } },
+ { MP_CMD_CURR, "standman_curr", 0, { {-1,{0}} } },
+ { MP_CMD_PREV, "standman_prev", 0, { {-1,{0}} } },
+ { MP_CMD_NEXT, "standman_next", 0, { {-1,{0}} } },
+
{ 0, NULL, 0, {} }
};
@@ -421,6 +426,11 @@ static mp_cmd_bind_t def_cmd_binds[] = {
{ { '!', 0 }, "seek_chapter -1" },
{ { '@', 0 }, "seek_chapter 1" },
+ { { KEY_F+9, 0 }, "standman_add" },
+ { { KEY_F+10, 0 }, "standman_curr" },
+ { { KEY_F+11, 0 }, "standman_prev" },
+ { { KEY_F+12, 0 }, "standman_next" },
+
{ { 0 }, NULL }
};
diff --git a/input/input.h b/input/input.h
index f220a08..922f006 100644
--- a/input/input.h
+++ b/input/input.h
@@ -90,6 +90,10 @@
#define MP_CMD_RADIO_SET_CHANNEL 88
#define MP_CMD_RADIO_SET_FREQ 89
#define MP_CMD_SET_MOUSE_POS 90
+#define MP_CMD_ADD 91
+#define MP_CMD_CURR 92
+#define MP_CMD_PREV 93
+#define MP_CMD_NEXT 94
#define MP_CMD_GUI_EVENTS 5000
#define MP_CMD_GUI_LOADFILE 5001
diff --git a/mplayer.c b/mplayer.c
index acdfab9..0d9651e 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -433,6 +433,16 @@ static unsigned int inited_flags=0;
#define mp_basename2(s) (strrchr(s,'/')==NULL?(char*)s:(strrchr(s,'/')+1))
+struct thread_list{
+ float point_time;
+ float start_time;
+ struct thread_list *prev;
+ struct thread_list *next;
+};
+
+static struct thread_list *p_head;
+static struct thread_list *p_list;
+
static int is_valid_metadata_type (metadata_t type) {
switch (type)
{
@@ -2821,6 +2831,20 @@ int gui_no_filename=0;
struct {double pts; vo_functions_t *vo;} vf_vo_data;
+ p_head = (struct thread_list *)malloc(sizeof(struct thread_list));
+ if (p_head == NULL) {
+ printf("malloc error.\n");
+ exit(-1);
+ }
+ memset(p_head, 0, sizeof(struct thread_list));
+
+ p_head->next = p_head;
+ p_head->prev = p_head;
+ p_head->point_time = 0.0;
+ p_head->start_time = 0.0;
+
+ p_list = p_head;
+
srand((int) time(NULL));
InitTimer();
@@ -4117,6 +4141,11 @@ if(!sh_video) {
if(!quiet || end_at.type == END_AT_TIME )
a_pos = playing_audio_pts(sh_audio, d_audio, audio_out);
+ if (p_list->next->point_time != 0 && a_pos > p_list->next->point_time) {
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ }
+
if(!quiet)
print_status(a_pos, 0, 0);
@@ -5237,6 +5266,53 @@ if(step_sec>0) {
break;
}
#endif
+ case MP_CMD_ADD: {
+ struct thread_list *p_new, *p_temp;
+
+ p_new = (struct thread_list *)malloc(sizeof(struct thread_list));
+ if (p_new == NULL) {
+ printf("malloc error.\n");
+ exit(-1);
+ }
+ memset(p_new, 0, sizeof(struct thread_list));
+
+ if(sh_video)
+ p_new->point_time = sh_video->pts;
+ else {
+ if(!quiet || end_at.type == END_AT_TIME )
+ p_new->point_time = playing_audio_pts(sh_audio, d_audio, audio_out);
+ }
+ p_new->start_time = p_new->point_time;
+ p_new->start_time -= (p_new->start_time > 1)? 0.7 : 0;
+ printf("add during time: %f ~ %f |\n\n", p_list->start_time, p_new->point_time);
+
+ p_temp = p_head->prev;
+ while(p_new->point_time < p_temp->point_time){
+ p_temp = p_temp->prev;
+ }
+ p_new->next = p_temp->next;
+ p_temp->next->prev = p_new;
+ p_new->prev = p_temp;
+ p_temp->next = p_new;
+ } break;
+ case MP_CMD_CURR: {
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ printf("point time: %f\n\n", p_list->point_time);
+ printf("during time: %f ~ %f |\n\n", p_list->start_time, p_list->next->point_time);
+ } break;
+ case MP_CMD_PREV: {
+ p_list = p_list->prev;
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ printf("during time: %f ~ %f |\n\n", p_list->start_time, p_list->next->point_time);
+ } break;
+ case MP_CMD_NEXT: {
+ p_list = p_list->next;
+ abs_seek_pos = 1;
+ rel_seek_secs = p_list->start_time;
+ printf("during time: %f ~ %f |\n\n", p_list->start_time, p_list->next->point_time);
+ } break;
default : {
#ifdef HAVE_NEW_GUI
if ( ( use_gui )&&( cmd->id > MP_CMD_GUI_EVENTS ) ) guiGetEvent( guiIEvent,(char *)cmd->id );
--
1.5.5.1
- BigSnake.NET
- 帖子: 12522
- 注册时间: 2006-07-02 11:16
- 来自: 廣州
- 联系:
- hyxuzhimin
- 帖子: 249
- 注册时间: 2008-05-09 14:14