fixed kinect issue and ignorting fps in opencvlux plugin
authorKevron Rees <kevron_m_rees@linux.intel.com>
Thu, 21 Mar 2013 21:01:59 +0000 (14:01 -0700)
committerKevron Rees <kevron_m_rees@linux.intel.com>
Thu, 21 Mar 2013 21:01:59 +0000 (14:01 -0700)
plugins/opencvlux/opencvluxplugin.cpp

index 9bfcc70..025a8b5 100644 (file)
@@ -126,7 +126,7 @@ void OpenCvLuxPlugin::getPropertyAsync(AsyncPropertyReply *reply)
                /// we want to turn on the camera for one shot to get an image and determine the intensity
 
                if(init())
-                       g_timeout_add(1,grabImage,shared);
+                       grabImage(shared);
        }
 
        if(reply->property == VehicleProperty::ExteriorBrightness)
@@ -196,11 +196,11 @@ static int grabImage(void *data)
        else
        {
                *(shared->m_capture) >> m_image;
+       }
 
-               uint lux = evalImage(m_image,shared);
+       uint lux = evalImage(m_image,shared);
 
-               shared->parent->updateProperty(lux);
-       }
+       shared->parent->updateProperty(lux);
 
        if(shared->mRequests.size())
        {