Matt Rogers schrieb:
> On Thursday 14 January 2010 13:32:44 Frank Schaefer wrote:
>   
>> Hi,
>>
>> I finally finished working on a series of patches for kopete's
>> webcam-code, which I think should be applied to the 4.4-branch.
>> They fix a number of issues with
>> - loading/saving of the video-settings
>> - device registering + unregistering + switching
>> - device input switching
>> - GUI-elements in the video-settings-dialog (bug 188177)
>>
>> See the a short summary about what they and why below.
>> The first 6 patches are basically what I've already put on the
>>  review-board. I decided to split them up to make reviewing easier.
>>  However, patch 6 ist still complex. Feel free to ask questions.
>>
>> All patches apply from Kopetes' root-directory with "patch -p1 <
>>  patchfile".
>>
>> Even if you do/can not comment the code-changes, please test them and
>> report problems.
>>
>> Thanks,
>> Frank
>>
>>
>> #######################################
>>
>> PATCH 1:
>> Fix loading of video-setting "Mirror image"
>>
>> Fixes a typo in videodevicepool::loadConfiguration().
>> ----------------------------------------------------------------------
>> PACTH 2:
>> Fix loading of video-setting "Whitebalance"
>>
>> Add code-line for applying the whitebalance-setting after loading it.
>> Also fix the standard value for this setting.
>> ----------------------------------------------------------------------
>> PATCH 3:
>> videodevicepool: decrease model-count in the model-pool when devices are
>> removed
>>
>> This fixes a bug which causes the wrong device number to be used when
>> video-settings are saved in some cases.
>> ----------------------------------------------------------------------
>> PATCH 4:
>> Video-settings (videodevicepool): do not save device automatically when
>> open() is called with a device parameter
>>
>> With the current code, always the last selected device is saved in the
>> video-settings-dialog, even if the settings-changes are cancled/not
>>  applied. Restoring the initial value in the settings-dialog would be very
>>  complex and video-settings should only be saved by calling
>> videodevicepool::saveConfig() explicitly.
>> ----------------------------------------------------------------------
>> PATCH 5:
>> Video-settings (videodevicepool): fix nr. of clients in case of
>> device-removal and failed open()
>>
>> Set nr. of clients to 0 when the device is removed.
>> Do not increase the nr. of clients if open() fails.
>>
>> The current code causes video-settings not to be saved in some cases
>> (when devices are plugged in for the second time).
>> ----------------------------------------------------------------------
>> PATCH 6:
>> Video-settings (videodevicepool): fix workflow during device-open
>>
>> Fixes
>> - loading of the saved device
>> - closing of the current device before opening a new device
>> - handling of multiple clients
>>
>> With the current code, always the device with index 0 is used regardless
>> of what has been saved.
>> This happens, because the video-settings are loaded AFTER the device is
>> opened.
>> Because the video-settings (options, values for the controls) must be
>> applied witch an open device, the only solution is to split the
>> loadConfig()-function and into two functions:
>> - loadSelectedDevice() => applied before the device is opened to set the
>> right device-index
>> - loadDeviceConfig()   => applied after the device has been successfully
>> opened to set the video-settings
>>
>> With the current workflow during device-open (open(int device) calls
>> open()), we do not know if the device is selected explicitly or the
>> default device should be opened.
>> Because of that, merge open() and open(ind device), using negative
>> parameters for selecting the standard/saved device (defualt=-1).
>> This way, we also fix handling of multiple clients for a device and
>> closing of the previous device (which do not work in several cases with
>> the current code).
>> ----------------------------------------------------------------------
>> PATCH 7:
>> Fix device-removal in video-settings-dialog
>>
>> - stop polling frames from removed device
>> - remove unregistered/removed devices from the selection-combobox
>> - switch to another device (if available) and start capturing
>> ----------------------------------------------------------------------
>> PATCH 8:
>> Fix device-switching in video-settings-dialog
>>
>> Stop capturing from current device and close it before switching to the
>> new device
>> This fixes the following issues:
>> - device-switching not working / hanging devices
>> - settings-loading not working after switching to a device for the
>> second time (because of >1 clients in videodevicepool)
>> ----------------------------------------------------------------------
>> PATCH 9:
>> Fix device-input-switching in video-settings-dialog
>>
>> On most (all ?) devices, the V4L2-ioctl returns EBUSY when trying to
>> switch the input while device is streaming.
>> Fix it by stopping capturing before switching the input and restarting
>> capturing afterwards.
>> ----------------------------------------------------------------------
>> PATCH 10:
>> Video-settings-dialog: disable comboboxes if no device available
>> BUG: 188177
>> ----------------------------------------------------------------------
>> PATCH 11:
>> Video-settings-dialog: disable "Controls"- and "Options"-tabs if no
>> device available
>> BUG: 188177
>> ----------------------------------------------------------------------
>>
>>     
>
> All look fine. Please commit.
>   

Committed. I already ported some of these changes to the trunk, too.

Thanks,
Frank
_______________________________________________
kopete-devel mailing list
kopete-devel@kde.org
https://mail.kde.org/mailman/listinfo/kopete-devel

Reply via email to