Please login or register.

Login with username, password and session length
Advanced search  

News:

Forum rules - please read before posting, it can save you a lot of time.

Author Topic: lip synch  (Read 8519 times)

0 Members and 1 Guest are viewing this topic.

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
lip synch
« on: May 21, 2007, 10:49:17 PM »

I know there's a topic on this, but I read it and I don't understand it.  Could you be a little more specific about how the phonemes are used and the text file for them, etc?  I forgot what program you were set up for also.  I plan to use a different one, I know, but maybe I can figure out some conversion.  I don't suppose there's a sample somewhere.
« Last Edit: May 21, 2007, 11:04:03 PM by fireside »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: lip synch
« Reply #1 on: May 22, 2007, 09:49:28 AM »

The basic idea was to define WME's talk stances representing phonemes. E.g. you'd have stances called "a", "o", "e" ... for your actor. Now the lipsync software would break the sound down to a bunch of phonems, which you'd convert to a single string ("a,e,e,e,a,o") and pass to the Talk method.
Alternatively you could use the (undocumented) .Talk files. In any way, you'd need to further process the output of your lipsync software, either to generate the .Talk file, or the sequence of phonemes to be used as talk stances.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #2 on: May 22, 2007, 01:50:24 PM »

How would the timings work? You know like "this phoneme for this long".  Where would I put the talk stances?  I know where you put the general talk animation, but these would be individual stances? Would I make individual sprites for each stance?  Let's say I had to say "hi", in the middle of a sound file 2 seconds long.  So you wait 1.2 seconds, say "h" for .2 seconds and "i" for .3 seconds, and close mouth the rest.  How would you set that up?
« Last Edit: May 22, 2007, 02:07:20 PM by fireside »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: lip synch
« Reply #3 on: May 22, 2007, 07:36:54 PM »

Yeah, the stances wouldn't work well, unless the phonemes in the stream all used the same length (and you'd have a special "empty" phoneme for composing pauses). The .talk files are more flexible, but harder to generate.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #4 on: May 22, 2007, 08:40:19 PM »

Quote
TALK
{
  DEFAULT_SPRITE = "actors\molly\talk.sprite"
  ACTION
  {
    START_TIME = 2000
    END_TIME = 3500
    SPRITE = "actors\molly\some_gesture.sprite"
  }
 
}

Hm, I think I understand now.  Duh.  I'm really a dope with this stuff some times.  I string the times like this, right?
{
     START_TIME = 2000
    END_TIME = 3500
    SPRITE = "actors\molly\some_gesture.sprite"
    START_TIME = 3500
    END_TIME = 4500
    SPRITE = "actors\molly\another_gesture.sprite"
}

So I could maybe write a python program that reads the file and writes this.  I think I  could do that.  I'll set up a test and try it.  Sorry I'm so slow at obvious things sometimes.  I don't know what causes that. 
« Last Edit: May 22, 2007, 08:49:19 PM by fireside »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: lip synch
« Reply #5 on: May 22, 2007, 08:45:20 PM »

More like this:

Code: [Select]
ACTION
{
  START_TIME = 2000
  END_TIME = 3500
  SPRITE = "actors\molly\some_gesture.sprite"
}
ACTION
{
  START_TIME = 3500
  END_TIME = 4500
  SPRITE = "actors\molly\another_gesture.sprite"
}
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #6 on: May 22, 2007, 08:50:23 PM »

O.K.  Thanks.  I'll set up a test.
Logged

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #7 on: May 24, 2007, 01:12:11 AM »

I'll have to check further, but right now there seems to be a sizable delay between action calls.
Code: [Select]
TALK
{
  DEFAULT_SPRITE = "actors\molly\dd\stand.sprite"
  ACTION
  {
    START_TIME = 1227
    END_TIME = 1485
    SPRITE = "actors\molly\dd\mouth_open.sprite"
  }
    ACTION
  {
    START_TIME = 1485
    END_TIME = 1550
    SPRITE = "actors\molly\dd\mouth_open.sprite"
  }
 
}

This should look like the mouth opens and stays open, but it doesn't.  The mouth opens, closes and opens again.  The timing on one syllable in sound file seems accurate.  I'll have to try a sentence and see what happens.
« Last Edit: May 24, 2007, 01:16:40 AM by fireside »
Logged

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #8 on: May 24, 2007, 03:25:25 PM »

It seems to match up fairly well on a full sentence, but always jumps back to the default after an action instead of sliding into the next phoneme.  It makes complete sense for a body gesture, but doesn't work well for speech. Even a body gesture, though, you would probably want to bring it back to the default position with an animation.
« Last Edit: May 24, 2007, 04:35:26 PM by fireside »
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: lip synch
« Reply #9 on: May 24, 2007, 05:53:40 PM »

I tried it and it seems to work ok. Make sure the mouth_open.sprite is Looping, otherwise it's possible it would end prematurely.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #10 on: May 24, 2007, 07:16:00 PM »

Yeah, that's what it was.  Thanks. I forget to click that on a single frame.  It's clicked by default but I can't quite get the idea of a single frame needing looping so I un-check it.
It should work great then.  Now to write a little parser thingy.
« Last Edit: May 24, 2007, 08:07:02 PM by fireside »
Logged

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #11 on: May 25, 2007, 06:14:47 PM »

By the way, in case anyone else is interested, I downloaded the automatic phoneme placer from here:
http://www.annosoft.com/sapi_lipsync/docs/

You have to download sapi from Microsoft, but it's free.  It's a little confusing but there is a binary in the folder and you just run it from console, so you don't have to compile it or anything.
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: lip synch
« Reply #12 on: May 26, 2007, 08:50:28 AM »

It looks like an interesting tool. Thanks for the link.
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

fireside

  • Supporter
  • Regular poster
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 211
    • View Profile
Re: lip synch
« Reply #13 on: May 26, 2007, 09:39:45 PM »

You're welcome.  I wrote a little python interpreter thing and it works excellent. 
Logged
 

Page created in 0.189 seconds with 23 queries.