reimar
3b34c55178
Avoid memleaks when vo_direct3d initialization fails.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30191 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-01-03 17:04:04 +00:00
reimar
f31ed10742
Modify -vo direct3d so we do not have to link against d3d9.dll, it might
...
not be available on some rare systems.
Based on patch used for builds by Gianluigi Tiesi [sherpya netfarm it]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30190 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-01-03 17:00:51 +00:00
reimar
01ef7e4579
Extend calc_src_dst_rects to also calculate the border values needed for
...
correctly placed dvdnav highlights, and fix direct3d and vdpau accordingly.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28633 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-17 11:59:49 +00:00
reimar
694c3dc03f
Add a calc_src_dst_rects that calculates from window size, panscan etc.
...
which part of the video source must be scaled onto which part of the window.
Direct3D and (future) VDPAU need this, for XvMC it makes it easier to add
cropping support and Xv is changed to keep the diff to XvMC small.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28546 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-12 17:40:53 +00:00
gogothebee
ff0c8c1e35
Avoid message spam during video adapter uncooperative state.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28469 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-05 09:07:58 +00:00
gogothebee
680578839d
Unify info/error messages to a common style:
...
<vo_direct3d> in the beginning, "." at the end.
Shorter/more descriptive sentences.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28468 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-05 09:06:09 +00:00
reimar
0fcb101267
Add checks that a D3D device is available before attempting rendering.
...
We may have lost the device e.g. because it became uncooperative e.g.
when using remote desktop or Vista's UAC is activated.
Patch by Georgi Petrov [gogothebee gmail com]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28457 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-03 11:00:09 +00:00
reimar
cd8ef8a8f6
Remove the Present call after adapter reinitialization, it can not work anyway
...
since no video frame is uploaded to the new context yet.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28456 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-03 10:54:27 +00:00
reimar
680eb1a1e4
Cosmetics: remove empty line, improve some messages.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28454 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-03 10:21:17 +00:00
reimar
fbac650de3
Whitespace/comment typo cosmetics.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28453 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-03 10:17:14 +00:00
reimar
af87ab3afd
Check for change_d3d_backbuffer failure.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28452 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-03 10:16:03 +00:00
reimar
ad8c8f6f28
Fix several return values
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28451 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-02-03 10:14:44 +00:00
reimar
7fcf438a2f
Allocate a larger backbuffer to allow resizing without reinit.
...
Patch by Georgi Petrov [gogothebee gmail com] and Jim Hauxwell [james (at) dattrax co uk]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28379 b3059339-0415-0410-9bf9-f77b7e298cf2
2009-01-27 10:02:47 +00:00
reimar
98d227c9fd
Set d3d_handle to NULL after release.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28121 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-09 18:44:48 +00:00
reimar
d0952d0b19
Forgotten part of previous cosmetics commit
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28120 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-09 18:41:41 +00:00
reimar
6f621f00d8
Slightly simplify the conditional release/free code
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28119 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-09 18:36:15 +00:00
reimar
1dd432665e
First version of OSD support for vo_direct3d
...
Patch by Jim Hauxwell [james dattrax co uk] with modifications by me
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28118 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-09 18:31:52 +00:00
diego
a9c80bee77
cosmetics: indentation
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28113 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-08 11:30:43 +00:00
reimar
38005bd941
Remove pointless or even wrong N/A return values doxy comments
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28112 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-08 11:04:27 +00:00
reimar
2b12cb43f1
Fix indentation.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28076 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-03 12:22:32 +00:00
reimar
27b167bb75
Remove resize_d3d call from render_d3d_frame that was made useless
...
by previous commit. If this is necessary e.g. to prevent flicker
while resizing, check_events should be called instead or even
better the functionality be moved to some higher layer.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28065 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-02 15:03:19 +00:00
reimar
bb89a7696d
100l, do not call check_events from resize_d3d since there should be
...
no reason to do it and it might call resize_d3d again which makes it
hard to guarantee that it works correctly.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28064 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-02 14:51:46 +00:00
reimar
2d330d3c01
Cosmetics: Remove unnecessary ()
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28063 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-02 09:46:08 +00:00
reimar
ef4313fd77
Consistency cosmetics: do not compare against NULL in ifs
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28062 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-02 09:40:09 +00:00
reimar
e84d33f00f
Cosmetics: remove spaces before argument (
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28061 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-02 09:38:24 +00:00
reimar
bbc8a57160
Reorganize Direct3D initialization code.
...
Patch by Georgi Petrov [gogothebee gmail com]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28060 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-12-02 09:36:47 +00:00
diego
5e2bec3344
whitespace cosmetics: prettyprinting and indentation
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28045 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-28 09:24:20 +00:00
reimar
669b0697b0
Use D3DFMT_ constants where possible instead of MAKEFOURCC
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28041 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-26 16:30:42 +00:00
reimar
513bd7461d
Add support for RGB formats to vo_direct3d
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28040 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-26 16:27:39 +00:00
reimar
2c6a12c01d
Remove a ColorFill that is not necessary since the surface it is used
...
on has exactly the same size as the video image and the video will
be copied into it before it is used the first time.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28019 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-24 09:46:23 +00:00
reimar
5cb896b7eb
Make sure the backbuffer is cleared when the border size might have changed.
...
Patch by Georgi Petrov [gogothebee gmail com]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28018 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-24 09:44:33 +00:00
reimar
97eeb07265
Patch to improve/consistify coding style.
...
Patch by Georgi Petrov [gogothebee gmail com]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28005 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-23 18:50:39 +00:00
reimar
d86a77d8ba
Fix indentation
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28004 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-23 18:45:01 +00:00
reimar
cc7e0dae7e
Lock/unlock surface only once even when drawing many slices.
...
Patch originally by Jim Hauxwell [james dattrax co.uk]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28003 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-23 18:42:29 +00:00
reimar
161092eb35
Move locked_rect from stack to priv struct in preparation for following patch.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28002 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-23 18:24:53 +00:00
reimar
e148ffb3ec
Move the StretchRect call from draw_slices to render_d3d_frame.
...
This avoids calling it (and BeginScene/EndScene) many times with
slices and also avoids code duplication.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28001 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-23 18:13:56 +00:00
reimar
2e5c6e2f4e
Remove pointless is_cfG_finished variable.
...
Patch by Georgi Petrov [gogothebee gmail com]
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28000 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-23 17:25:46 +00:00
reimar
157343aeb3
Fix and enable panscan handling for vo_direct3d
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27971 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-21 12:22:16 +00:00
reimar
f525ba25e7
Cosmetics: rename variables etc. in vo_direct3d.c
...
Patch by Georgi Petrov (gogothebee gmail com)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27962 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-20 15:13:14 +00:00
reimar
82e0e9055a
Simplify conditions in direct3d vo: remove == 1, change == 0 to ! etc.
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27959 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-19 13:39:07 +00:00
reimar
0ebdbc02d8
Add missing "static" qualifiers to vo_direct3d
...
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27957 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-18 14:51:54 +00:00
reimar
af366bff51
Direct3D based video_out module.
...
Patch by Georgi Petrov (gogothebee gmail com)
Panscan handling is still disabled and needs to be fixed for negative
-panscan.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27955 b3059339-0415-0410-9bf9-f77b7e298cf2
2008-11-18 12:23:42 +00:00