WME 9 video freezing
WMPTalk.com Forum Index WMPTalk.com
Discuss Windows Media Player
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web wmptalk.com
WME 9 video freezing

 
Post new topic   Reply to topic    WMPTalk.com Forum Index -> Encoders
Author Message
Neil
Guest





Posted: Fri Apr 22, 2005 5:31 am    Post subject: WME 9 video freezing Reply with quote

We stream 24/7 and since upgrading windows 2003 server with service pack 1 we
are finding our wme9 encoder freezes the video randomly. The audio is not
effected. Is anyone else finding this and is there a patch to fix.
Thanks
Neil

Back to top
robudzi
Guest





Posted: Tue May 31, 2005 4:30 pm    Post subject: RE: WME 9 video freezing Reply with quote

I have a identical problem, you find someting about this?????? I found out
that WME9 does not work well with WDM drives, it's true????
thank's

Robudzi
--
wme


"Neil" wrote:

Quote:
We stream 24/7 and since upgrading windows 2003 server with service pack 1 we
are finding our wme9 encoder freezes the video randomly. The audio is not
effected. Is anyone else finding this and is there a patch to fix.
Thanks
Neil
Back to top
jj_in_atlanta
Guest





Posted: Wed Aug 31, 2005 5:51 am    Post subject: RE: WME 9 video freezing Reply with quote

I had written an encoding application that used System.Timers (in c#) - when
we upgraded the servers from W2003 to SP1 the timers quit working after
running many hours - it was because of some sort of bug with the timers. I
had to write my own timing method that used System.Threading.thread.sleep(x)
http://arje.net/halcyon_days_of_system.threading.timer

Though that problem has been resolved, I now am having problems with the
calls to wmencoder.stop not returning once the service has been running
several hours.

"robudzi" wrote:

Quote:
I have a identical problem, you find someting about this?????? I found out
that WME9 does not work well with WDM drives, it's true????
thank's

Robudzi
--
wme


"Neil" wrote:

We stream 24/7 and since upgrading windows 2003 server with service pack 1 we
are finding our wme9 encoder freezes the video randomly. The audio is not
effected. Is anyone else finding this and is there a patch to fix.
Thanks
Neil


Back to top
Neil Smith [MVP Digital M
Guest





Posted: Wed Aug 31, 2005 8:30 am    Post subject: Re: WME 9 video freezing Reply with quote

On Tue, 30 Aug 2005 17:51:49 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

Quote:
I had written an encoding application that used System.Timers (in c#) - when
we upgraded the servers from W2003 to SP1 the timers quit working after
running many hours - it was because of some sort of bug with the timers. I
had to write my own timing method that used System.Threading.thread.sleep(x)
http://arje.net/halcyon_days_of_system.threading.timer

Though that problem has been resolved, I now am having problems with the
calls to wmencoder.stop not returning once the service has been running
several hours.

The encoder can take a significant amount of time to "stop" as it has
to release device resources, close files and so on. Are you expecting
it to return immediately ? It won't.

You'll need to ensure you check the RunState asynchronously after
calling the Encoder.Stop(). The RunState values available include

WMENC_ENCODER_RUNNING = 2
WMENC_ENCODER_STOPPING = 4
WMENC_ENCODER_STOPPED = 5

HTH
Cheers - Neil
Back to top
jj_in_atlanta
Guest





Posted: Wed Aug 31, 2005 4:30 pm    Post subject: Re: WME 9 video freezing Reply with quote

My app runs synchronously - so I call Encoder.Stop() and wait for it to
return before continuning:

Encoder.Stop()
// Never get to this line //

It usually happens when the app has been runing for between 15 - 20 hours -
(15-20 stops/starts on each of the 3 encoder cards in the servers)

ViewCast suggested I destroy and re-create the Encoder objects every so
often, but when I do that 4 or 5 times, I run out of memory - I suppose
because some of the Windows Media Encoder COM objects aren't releasing their
memory

More suggestions??

Thanks

PS: I'm programming in c#, .Net v1.1

"Neil Smith [MVP Digital Media]" wrote:

Quote:
On Tue, 30 Aug 2005 17:51:49 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

I had written an encoding application that used System.Timers (in c#) - when
we upgraded the servers from W2003 to SP1 the timers quit working after
running many hours - it was because of some sort of bug with the timers. I
had to write my own timing method that used System.Threading.thread.sleep(x)
http://arje.net/halcyon_days_of_system.threading.timer

Though that problem has been resolved, I now am having problems with the
calls to wmencoder.stop not returning once the service has been running
several hours.

The encoder can take a significant amount of time to "stop" as it has
to release device resources, close files and so on. Are you expecting
it to return immediately ? It won't.

You'll need to ensure you check the RunState asynchronously after
calling the Encoder.Stop(). The RunState values available include

WMENC_ENCODER_RUNNING = 2
WMENC_ENCODER_STOPPING = 4
WMENC_ENCODER_STOPPED = 5

HTH
Cheers - Neil

Back to top
Neil Smith [MVP Digital M
Guest





Posted: Wed Aug 31, 2005 8:30 pm    Post subject: Re: WME 9 video freezing Reply with quote

On Wed, 31 Aug 2005 06:38:13 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

Quote:
My app runs synchronously - so I call Encoder.Stop() and wait for it to
return before continuning:

Encoder.Stop()
// Never get to this line //

I suppose the problem is, that the encoder *isn't* a synchronous
program - most windows programs aren't, they are event driven.

I think you'll have to ~find a way~ to make your app respond to async
events. The event which triggers when the encoder changes state is
_IWMEncoderEvents::OnStateChange

So you need to add an event handler for that, and when the return
values is WMENC_ENCODER_STOPPED, you can take your relevant actions.

Quote:
It usually happens when the app has been runing for between 15 - 20 hours -
(15-20 stops/starts on each of the 3 encoder cards in the servers)

ViewCast suggested I destroy and re-create the Encoder objects every so
often, but when I do that 4 or 5 times, I run out of memory - I suppose
because some of the Windows Media Encoder COM objects aren't releasing their
memory

Yes I think I've read about that before. I'm not sure what the cause
is though. Is it possible it's driver dependent - i.e. do you see the
memory leak when encoding from a different device for a long time ?

This is an example of a documented memory leak caused by OHCI
http://support.microsoft.com/default.aspx?scid=kb;EN-US;Q260055

Quote:
More suggestions??

Sorry, I'm out of suggestios ! Perhaps you could ask in the
microsoft.public.windowsmedia.sdk newsgroup and see if anybody has any
better ideas.

HTH
Cheers - Neil

Quote:
Thanks

PS: I'm programming in c#, .Net v1.1

"Neil Smith [MVP Digital Media]" wrote:

On Tue, 30 Aug 2005 17:51:49 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

I had written an encoding application that used System.Timers (in c#) - when
we upgraded the servers from W2003 to SP1 the timers quit working after
running many hours - it was because of some sort of bug with the timers. I
had to write my own timing method that used System.Threading.thread.sleep(x)
http://arje.net/halcyon_days_of_system.threading.timer

Though that problem has been resolved, I now am having problems with the
calls to wmencoder.stop not returning once the service has been running
several hours.

The encoder can take a significant amount of time to "stop" as it has
to release device resources, close files and so on. Are you expecting
it to return immediately ? It won't.

You'll need to ensure you check the RunState asynchronously after
calling the Encoder.Stop(). The RunState values available include

WMENC_ENCODER_RUNNING = 2
WMENC_ENCODER_STOPPING = 4
WMENC_ENCODER_STOPPED = 5

HTH
Cheers - Neil

Back to top
jj_in_atlanta
Guest





Posted: Thu Sep 15, 2005 8:30 pm    Post subject: Re: WME 9 video freezing Reply with quote

After inspecting my code very closely for memory leaks, and using
ReleaseComObject every 1000 recording cycles, the problem of the the memory
leak and not returning from wmencoder.stop appears to have abated.

I'm having one other problem, which I've had all along, that I'll mention in
the event I still have your attention.

Occassionally, the file for an hour isn't recorded properly - the file will
be about 20K, and will give an error when I try to view it. I don't see any
unexpected events or errors in my logging - my code starts the encoder, sees
the state change from stopped..starting..running, then, at the end of the
hour, state goes from running..Stopping..stopped and the recording session
ends without error. But, the file is tiny (~20KB) and won't open.

This is happening on 26 different servers. I get failures about 1% of the
time, and I can't determine a pattern. I don't think I've seen this fail 2
times on the same server/card in a row yet.

I've ran NTFileMon watching for this, and when it occurs, nothing is written
to the file after the recording starts, until the recording stops.

Every hear of anything like this?


Thanks

"Neil Smith [MVP Digital Media]" wrote:

Quote:
On Wed, 31 Aug 2005 06:38:13 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

My app runs synchronously - so I call Encoder.Stop() and wait for it to
return before continuning:

Encoder.Stop()
// Never get to this line //

I suppose the problem is, that the encoder *isn't* a synchronous
program - most windows programs aren't, they are event driven.

I think you'll have to ~find a way~ to make your app respond to async
events. The event which triggers when the encoder changes state is
_IWMEncoderEvents::OnStateChange

So you need to add an event handler for that, and when the return
values is WMENC_ENCODER_STOPPED, you can take your relevant actions.

It usually happens when the app has been runing for between 15 - 20 hours -
(15-20 stops/starts on each of the 3 encoder cards in the servers)

ViewCast suggested I destroy and re-create the Encoder objects every so
often, but when I do that 4 or 5 times, I run out of memory - I suppose
because some of the Windows Media Encoder COM objects aren't releasing their
memory

Yes I think I've read about that before. I'm not sure what the cause
is though. Is it possible it's driver dependent - i.e. do you see the
memory leak when encoding from a different device for a long time ?

This is an example of a documented memory leak caused by OHCI
http://support.microsoft.com/default.aspx?scid=kb;EN-US;Q260055

More suggestions??

Sorry, I'm out of suggestios ! Perhaps you could ask in the
microsoft.public.windowsmedia.sdk newsgroup and see if anybody has any
better ideas.

HTH
Cheers - Neil

Thanks

PS: I'm programming in c#, .Net v1.1

"Neil Smith [MVP Digital Media]" wrote:

On Tue, 30 Aug 2005 17:51:49 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

I had written an encoding application that used System.Timers (in c#) - when
we upgraded the servers from W2003 to SP1 the timers quit working after
running many hours - it was because of some sort of bug with the timers. I
had to write my own timing method that used System.Threading.thread.sleep(x)
http://arje.net/halcyon_days_of_system.threading.timer

Though that problem has been resolved, I now am having problems with the
calls to wmencoder.stop not returning once the service has been running
several hours.

The encoder can take a significant amount of time to "stop" as it has
to release device resources, close files and so on. Are you expecting
it to return immediately ? It won't.

You'll need to ensure you check the RunState asynchronously after
calling the Encoder.Stop(). The RunState values available include

WMENC_ENCODER_RUNNING = 2
WMENC_ENCODER_STOPPING = 4
WMENC_ENCODER_STOPPED = 5

HTH
Cheers - Neil



Back to top
Neil Smith [MVP Digital M
Guest





Posted: Fri Sep 16, 2005 12:30 am    Post subject: Re: WME 9 video freezing Reply with quote

On Thu, 15 Sep 2005 09:43:02 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

Quote:
Occassionally, the file for an hour isn't recorded properly - the file will
be about 20K, and will give an error when I try to view it. I don't see any
unexpected events or errors in my logging - my code starts the encoder, sees
the state change from stopped..starting..running, then, at the end of the
hour, state goes from running..Stopping..stopped and the recording session
ends without error. But, the file is tiny (~20KB) and won't open.

This is happening on 26 different servers. I get failures about 1% of the
time, and I can't determine a pattern. I don't think I've seen this fail 2
times on the same server/card in a row yet.

Yes, I've seen it too, but I can't remember the cause, sorry.

Cheers - Neil
Back to top
jj_in_atlanta
Guest





Posted: Fri Sep 16, 2005 4:30 pm    Post subject: Re: WME 9 video freezing Reply with quote

Well, if you remember or hear of anyone who's figured this out, please post
about it. I'll do the same.

Thanks

"Neil Smith [MVP Digital Media]" wrote:

Quote:
On Thu, 15 Sep 2005 09:43:02 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

Occassionally, the file for an hour isn't recorded properly - the file will
be about 20K, and will give an error when I try to view it. I don't see any
unexpected events or errors in my logging - my code starts the encoder, sees
the state change from stopped..starting..running, then, at the end of the
hour, state goes from running..Stopping..stopped and the recording session
ends without error. But, the file is tiny (~20KB) and won't open.

This is happening on 26 different servers. I get failures about 1% of the
time, and I can't determine a pattern. I don't think I've seen this fail 2
times on the same server/card in a row yet.

Yes, I've seen it too, but I can't remember the cause, sorry.

Cheers - Neil
Back to top
Red66
Guest





Posted: Wed Sep 21, 2005 8:30 pm    Post subject: Re: WME 9 video freezing Reply with quote

JJ, we'd like to contact you regarding your encoding application - we're
looking for something similar and ours is giving us lots of trouble. If
interested, please contact me at:

msnewsgroup A T carlanga D O T com

Thanks.


"jj_in_atlanta" <jj in atlanta@yahoo.com> escribió en el mensaje
news:2F0580FE-BA2B-40DF-B354-D7A16B1D8EF3@microsoft.com...
Quote:
Well, if you remember or hear of anyone who's figured this out, please
post
about it. I'll do the same.

Thanks

"Neil Smith [MVP Digital Media]" wrote:

On Thu, 15 Sep 2005 09:43:02 -0700, "jj_in_atlanta" <jj in
atlanta@yahoo.com> wrote:

Occassionally, the file for an hour isn't recorded properly - the file
will
be about 20K, and will give an error when I try to view it. I don't see
any
unexpected events or errors in my logging - my code starts the encoder,
sees
the state change from stopped..starting..running, then, at the end of
the
hour, state goes from running..Stopping..stopped and the recording
session
ends without error. But, the file is tiny (~20KB) and won't open.

This is happening on 26 different servers. I get failures about 1% of
the
time, and I can't determine a pattern. I don't think I've seen this
fail 2
times on the same server/card in a row yet.

Yes, I've seen it too, but I can't remember the cause, sorry.

Cheers - Neil
Back to top
MPEGeek



Joined: 29 Nov 2005
Posts: 1

Posted: Tue Nov 29, 2005 7:33 pm    Post subject: re:WME 9 video freezing Reply with quote

I'm a newbie to this forum, and so my comments may be a day late/dollar short.

We saw the same issue - the encoder would stream for about 10 minutes and the video would go to black, but the audio kept on streaming normally. Viewcast made a fix to one of the very earliest releases of the WDM driver. Prior to the release they did recommend using the 2x (VFW) drivers as a work-around.

I do not remember the particulars of the problem, but I do remember that the explanation was quite technical and so the answer was much bigger than the question! :D Anyway, since we've had the new drivers it works flawlessly. We've streamed for weeks on end 24/7 without any problem. This fix was made more than a year ago so whatever is the current driver version on the Viewcast web site should have this fix.

I should also mention that we use the stand-alone Windows Media Encoder application, and not a custom one built with the WM SDK.
Back to top
View user's profile Send private message
 
Post new topic   Reply to topic    WMPTalk.com Forum Index -> Encoders All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Microsoft Office Forum New Topics
Powered by phpBB