Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
d4ded92b
Commit
d4ded92b
authored
Nov 26, 2020
by
Zebediah Figura
Committed by
Alexandre Julliard
Nov 27, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qcap: Move v4l2 support to a new Unix library.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
8bcb4466
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
20 additions
and
16 deletions
+20
-16
qcap_main.c
dlls/qcap/qcap_main.c
+1
-1
qcap_private.h
dlls/qcap/qcap_private.h
+2
-2
v4l.c
dlls/qcap/v4l.c
+14
-11
vfwcapture.c
dlls/qcap/vfwcapture.c
+3
-2
No files found.
dlls/qcap/qcap_main.c
View file @
d4ded92b
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
qcap
);
WINE_DEFAULT_DEBUG_CHANNEL
(
qcap
);
static
HINSTANCE
qcap_instance
;
HINSTANCE
qcap_instance
;
static
LONG
objects_ref
=
0
;
static
LONG
objects_ref
=
0
;
...
...
dlls/qcap/qcap_private.h
View file @
d4ded92b
...
@@ -30,6 +30,8 @@
...
@@ -30,6 +30,8 @@
#include "wine/strmbase.h"
#include "wine/strmbase.h"
#include "wine/unicode.h"
#include "wine/unicode.h"
extern
HINSTANCE
qcap_instance
DECLSPEC_HIDDEN
;
extern
DWORD
ObjectRefCount
(
BOOL
increment
)
DECLSPEC_HIDDEN
;
extern
DWORD
ObjectRefCount
(
BOOL
increment
)
DECLSPEC_HIDDEN
;
HRESULT
audio_record_create
(
IUnknown
*
outer
,
IUnknown
**
out
)
DECLSPEC_HIDDEN
;
HRESULT
audio_record_create
(
IUnknown
*
outer
,
IUnknown
**
out
)
DECLSPEC_HIDDEN
;
...
@@ -59,6 +61,4 @@ struct video_capture_funcs
...
@@ -59,6 +61,4 @@ struct video_capture_funcs
BOOL
(
*
read_frame
)(
struct
video_capture_device
*
device
,
BYTE
*
data
);
BOOL
(
*
read_frame
)(
struct
video_capture_device
*
device
,
BYTE
*
data
);
};
};
extern
const
struct
video_capture_funcs
v4l_funcs
;
#endif
#endif
dlls/qcap/v4l.c
View file @
d4ded92b
...
@@ -19,6 +19,10 @@
...
@@ -19,6 +19,10 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#if 0
#pragma makedep unix
#endif
#define BIONIC_IOCTL_NO_SIGNEDNESS_OVERLOAD
/* work around ioctl breakage on Android */
#define BIONIC_IOCTL_NO_SIGNEDNESS_OVERLOAD
/* work around ioctl breakage on Android */
#include "config.h"
#include "config.h"
...
@@ -47,7 +51,11 @@
...
@@ -47,7 +51,11 @@
#include <unistd.h>
#include <unistd.h>
#endif
#endif
#include "ntstatus.h"
#define WIN32_NO_STATUS
#include "initguid.h"
#include "qcap_private.h"
#include "qcap_private.h"
#include "winternl.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
qcap
);
WINE_DEFAULT_DEBUG_CHANNEL
(
qcap
);
...
@@ -558,17 +566,12 @@ const struct video_capture_funcs v4l_funcs =
...
@@ -558,17 +566,12 @@ const struct video_capture_funcs v4l_funcs =
.
read_frame
=
v4l_device_read_frame
,
.
read_frame
=
v4l_device_read_frame
,
};
};
#else
NTSTATUS
CDECL
__wine_init_unix_lib
(
HMODULE
module
,
DWORD
reason
,
const
void
*
ptr_in
,
void
*
ptr_out
)
static
struct
video_capture_device
*
v4l_device_create
(
USHORT
index
)
{
{
ERR
(
"v4l2 was not present at compilation time.
\n
"
);
if
(
reason
!=
DLL_PROCESS_ATTACH
)
return
STATUS_SUCCESS
;
return
NULL
;
}
const
struct
video_capture_funcs
v4l_funcs
=
*
(
const
struct
video_capture_funcs
**
)
ptr_out
=
&
v4l_funcs
;
{
return
STATUS_SUCCESS
;
.
create
=
v4l_device_create
,
}
};
#endif
/*
defined(VIDIOCMCAPTURE)
*/
#endif
/*
HAVE_LINUX_VIDEODEV2_H
*/
dlls/qcap/vfwcapture.c
View file @
d4ded92b
...
@@ -19,6 +19,7 @@
...
@@ -19,6 +19,7 @@
*/
*/
#include "qcap_private.h"
#include "qcap_private.h"
#include "winternl.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
qcap
);
WINE_DEFAULT_DEBUG_CHANNEL
(
qcap
);
...
@@ -839,7 +840,7 @@ static const IAMVideoControlVtbl IAMVideoControl_VTable =
...
@@ -839,7 +840,7 @@ static const IAMVideoControlVtbl IAMVideoControl_VTable =
static
BOOL
WINAPI
load_capture_funcs
(
INIT_ONCE
*
once
,
void
*
param
,
void
**
context
)
static
BOOL
WINAPI
load_capture_funcs
(
INIT_ONCE
*
once
,
void
*
param
,
void
**
context
)
{
{
capture_funcs
=
&
v4l_funcs
;
__wine_init_unix_lib
(
qcap_instance
,
DLL_PROCESS_ATTACH
,
NULL
,
&
capture_funcs
)
;
return
TRUE
;
return
TRUE
;
}
}
...
@@ -850,7 +851,7 @@ HRESULT vfw_capture_create(IUnknown *outer, IUnknown **out)
...
@@ -850,7 +851,7 @@ HRESULT vfw_capture_create(IUnknown *outer, IUnknown **out)
static
const
WCHAR
source_name
[]
=
{
'O'
,
'u'
,
't'
,
'p'
,
'u'
,
't'
,
0
};
static
const
WCHAR
source_name
[]
=
{
'O'
,
'u'
,
't'
,
'p'
,
'u'
,
't'
,
0
};
struct
vfw_capture
*
object
;
struct
vfw_capture
*
object
;
if
(
!
InitOnceExecuteOnce
(
&
init_once
,
load_capture_funcs
,
NULL
,
NULL
))
if
(
!
InitOnceExecuteOnce
(
&
init_once
,
load_capture_funcs
,
NULL
,
NULL
)
||
!
capture_funcs
)
return
E_FAIL
;
return
E_FAIL
;
if
(
!
(
object
=
CoTaskMemAlloc
(
sizeof
(
*
object
))))
if
(
!
(
object
=
CoTaskMemAlloc
(
sizeof
(
*
object
))))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment