const
  cNumberCount = 2;

function Filter(AItem: TImageItem): Boolean;
var
  AProps: TCatalogItemProps;
  ACatItem: TCatalogItem;
begin
  result := False;

  ACatItem := TCatalogItem.Create(nil);
  if PublicCatalog.FindItemCombinedByGUID(AItem.GUID, ACatItem) then
  begin
    AProps := TCatalogItemProps.Create(TCatalogItemProp, '');
    PublicCatalog.EnumPropsInParentForItem(ACatItem, PeopleGUID, AProps, True, True, True, True, -1);
    result := (AProps.Count = cNumberCount);
    AProps.Free;
  end;
  ACatItem.Free;
end;
