查看: 4728|回复: 16

如何制作歌词同步音画

[复制链接]

发表于 2008-6-29 14:27 | 显示全部楼层 |阅读模式

(一)编辑歌词

 

千千静听的歌词文件有其特定的格式,每句歌词前面都必须有类似[00:16.00]这样的时间标签,否则歌词无法正常显示。歌词可以用各种文本编辑工具进行编辑,最后保存成lrc或txt扩展名即可。不过,用其他文本编辑工具编辑歌词时需要自己手动输入时间标签,比较麻烦,您可以选择千千歌词秀编辑,轻点鼠标即可插入时间标签,轻松完成歌词编辑。

编辑方法如下:
1、在播放列表中选中您想要编辑歌词的曲目
2、在千千歌词秀显示窗口单击鼠标右键,在菜单中选择“编辑歌词”,进入歌词编辑模式。
3、点击编辑模式下歌词秀窗口中的播放键;在听到歌声的瞬间,点击暂停。
4、点击鼠标右键,在弹出菜单中选择插入时间标签,再次点击播放键。
5、在本句歌词演唱结束时点击“暂停”,在刚插入的时间标签后输入歌词内容,并将光标下移一行。
6、点击“播放”,在听到第二句歌词演唱开始的瞬间,点击“暂停”。重复4-6的步骤,直到歌词完全输入。
7、在歌词头部输入歌词[ti:]、[ar:]、[al:]、[by:]等信息增加歌词的完整性,这一步也可以在步骤3之前做,也可以不写。
8、编辑完毕,右键菜单选择“返回显示”,重新播放歌曲检查歌词编辑是否有误。
9、若检查后没有发现错误或者遗漏,则可以保存并进入时间校正;否则请返回编辑模式修改。

提示:
·不用过分在意点击“暂停”的时间是否精确,输入完毕后可以进行时间校正。
·遇到需要重复输入的歌词,点击“暂停”后,将光标移至已输入的歌词处插入时间标签即可,无需重新输入。您可以在右键菜单中选择“排列方式-〉全部展开”,即可按时间标签顺序浏览歌词。


 楼主| 发表于 2008-6-29 14:29 | 显示全部楼层

示例:

[ti:红尘]
[ar:f李翊君]
[al:红尘]
[by: ☆☆☆☆☆☆]
[00:05.00]演唱:李翊君
[00:30.00]音画制作:东方血狐
[00:35.00]爱 怎么断
[00:41.00]才能潇洒来去
[00:45.00]不留一丝遗憾
[00:49.00]情字乱 总来纠缠
[00:54.00]伴 无声的呐喊
[00:59.00]我的心 有牵绊
[01:04.00]尝过酸甜苦辣
[01:07.00]数不尽的悲欢
[01:12.00]谁欠谁 该怎么算
[01:16.00]英雄低头也无力还
[01:23.00]红尘 谁能看穿
[01:26.00]东势悬崖西有寂寞
[01:30.00]阻拦
[01:34.00]回忆走投无路痛成了习惯
[01:38.00]谁告诉我该怎么办
[01:42.00]
[01:55.00]爱 怎么断
[01:59.00]才能潇洒来去
[02:01.00]不留一丝遗憾
[02:07.00]情字乱 总来纠缠
[02:11.00]伴 无声的呐喊
[02:16.00]我的心 有牵绊
[02:22.00]尝过酸甜苦辣
[02:24.00]数不尽的悲欢
[02:29.00]谁欠谁 该怎么算
[02:34.00]英雄低头也无力还
[02:39.00]红尘 谁能看穿
[02:42.00]东势悬崖西有寂寞
[02:51.00]阻拦
[02:56.00]回忆走投无路痛成了习惯
[03:02.00]谁告诉我该怎么办
[03:08.00]我的挣扎你不给答案
[03:14.00]却又一厢情愿带我陷情关
[03:14.00]等待变成伤感 清醒太难
[03:21.00]也只好任泪水泛滥
[03:23.00]俗世红尘 谁能承担
[03:30.00]擦身而过却换来一生孤单
[03:37.00]承诺或是拒绝你只给一半
[03:42.00]爱不爱你都为难
[04:00.00]☆☆☆☆☆☆

回复 使用道具


 楼主| 发表于 2008-6-29 14:34 | 显示全部楼层

代码:

<HTML  xmlns:v>
<style >
v\:*{behavior:url(#default#VML)}
v\:textpath{font-family:新宋体;font-size:18px;v-text-align:left}
</style>
<body >
<xmp id=xLyric style=display:none>
[ti:红尘]
[ar:f李翊君]
[al:红尘]
[by: 音画制作:东方血狐]
[00:05.00]演唱:李翊君
[00:30.00]音画制作:东方血狐
[00:35.00]爱 怎么断
[00:41.00]才能潇洒来去
[00:45.00]不留一丝遗憾
[00:49.00]情字乱 总来纠缠
[00:54.00]伴 无声的呐喊
[00:59.00]我的心 有牵绊
[01:04.00]尝过酸甜苦辣
[01:07.00]数不尽的悲欢
[01:12.00]谁欠谁 该怎么算
[01:16.00]英雄低头也无力还
[01:23.00]红尘 谁能看穿
[01:26.00]东势悬崖西有寂寞
[01:30.00]阻拦
[01:34.00]回忆走投无路痛成了习惯
[01:38.00]谁告诉我该怎么办
[01:42.00]
[01:55.00]爱 怎么断
[01:59.00]才能潇洒来去
[02:01.00]不留一丝遗憾
[02:07.00]情字乱 总来纠缠
[02:11.00]伴 无声的呐喊
[02:16.00]我的心 有牵绊
[02:22.00]尝过酸甜苦辣
[02:24.00]数不尽的悲欢
[02:29.00]谁欠谁 该怎么算
[02:34.00]英雄低头也无力还
[02:39.00]红尘 谁能看穿
[02:42.00]东势悬崖西有寂寞
[02:51.00]阻拦
[02:56.00]回忆走投无路痛成了习惯
[03:02.00]谁告诉我该怎么办
[03:08.00]我的挣扎你不给答案
[03:14.00]却又一厢情愿带我陷情关
[03:14.00]等待变成伤感 清醒太难
[03:21.00]也只好任泪水泛滥
[03:23.00]俗世红尘 谁能承担
[03:30.00]擦身而过却换来一生孤单
[03:37.00]承诺或是拒绝你只给一半
[03:42.00]爱不爱你都为难
[04:00.00]☆☆☆☆☆☆
</xmp>
</body >
</html>
<script >
window.onerror=function(){return false}
start()
function start(){
browser_ini()
timer_ini()
emv_ini()
lrc.setData(oo("xLyric").innerHTML)
lrc.write("歌词载入中...","l")
emv.play("http://www .lanxin.net/lanxinadmin/eWebeditor/Uploadfile/2006715153555587.mp3")
}
function emv_ini(){
var l
window.emv={}
lrc_ini()
l="<div id=bxEmv style=position:absolute;left:0;top:0;width:900;height:50>"
        l+="<div id=bxEmvScreen style=position:absolute;overflow:hidden;left:0;top:0;width:900;height:50;background-color:#ffffff>"
        l+="</div>"
l+="</div>"
l+="<object classid=clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95 id=mplayer  width=0 height=0style=display:xnone;position:absolute;left:400;top:200><param name=PlayCount value=0><param name=ShowStatusBar value=-1><param name=Volume value=0></object>"
insHtm(document.body,l)
emv.play=function(url){oo("mplayer").FileName=url;oo("mplayer").Play()}
emv.time=function(){
  var mPos
  var n1,o,len,w,per,n0,n1
  if(mplayer==null)
   return
  mPos=mplayer.CurrentPosition
  n=-1
  for(i=0;i<lrc.arr.length;i++){
   if(mPos<lrc.arr.slice(0,"|")*1)
    break
   n=i
  }
  if(n==-1)
   return
  if(lrc.i!=n){
   if(n==0)
    lrc.write(lrc.arr[n].slice("|"),"l")
   if(n!=lrc.i+1)
    lrc.write(lrc.arr[n].slice("|"),n%2==0?"l":"r")
   if(n<lrc.arr.length-1)
    lrc.write(lrc.arr[n+1].slice("|"),n%2==1?"l":"r")
   lrc.i=n
  }
  n0=lrc.arr[n].slice(0,"|")
  n1=lrc.arr.length>n+1?lrc.arr[n+1].slice(0,"|"):4
  o=oo("bxCaption_"+(n%2==0?"l":"r")+"_cover")
  len=o.time!=""?o.time*1:n1-n0
  per=(mPos-n0)/len
  for(i=0.001;i<1;i+=0.001){
   per1=lrc.getRealPos(o,i)
   if(per1>=per)
    break
  }
  o.style.width=o.width*i
}
timer.add("emv.time()")
}
function lrc_ini(){
window.lrc={}
lrc.wordPer=function(str,pos){
  return str.slice(0,pos).replace(/[^\x00-\xff]/g,"  ").length/str.replace(/[^\x00-\xff]/g,"  ").length
}
lrc.setData=function(str){
  var l,a,i,ad,n,j
  str=str.replace(/\|/g,"").replace(/\r\n/g,"\n")
  str=str.replace(/\[(\d\d)\:(\d\d)\.(\d\d)\]/g,function($0,$1,$2,$3){return ($1*60+$2*1+$3/100)+"|"})
  a=str.split("\n")
  lrc.arr=new Array()
  for(i=0;i<a.length;i++){
   ad=a.split("|")
   for(j=1;j<ad.length;j++){
    lrc.arr.add(ad[j-1]+"|"+ad[ad.length-1])
   }
  }
  lrc.i=-1
  sortIndex=0
  sortDir=1
  lrc.arr.sort(sortFoo)
}
lrc.getRealPos=function(obj,pos){
  var a=obj.path,zoom=obj.zoom,pos1=pos*zoom
  var a,i,ad
  for(i=0;i<a.length;i++){
   ad=a
   if(pos<=ad[0])
    continue
   if(pos>ad[0]&&pos<=ad[1])
    pos1+=(zoom*ad[2]-zoom)*(pos-ad[0])
   else
    pos1+=(zoom*ad[2]-zoom)*(ad[1]-ad[0])
   
  }
  return pos1
}
lrc.write =function(str,pos){
  var word=str,style=""
  var x,y,l,w,w1,o,a,i,ad
  if(/^\<.+\>/.test(str)){
   word=str.slice(">")
   style=str.slice(1).slice(0,">")
  }
  w=word.replace(/[^\x00-\xff]/g,"  ").length*13+2
  if(pos=="l"){
   x=60
                            y=19
  }
  else{
   x=710-w
   y=19
  }
  l="<div id=bxCaption_"+pos+" style='position:absolute;left:"+x+";top:"+y+";width:"+w+";height:32;overflow:hidden'>"
  l+="<v:curve to=800,1 strokecolor=#FFFF00 strokeweight=3 style=position:absolute;top:10>"
  l+="<v:path textpathok=t /><v:textpath on=t string='"+word+"' /></v:curve>"
  l+="<v:curve to=800,1 strokecolor=#0000FF fillcolor=#0000FFstrokeweight=1 style=position:absolute;top:10>"
  l+="<v:path textpathok=t /><v:textpath on=t string='"+word+"' /></v:curve>"
  l+="</div>"
  l+="<div id=bxCaption_"+pos+"_cover width="+w+" style=position:absolute;left:"+x+";top:"+y+";width:0;height:32;overflow:hidden>"
  l+="<v:curve to=800,1 strokecolor=#FFFF00 strokeweight=3 style=position:absolute;top:10>"
  l+="<v:path textpathok=t /><v:textpath on=t string='"+word+"' /></v:curve>"
  l+="<v:curve to=800,1 strokecolor=#FF3030 fillcolor=#FF3030 strokeweight=1 style=position:absolute;top:10>"
  l+="<v:path textpathok=t /><v:textpath on=t string='"+word+"' /></v:curve>"
  l+="</div>"
  odel("bxCaption_"+pos)
  odel("bxCaption_"+pos+"_cover")
  insHtm("bxEmvScreen",l)
  o=oo("bxCaption_"+pos+"_cover")
  o.time=style.get("time")
  o.path=new Array()
  len1=1
  a=style.split(";")
  for(i=0;i<a.length;i++){
   if(!/(\d+):(\d+)/.test(a))
    continue
   if(/(\d+)-(\d+):(\d+)/.test(a)){
    ad=/(\d+)-(\d+):(\d+)/.exec(a)
    ad[0]=lrc.wordPer(word,ad[1]-1)
    ad[1]=lrc.wordPer(word,ad[2]*1)
    ad[2]=ad[3]
   }
   else{
    ad=/(\d+):(.+)/.exec(a)
    ad[0]=lrc.wordPer(word,ad[1]-1)
    ad[1]=lrc.wordPer(word,ad[1]*1)
   }
   len1+=(ad[1]-ad[0])*(ad[2]-1)
   o.path.add(ad)
  }
  o.zoom=1/len1
}
}
function browser_ini(){
window.isIE=navigator.userAgent.indexOf("IE")>0
window.isIE5=navigator.userAgent.indexOf("IE 5.0")>0
String.prototype.trim=function(){return this.replace(/(^[\s]*)|([\s]*$)/g,"")}
String.prototype.inc=function(s1,s2){if(s2==null){s2=","};return (s2+this+s2).indexOf(s2+s1+s2)>-1?true:false}
String.prototype._slice="".slice
String.prototype.slice=function(n1,n2){var v,b1=typeof(n1)=="number",b2=typeof(n2)=="number";if(!b1||typeof(n2)=="string"){v=eval("this._slice("+(b1?n1:this.indexOf(n1)+(n2==null?1:0)+(this.indexOf(n1)==-1?this.length:0))+(n2==null?"":(b2?n2:(this.indexOf(n2)==-1?"":","+this.indexOf(n2))))+")")}else{v=isIE5&&n1<0&&n2==null?this._slice(this.length-1):eval("this._slice(n1"+(n2==null?"":","+n2)+")")}return v}
String.prototype.get=function(str,def){if(this.inc(str,";"))return 1;var a=this.match(new RegExp("(^|;)"+str+":[^;]*"));return a==null||str==""?(def==null?"":def):a[0].replace(";","").slice(str.length+1)}
Array.prototype.add=function(key){this[this.length]=key}
window.oo=function(obj){return typeof(obj)=="string"?document.getElementById(obj):obj}
window.insHtm=function(op,html,inEnd){op=oo(op);if(isIE){op.insertAdjacentHTML(inEnd==null?"beforeend":"afterbegin",html)}else{var r=op.ownerDocument.createRange();r.setStartBefore(op);eval("op."+(inEnd==null?"appendChild":"insertBefore")+"(r.createContextualFragment(html),op.firstChild)");}}
window.odel=function(obj){if(oo(obj)!=null){oo(obj).parentNode.removeChild(oo(obj))}}
if(!isIE){
     HTMLElement.prototype.contains=function(node){if(!node)return false;do if(node==this){return true}while(node=node.parentNode){return false}}
  Event.prototype.__defineGetter__("srcElement",function(){var node=this.target;while(node.nodeType!=1){node=node.parentNode}return node})
  Event.prototype.__defineGetter__("toElement",function(){return this.relatedTarget})
}
}
function timer_ini(){
window.timer={}
timer.handle=null
timer.queue=""
timer.i=0
timer.add=function(key){if(!timer.queue.inc(key,";")){timer.queue+=key+";"}}
timer.del=function(key){timer.queue=move.queue.replace(key+";","")}
timer.inv=function(){
  window.clearTimeout(timer.handle)
  eval(timer.queue)
  timer.i++
  timer.handle=window.setTimeout("timer.inv()",10)
}
timer.inv()
}
function sortFoo(v1,v2){
    var s1=v1.split("|")[sortIndex],s2=v2.split("|")[sortIndex]
    if(!isNaN(s1)&&!isNaN(s2)){
  s1*=1
  s2*=1   }
return (s1==s2?0:(s1>s2?1:-1))*sortDir
}
</scr ipt>

回复 使用道具


 楼主| 发表于 2008-6-29 14:35 | 显示全部楼层
替换红色部分文件地址
回复 使用道具


 楼主| 发表于 2008-6-29 14:38 | 显示全部楼层
在记事本中编辑好保存后的格式默认为.TXT
回复 使用道具


 楼主| 发表于 2008-6-29 14:39 | 显示全部楼层
回复 使用道具


 楼主| 发表于 2008-6-29 14:47 | 显示全部楼层
代码修改介绍

 

 

http://l.99081.com/jf0523/音画/红尘(歌词).txt

 

(一)帖子背景图片更改:注意宽度和高度要与替换图片一样

 

<table border="0" width="960" id="table1" height="720">
<tr>
<td align="center" width="960" background="http://www.bbsman.com/attachments/forumid_94/20080623_00807fb6a8f78ebb1114mALDi581UrOA.jpg">


 

回复 使用道具


甘首五朝臣

发表于 2008-6-29 14:52 | 显示全部楼层

回复 7# 的帖子

:victory :)
回复 使用道具


畅意三江水

发表于 2008-7-1 12:55 | 显示全部楼层
代码中有图片呢 怎么这么多代码啊
回复 使用道具


发表于 2008-7-1 13:12 | 显示全部楼层
好教材挂起来~~~~有啥不明白的大家跟帖向我们的东方总版请教~~~~~~~:victory :victory
"轻轻的我走了,正如我轻轻的来;悄悄的我走了,正如我悄悄的来;我挥一挥衣袖,不带走一片云彩"
回复 使用道具

您需要登录后才可以回帖 登录 | 注册

本版积分规则

九月家园

GMT+8, 2024-5-30 07:49

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表