mirror of
https://github.com/brunoherbelin/vimix.git
synced 2025-12-12 02:40:00 +01:00
Fixed Frame grabber
This commit is contained in:
@@ -341,7 +341,7 @@ void FrameGrabber::addFrame (GstBuffer *buffer, GstCaps *caps)
|
|||||||
t = gst_clock_get_time(timer_) - timer_firstframe_;
|
t = gst_clock_get_time(timer_) - timer_firstframe_;
|
||||||
|
|
||||||
// if time is zero (first frame) or if delta time is passed one frame duration (with a margin)
|
// if time is zero (first frame) or if delta time is passed one frame duration (with a margin)
|
||||||
if ( t == 0 || (t - timestamp_) > (frame_duration_ - 3000) ) {
|
if ( t == 0 || (t - duration_) > (frame_duration_ - 3000) ) {
|
||||||
|
|
||||||
// count frames
|
// count frames
|
||||||
frame_count_++;
|
frame_count_++;
|
||||||
@@ -399,7 +399,7 @@ void FrameGrabber::addFrame (GstBuffer *buffer, GstCaps *caps)
|
|||||||
stop();
|
stop();
|
||||||
// inform
|
// inform
|
||||||
Log::Info("Frame capture : Unnexpected EOF signal (no space left on drive? File deleted?)");
|
Log::Info("Frame capture : Unnexpected EOF signal (no space left on drive? File deleted?)");
|
||||||
Log::Warning("Frame capture : failed after %s.", GstToolkit::time_to_string(duration_, GstToolkit::TIME_STRING_READABLE).c_str());
|
Log::Warning("Frame capture : Failed after %s.", GstToolkit::time_to_string(duration_, GstToolkit::TIME_STRING_READABLE).c_str());
|
||||||
}
|
}
|
||||||
// terminate properly if finished
|
// terminate properly if finished
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user