winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
March 2018
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
785 discussions
Start a n
N
ew thread
Henri Verbeet : wined3d: Pass a texture and sub-resource index to surface_load_drawable().
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 798439ba31ee155f88b25f31bcd13f7bcf078698 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=798439ba31ee155f88b25f31…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Mar 6 10:26:29 2018 +0330 wined3d: Pass a texture and sub-resource index to surface_load_drawable(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 10 +++++----- dlls/wined3d/texture.c | 2 +- dlls/wined3d/wined3d_private.h | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 24d1f59..1824a98 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -2106,12 +2106,11 @@ BOOL texture2d_load_sysmem(struct wined3d_texture *texture, unsigned int sub_res } /* Context activation is done by the caller. */ -BOOL surface_load_drawable(struct wined3d_surface *surface, - struct wined3d_context *context) +BOOL texture2d_load_drawable(struct wined3d_texture *texture, + unsigned int sub_resource_idx, struct wined3d_context *context) { - unsigned int sub_resource_idx = surface_get_sub_resource_idx(surface); - struct wined3d_texture *texture = surface->container; struct wined3d_surface *restore_rt = NULL; + struct wined3d_surface *surface; struct wined3d_device *device; unsigned int level; RECT r; @@ -2127,11 +2126,12 @@ BOOL surface_load_drawable(struct wined3d_surface *surface, if (wined3d_settings.offscreen_rendering_mode == ORM_FBO && wined3d_resource_is_offscreen(&texture->resource)) { - ERR("Trying to load offscreen surface into WINED3D_LOCATION_DRAWABLE.\n"); + ERR("Trying to load offscreen texture into WINED3D_LOCATION_DRAWABLE.\n"); return FALSE; } device = texture->resource.device; + surface = texture->sub_resources[sub_resource_idx].u.surface; restore_rt = context_get_rt_surface(context); if (restore_rt != surface) context = context_acquire(device, texture, sub_resource_idx); diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 0368550..9add4a3 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -1806,7 +1806,7 @@ static BOOL texture2d_load_location(struct wined3d_texture *texture, unsigned in return texture2d_load_sysmem(texture, sub_resource_idx, context, location); case WINED3D_LOCATION_DRAWABLE: - return surface_load_drawable(surface, context); + return texture2d_load_drawable(texture, sub_resource_idx, context); case WINED3D_LOCATION_RB_RESOLVED: case WINED3D_LOCATION_RB_MULTISAMPLE: diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index f0e7680..d2addfb 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -3234,6 +3234,8 @@ static inline unsigned int wined3d_texture_get_level_pow2_height(const struct wi return max(1, texture->pow2_height >> level); } +BOOL texture2d_load_drawable(struct wined3d_texture *texture, unsigned int sub_resource_idx, + struct wined3d_context *context) DECLSPEC_HIDDEN; BOOL texture2d_load_sysmem(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_context *context, DWORD dst_location) DECLSPEC_HIDDEN; @@ -3340,8 +3342,6 @@ static inline struct wined3d_texture_sub_resource *surface_get_sub_resource(stru HRESULT wined3d_surface_blt(struct wined3d_surface *dst_surface, const RECT *dst_rect, struct wined3d_surface *src_surface, const RECT *src_rect, DWORD flags, const struct wined3d_blt_fx *blt_fx, enum wined3d_texture_filter_type filter) DECLSPEC_HIDDEN; -BOOL surface_load_drawable(struct wined3d_surface *surface, - struct wined3d_context *context) DECLSPEC_HIDDEN; void surface_load_fb_texture(struct wined3d_surface *surface, BOOL srgb, struct wined3d_context *context) DECLSPEC_HIDDEN; BOOL surface_load_renderbuffer(struct wined3d_surface *surface,
1
0
0
0
Henri Verbeet : wined3d: Pass a texture and sub-resource index to surface_load_sysmem().
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 3b47e108a91cefc8dc781e771d6dcda4fc286906 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3b47e108a91cefc8dc781e77…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Mar 6 10:26:28 2018 +0330 wined3d: Pass a texture and sub-resource index to surface_load_sysmem(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 16 +++++++--------- dlls/wined3d/texture.c | 2 +- dlls/wined3d/wined3d_private.h | 5 +++-- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 23d7ae7..24d1f59 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -2060,12 +2060,10 @@ static HRESULT surface_blt_special(struct wined3d_surface *dst_surface, const RE } /* Context activation is done by the caller. */ -BOOL surface_load_sysmem(struct wined3d_surface *surface, +BOOL texture2d_load_sysmem(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_context *context, DWORD dst_location) { - unsigned int sub_resource_idx = surface_get_sub_resource_idx(surface); const struct wined3d_gl_info *gl_info = context->gl_info; - struct wined3d_texture *texture = surface->container; struct wined3d_texture_sub_resource *sub_resource; sub_resource = &texture->sub_resources[sub_resource_idx]; @@ -2075,7 +2073,7 @@ BOOL surface_load_sysmem(struct wined3d_surface *surface, if (is_multisample_location(texture, WINED3D_LOCATION_TEXTURE_RGB)) { wined3d_texture_load_location(texture, sub_resource_idx, context, WINED3D_LOCATION_RB_RESOLVED); - read_from_framebuffer(surface, context, WINED3D_LOCATION_RB_RESOLVED, dst_location); + read_from_framebuffer(sub_resource->u.surface, context, WINED3D_LOCATION_RB_RESOLVED, dst_location); return TRUE; } else @@ -2083,12 +2081,12 @@ BOOL surface_load_sysmem(struct wined3d_surface *surface, if (sub_resource->locations & (WINED3D_LOCATION_RB_MULTISAMPLE | WINED3D_LOCATION_RB_RESOLVED)) wined3d_texture_load_location(texture, sub_resource_idx, context, WINED3D_LOCATION_TEXTURE_RGB); - /* Download the surface to system memory. */ + /* Download the sub-resource to system memory. */ if (sub_resource->locations & (WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB)) { wined3d_texture_bind_and_dirtify(texture, context, !(sub_resource->locations & WINED3D_LOCATION_TEXTURE_RGB)); - surface_download_data(surface, gl_info, dst_location); + surface_download_data(sub_resource->u.surface, gl_info, dst_location); ++texture->download_count; return TRUE; @@ -2098,12 +2096,12 @@ BOOL surface_load_sysmem(struct wined3d_surface *surface, if (!(texture->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) && (sub_resource->locations & WINED3D_LOCATION_DRAWABLE)) { - read_from_framebuffer(surface, context, texture->resource.draw_binding, dst_location); + read_from_framebuffer(sub_resource->u.surface, context, texture->resource.draw_binding, dst_location); return TRUE; } - FIXME("Can't load surface %p with location flags %s into sysmem.\n", - surface, wined3d_debug_location(sub_resource->locations)); + FIXME("Can't load texture %p, %u with location flags %s into sysmem.\n", + texture, sub_resource_idx, wined3d_debug_location(sub_resource->locations)); return FALSE; } diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 72aee66..0368550 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -1803,7 +1803,7 @@ static BOOL texture2d_load_location(struct wined3d_texture *texture, unsigned in case WINED3D_LOCATION_USER_MEMORY: case WINED3D_LOCATION_SYSMEM: case WINED3D_LOCATION_BUFFER: - return surface_load_sysmem(surface, context, location); + return texture2d_load_sysmem(texture, sub_resource_idx, context, location); case WINED3D_LOCATION_DRAWABLE: return surface_load_drawable(surface, context); diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 6d2ff8e..f0e7680 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -3234,6 +3234,9 @@ static inline unsigned int wined3d_texture_get_level_pow2_height(const struct wi return max(1, texture->pow2_height >> level); } +BOOL texture2d_load_sysmem(struct wined3d_texture *texture, unsigned int sub_resource_idx, + struct wined3d_context *context, DWORD dst_location) DECLSPEC_HIDDEN; + void wined3d_texture_apply_sampler_desc(struct wined3d_texture *texture, const struct wined3d_sampler_desc *sampler_desc, const struct wined3d_context *context) DECLSPEC_HIDDEN; void wined3d_texture_bind(struct wined3d_texture *texture, @@ -3343,8 +3346,6 @@ void surface_load_fb_texture(struct wined3d_surface *surface, BOOL srgb, struct wined3d_context *context) DECLSPEC_HIDDEN; BOOL surface_load_renderbuffer(struct wined3d_surface *surface, struct wined3d_context *context, DWORD dst_location) DECLSPEC_HIDDEN; -BOOL surface_load_sysmem(struct wined3d_surface *surface, - struct wined3d_context *context, DWORD dst_location) DECLSPEC_HIDDEN; BOOL surface_load_texture(struct wined3d_surface *surface, struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; void wined3d_surface_upload_data(struct wined3d_texture *texture, unsigned int sub_resource_idx,
1
0
0
0
Henri Verbeet : wined3d: Merge surface_load_location() into texture2d_load_location().
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: c1f5b9ac67b5dbed71d4a32a8d3d833d39a0dc1a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c1f5b9ac67b5dbed71d4a32a…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Mar 6 10:26:27 2018 +0330 wined3d: Merge surface_load_location() into texture2d_load_location(). Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/surface.c | 40 +++++----------------------------------- dlls/wined3d/texture.c | 31 ++++++++++++++++++++++++++++++- dlls/wined3d/wined3d_private.h | 10 ++++++++-- 3 files changed, 43 insertions(+), 38 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 5a2bf52..23d7ae7 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -2060,7 +2060,7 @@ static HRESULT surface_blt_special(struct wined3d_surface *dst_surface, const RE } /* Context activation is done by the caller. */ -static BOOL surface_load_sysmem(struct wined3d_surface *surface, +BOOL surface_load_sysmem(struct wined3d_surface *surface, struct wined3d_context *context, DWORD dst_location) { unsigned int sub_resource_idx = surface_get_sub_resource_idx(surface); @@ -2108,7 +2108,7 @@ static BOOL surface_load_sysmem(struct wined3d_surface *surface, } /* Context activation is done by the caller. */ -static BOOL surface_load_drawable(struct wined3d_surface *surface, +BOOL surface_load_drawable(struct wined3d_surface *surface, struct wined3d_context *context) { unsigned int sub_resource_idx = surface_get_sub_resource_idx(surface); @@ -2155,7 +2155,7 @@ static BOOL surface_load_drawable(struct wined3d_surface *surface, return TRUE; } -static BOOL surface_load_texture(struct wined3d_surface *surface, +BOOL surface_load_texture(struct wined3d_surface *surface, struct wined3d_context *context, BOOL srgb) { unsigned int width, height, level, src_row_pitch, src_slice_pitch, dst_row_pitch, dst_slice_pitch; @@ -2326,8 +2326,8 @@ static BOOL surface_load_texture(struct wined3d_surface *surface, } /* Context activation is done by the caller. */ -static BOOL surface_load_renderbuffer(struct wined3d_surface *surface, struct wined3d_context *context, - DWORD dst_location) +BOOL surface_load_renderbuffer(struct wined3d_surface *surface, + struct wined3d_context *context, DWORD dst_location) { struct wined3d_texture *texture = surface->container; unsigned int level = surface_get_sub_resource_idx(surface) % texture->level_count; @@ -2359,36 +2359,6 @@ static BOOL surface_load_renderbuffer(struct wined3d_surface *surface, struct wi return TRUE; } -/* Context activation is done by the caller. Context may be NULL in ddraw-only mode. */ -BOOL surface_load_location(struct wined3d_surface *surface, struct wined3d_context *context, DWORD location) -{ - TRACE("surface %p, location %s.\n", surface, wined3d_debug_location(location)); - - switch (location) - { - case WINED3D_LOCATION_USER_MEMORY: - case WINED3D_LOCATION_SYSMEM: - case WINED3D_LOCATION_BUFFER: - return surface_load_sysmem(surface, context, location); - - case WINED3D_LOCATION_DRAWABLE: - return surface_load_drawable(surface, context); - - case WINED3D_LOCATION_RB_RESOLVED: - case WINED3D_LOCATION_RB_MULTISAMPLE: - return surface_load_renderbuffer(surface, context, location); - - case WINED3D_LOCATION_TEXTURE_RGB: - case WINED3D_LOCATION_TEXTURE_SRGB: - return surface_load_texture(surface, context, - location == WINED3D_LOCATION_TEXTURE_SRGB); - - default: - ERR("Don't know how to handle location %#x.\n", location); - return FALSE; - } -} - /* Context activation is done by the caller. */ static void fbo_blitter_destroy(struct wined3d_blitter *blitter, struct wined3d_context *context) { diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 8c03331..72aee66 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -1788,10 +1788,39 @@ static void texture2d_upload_data(struct wined3d_texture *texture, unsigned int texture->resource.format, &src_rect, row_pitch, &dst_point, FALSE, data); } +/* Context activation is done by the caller. Context may be NULL in ddraw-only mode. */ static BOOL texture2d_load_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_context *context, DWORD location) { - return surface_load_location(texture->sub_resources[sub_resource_idx].u.surface, context, location); + struct wined3d_surface *surface; + + TRACE("texture %p, sub_resource_idx %u, context %p, location %s.\n", + texture, sub_resource_idx, context, wined3d_debug_location(location)); + + surface = texture->sub_resources[sub_resource_idx].u.surface; + switch (location) + { + case WINED3D_LOCATION_USER_MEMORY: + case WINED3D_LOCATION_SYSMEM: + case WINED3D_LOCATION_BUFFER: + return surface_load_sysmem(surface, context, location); + + case WINED3D_LOCATION_DRAWABLE: + return surface_load_drawable(surface, context); + + case WINED3D_LOCATION_RB_RESOLVED: + case WINED3D_LOCATION_RB_MULTISAMPLE: + return surface_load_renderbuffer(surface, context, location); + + case WINED3D_LOCATION_TEXTURE_RGB: + case WINED3D_LOCATION_TEXTURE_SRGB: + return surface_load_texture(surface, context, + location == WINED3D_LOCATION_TEXTURE_SRGB); + + default: + ERR("Don't know how to handle location %#x.\n", location); + return FALSE; + } } /* Context activation is done by the caller. */ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index d7895b5..6d2ff8e 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -3337,10 +3337,16 @@ static inline struct wined3d_texture_sub_resource *surface_get_sub_resource(stru HRESULT wined3d_surface_blt(struct wined3d_surface *dst_surface, const RECT *dst_rect, struct wined3d_surface *src_surface, const RECT *src_rect, DWORD flags, const struct wined3d_blt_fx *blt_fx, enum wined3d_texture_filter_type filter) DECLSPEC_HIDDEN; +BOOL surface_load_drawable(struct wined3d_surface *surface, + struct wined3d_context *context) DECLSPEC_HIDDEN; void surface_load_fb_texture(struct wined3d_surface *surface, BOOL srgb, struct wined3d_context *context) DECLSPEC_HIDDEN; -BOOL surface_load_location(struct wined3d_surface *surface, - struct wined3d_context *context, DWORD location) DECLSPEC_HIDDEN; +BOOL surface_load_renderbuffer(struct wined3d_surface *surface, + struct wined3d_context *context, DWORD dst_location) DECLSPEC_HIDDEN; +BOOL surface_load_sysmem(struct wined3d_surface *surface, + struct wined3d_context *context, DWORD dst_location) DECLSPEC_HIDDEN; +BOOL surface_load_texture(struct wined3d_surface *surface, + struct wined3d_context *context, BOOL srgb) DECLSPEC_HIDDEN; void wined3d_surface_upload_data(struct wined3d_texture *texture, unsigned int sub_resource_idx, const struct wined3d_gl_info *gl_info, const struct wined3d_format *format, const RECT *src_rect, unsigned int src_pitch, const POINT *dst_point, BOOL srgb,
1
0
0
0
Henri Verbeet : wined3d: Store the EXT_fbo "renderbuffers" list in the texture instead of the surface.
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 3d21ea0807a95f504f2bef102e447a40e61c0c0d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3d21ea0807a95f504f2bef10…
Author: Henri Verbeet <hverbeet(a)codeweavers.com> Date: Tue Mar 6 10:26:26 2018 +0330 wined3d: Store the EXT_fbo "renderbuffers" list in the texture instead of the surface. Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/context.c | 23 +++---- dlls/wined3d/surface.c | 84 ------------------------ dlls/wined3d/texture.c | 146 +++++++++++++++++++++++++++++++---------- dlls/wined3d/wined3d_private.h | 10 +-- 4 files changed, 125 insertions(+), 138 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=3d21ea0807a95f504f2b…
1
0
0
0
Michael Stefaniuc : dmstyle/tests: Avoid a clang warning.
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 6fd5bce038789aac2312ac3b5347ba4f81371685 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6fd5bce038789aac2312ac3b…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Tue Mar 6 01:07:27 2018 +0100 dmstyle/tests: Avoid a clang warning. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dmstyle/tests/dmstyle.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/dmstyle/tests/dmstyle.c b/dlls/dmstyle/tests/dmstyle.c index a9a89a7..ed12315 100644 --- a/dlls/dmstyle/tests/dmstyle.c +++ b/dlls/dmstyle/tests/dmstyle.c @@ -356,13 +356,13 @@ struct chunk { followed by the chunks of the list and terminated with 0. */ static IStream *gen_riff_stream(const FOURCC *ids) { + static const LARGE_INTEGER zero; int level = -1; DWORD *sizes[4]; /* Stack for the sizes of RIFF and LIST chunks */ char riff[1024]; char *p = riff; struct chunk *ck; IStream *stream; - LARGE_INTEGER zero = {0}; do { ck = (struct chunk *)p;
1
0
0
0
Michael Stefaniuc : dmloader/tests: Add IDirectMusicObject:: ParseDescriptor() tests.
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 9e74cdc6397a79e7ca671eab5b3ac9393455077b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=9e74cdc6397a79e7ca671eab…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Tue Mar 6 01:07:26 2018 +0100 dmloader/tests: Add IDirectMusicObject::ParseDescriptor() tests. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dmloader/tests/loader.c | 204 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 204 insertions(+) diff --git a/dlls/dmloader/tests/loader.c b/dlls/dmloader/tests/loader.c index ff084b6..46e46d4 100644 --- a/dlls/dmloader/tests/loader.c +++ b/dlls/dmloader/tests/loader.c @@ -19,11 +19,14 @@ #define COBJMACROS #include "initguid.h" +#include <ole2.h> #include "dmusici.h" +#include <dmusicf.h> #include "wine/test.h" #define ARRAY_SIZE(a) (sizeof(a)/sizeof((a)[0])) +DEFINE_GUID(GUID_NULL,0,0,0,0,0,0,0,0,0,0,0); static unsigned char mp3file[] = "\xFF\xFB\x92\x04"; /* MP3 header */ static unsigned char rifffile[8+4+8+16+8+256] = "RIFF\x24\x01\x00\x00WAVE" /* header: 4 ("WAVE") + (8 + 16) (format segment) + (8 + 256) (data segment) = 0x124 */ "fmt \x10\x00\x00\x00\x01\x00\x20\x00\xAC\x44\x00\x00\x10\xB1\x02\x00\x04\x00\x10\x00" /* format segment: PCM, 2 chan, 44100 Hz, 16 bits */ @@ -391,6 +394,205 @@ static void test_container(void) while (IDirectMusicContainer_Release(dmc)); } +struct chunk { + FOURCC id; + DWORD size; + FOURCC type; +}; + +#define CHUNK_HDR_SIZE (sizeof(FOURCC) + sizeof(DWORD)) + +/* Generate a RIFF file format stream from an array of FOURCC ids. + RIFF and LIST need to be followed by the form type respectively list type, + followed by the chunks of the list and terminated with 0. */ +static IStream *gen_riff_stream(const FOURCC *ids) +{ + static const LARGE_INTEGER zero; + int level = -1; + DWORD *sizes[4]; /* Stack for the sizes of RIFF and LIST chunks */ + char riff[1024]; + char *p = riff; + struct chunk *ck; + IStream *stream; + + do { + ck = (struct chunk *)p; + ck->id = *ids++; + switch (ck->id) { + case 0: + *sizes[level] = p - (char *)sizes[level] - sizeof(DWORD); + level--; + break; + case FOURCC_LIST: + case FOURCC_RIFF: + level++; + sizes[level] = &ck->size; + ck->type = *ids++; + p += sizeof(*ck); + break; + case DMUS_FOURCC_GUID_CHUNK: + ck->size = sizeof(GUID_NULL); + p += CHUNK_HDR_SIZE; + memcpy(p, &GUID_NULL, sizeof(GUID_NULL)); + p += ck->size; + break; + case DMUS_FOURCC_VERSION_CHUNK: + { + DMUS_VERSION ver = {5, 8}; + + ck->size = sizeof(ver); + p += CHUNK_HDR_SIZE; + memcpy(p, &ver, sizeof(ver)); + p += ck->size; + break; + } + default: + { + /* Just convert the FOURCC id to a WCHAR string */ + WCHAR *s; + + ck->size = 5 * sizeof(WCHAR); + p += CHUNK_HDR_SIZE; + s = (WCHAR *)p; + s[0] = (char)(ck->id); + s[1] = (char)(ck->id >> 8); + s[2] = (char)(ck->id >> 16); + s[3] = (char)(ck->id >> 24); + s[4] = 0; + p += ck->size; + } + } + } while (level >= 0); + + ck = (struct chunk *)riff; + CreateStreamOnHGlobal(NULL, TRUE, &stream); + IStream_Write(stream, riff, ck->size + CHUNK_HDR_SIZE, NULL); + IStream_Seek(stream, zero, STREAM_SEEK_SET, NULL); + + return stream; +} + +static void test_parsedescriptor(void) +{ + IDirectMusicObject *dmo; + IStream *stream; + DMUS_OBJECTDESC desc; + HRESULT hr; + DWORD valid; + const WCHAR s_unam[] = {'U','N','A','M','\0'}; + const FOURCC alldesc[] = + { + FOURCC_RIFF, DMUS_FOURCC_CONTAINER_FORM, DMUS_FOURCC_CATEGORY_CHUNK, FOURCC_LIST, + DMUS_FOURCC_UNFO_LIST, DMUS_FOURCC_UNAM_CHUNK, DMUS_FOURCC_UCOP_CHUNK, + DMUS_FOURCC_UCMT_CHUNK, DMUS_FOURCC_USBJ_CHUNK, 0, DMUS_FOURCC_VERSION_CHUNK, + DMUS_FOURCC_GUID_CHUNK, 0 + }; + const FOURCC dupes[] = + { + FOURCC_RIFF, DMUS_FOURCC_CONTAINER_FORM, DMUS_FOURCC_CATEGORY_CHUNK, + DMUS_FOURCC_CATEGORY_CHUNK, DMUS_FOURCC_VERSION_CHUNK, DMUS_FOURCC_VERSION_CHUNK, + DMUS_FOURCC_GUID_CHUNK, DMUS_FOURCC_GUID_CHUNK, FOURCC_LIST, DMUS_FOURCC_UNFO_LIST, + DMUS_FOURCC_UNAM_CHUNK, 0, FOURCC_LIST, DMUS_FOURCC_UNFO_LIST, mmioFOURCC('I','N','A','M'), + 0, 0 + }; + FOURCC empty[] = {FOURCC_RIFF, DMUS_FOURCC_CONTAINER_FORM, 0}; + FOURCC inam[] = + { + FOURCC_RIFF, DMUS_FOURCC_CONTAINER_FORM, FOURCC_LIST, DMUS_FOURCC_UNFO_LIST, + mmioFOURCC('I','N','A','M'), 0, 0 + }; + + hr = CoCreateInstance(&CLSID_DirectMusicContainer, NULL, CLSCTX_INPROC_SERVER, + &IID_IDirectMusicObject, (void **)&dmo); + ok(hr == S_OK, "DirectMusicContainer create failed: %08x, expected S_OK\n", hr); + + /* Nothing loaded */ + memset(&desc, 0, sizeof(desc)); + hr = IDirectMusicObject_GetDescriptor(dmo, &desc); + ok(hr == S_OK, "GetDescriptor failed: %08x, expected S_OK\n", hr); + ok(desc.dwValidData == DMUS_OBJ_CLASS /* XP */ || + broken(desc.dwValidData == (DMUS_OBJ_OBJECT | DMUS_OBJ_CLASS)), /* Vista and above */ + "Got valid data %#x, expected DMUS_OBJ_OBJECT\n", desc.dwValidData); + ok(IsEqualGUID(&desc.guidClass, &CLSID_DirectMusicContainer), + "Got class guid %s, expected CLSID_DirectMusicContainer\n", + wine_dbgstr_guid(&desc.guidClass)); + + /* Empty RIFF stream */ + stream = gen_riff_stream(empty); + memset(&desc, 0, sizeof(desc)); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + ok(hr == E_INVALIDARG, "ParseDescriptor failed: %08x, expected E_INVALIDARG\n", hr); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + ok(desc.dwValidData == DMUS_OBJ_CLASS, "Got valid data %#x, expected DMUS_OBJ_CLASS\n", + desc.dwValidData); + ok(IsEqualGUID(&desc.guidClass, &CLSID_DirectMusicContainer), + "Got class guid %s, expected CLSID_DirectMusicContainer\n", + wine_dbgstr_guid(&desc.guidClass)); + IStream_Release(stream); + + /* Wrong form */ + empty[1] = DMUS_FOURCC_SEGMENT_FORM; + stream = gen_riff_stream(empty); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + todo_wine ok(hr == DMUS_E_DESCEND_CHUNK_FAIL, + "ParseDescriptor failed: %08x, expected DMUS_E_DESCEND_CHUNK_FAIL\n", hr); + + /* All desc chunks */ + stream = gen_riff_stream(alldesc); + memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + valid = DMUS_OBJ_OBJECT|DMUS_OBJ_CLASS|DMUS_OBJ_NAME|DMUS_OBJ_CATEGORY|DMUS_OBJ_VERSION; + ok(desc.dwValidData == valid, "Got valid data %#x, expected %#x\n", desc.dwValidData, valid); + ok(IsEqualGUID(&desc.guidClass, &CLSID_DirectMusicContainer), + "Got class guid %s, expected CLSID_DirectMusicContainer\n", + wine_dbgstr_guid(&desc.guidClass)); + ok(IsEqualGUID(&desc.guidObject, &GUID_NULL), "Got object guid %s, expected GUID_NULL\n", + wine_dbgstr_guid(&desc.guidClass)); + ok(!memcmp(desc.wszName, s_unam, sizeof(s_unam)), "Got name '%s', expected 'UNAM'\n", + wine_dbgstr_w(desc.wszName)); + IStream_Release(stream); + + /* UNFO list with INAM */ + inam[3] = DMUS_FOURCC_UNFO_LIST; + stream = gen_riff_stream(inam); + memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + todo_wine ok(desc.dwValidData == DMUS_OBJ_CLASS, "Got valid data %#x, expected DMUS_OBJ_CLASS\n", + desc.dwValidData); + IStream_Release(stream); + + /* INFO list with INAM */ + inam[3] = DMUS_FOURCC_INFO_LIST; + stream = gen_riff_stream(inam); + memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + ok(desc.dwValidData == DMUS_OBJ_CLASS, "Got valid data %#x, expected DMUS_OBJ_CLASS\n", + desc.dwValidData); + IStream_Release(stream); + + /* Duplicated chunks */ + stream = gen_riff_stream(dupes); + memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + valid = DMUS_OBJ_OBJECT|DMUS_OBJ_CLASS|DMUS_OBJ_NAME|DMUS_OBJ_CATEGORY|DMUS_OBJ_VERSION; + ok(desc.dwValidData == valid, "Got valid data %#x, expected %#x\n", desc.dwValidData, valid); + todo_wine ok(!memcmp(desc.wszName, s_unam, sizeof(s_unam)), "Got name '%s', expected 'UNAM'\n", + wine_dbgstr_w(desc.wszName)); + IStream_Release(stream); + + IDirectMusicObject_Release(dmo); +} + START_TEST(loader) { CoInitialize(NULL); @@ -408,5 +610,7 @@ START_TEST(loader) test_COM(); test_COM_container(); test_container(); + test_parsedescriptor(); + CoUninitialize(); }
1
0
0
0
Michael Stefaniuc : dmusic/tests: Check forms 'DMAP' and 'DMTG' in ParseDescriptor too.
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 07fd2ef37261a2f11a014acf6a395c70817dd7dc URL:
https://source.winehq.org/git/wine.git/?a=commit;h=07fd2ef37261a2f11a014acf…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Tue Mar 6 01:07:25 2018 +0100 dmusic/tests: Check forms 'DMAP' and 'DMTG' in ParseDescriptor too. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dmime/tests/dmime.c | 75 ++++++++++++++++++++++++++++++++---------------- 1 file changed, 51 insertions(+), 24 deletions(-) diff --git a/dlls/dmime/tests/dmime.c b/dlls/dmime/tests/dmime.c index b7b8095..1438a8d 100644 --- a/dlls/dmime/tests/dmime.c +++ b/dlls/dmime/tests/dmime.c @@ -723,71 +723,94 @@ static void test_parsedescriptor(void) }; FOURCC empty[] = {FOURCC_RIFF, ~0, 0}; FOURCC inam[] = {FOURCC_RIFF, ~0, FOURCC_LIST, ~0, mmioFOURCC('I','N','A','M'), 0, 0}; -#define X(form) form, #form +#define X(class) &CLSID_ ## class, #class +#define Y(form) form, #form const struct { + REFCLSID clsid; + const char *class; FOURCC form; const char *name; + BOOL needs_size; } forms[] = { - { X(DMUS_FOURCC_SEGMENT_FORM) }, - { X(mmioFOURCC('W','A','V','E')) }, + { X(DirectMusicSegment), Y(DMUS_FOURCC_SEGMENT_FORM), FALSE }, + { X(DirectMusicSegment), Y(mmioFOURCC('W','A','V','E')), FALSE }, + { X(DirectMusicAudioPathConfig), Y(DMUS_FOURCC_AUDIOPATH_FORM), TRUE }, + { X(DirectMusicGraph), Y(DMUS_FOURCC_TOOLGRAPH_FORM), TRUE }, }; #undef X +#undef Y - hr = CoCreateInstance(&CLSID_DirectMusicSegment, NULL, CLSCTX_INPROC_SERVER, - &IID_IDirectMusicObject, (void **)&dmo); - if (hr != S_OK) { - win_skip("Could not create DirectMusicSegment object: %08x\n", hr); - return; - } for (i = 0; i < ARRAY_SIZE(forms); i++) { - trace("Testing %s\n", forms[i].name); + trace("Testing %s / %s\n", forms[i].class, forms[i].name); + hr = CoCreateInstance(forms[i].clsid, NULL, CLSCTX_INPROC_SERVER, &IID_IDirectMusicObject, + (void **)&dmo); + if (hr != S_OK) { + win_skip("Could not create %s object: %08x\n", forms[i].class, hr); + return; + } /* Nothing loaded */ memset(&desc, 0, sizeof(desc)); hr = IDirectMusicObject_GetDescriptor(dmo, &desc); + if (forms[i].needs_size) { + todo_wine ok(hr == E_INVALIDARG, + "GetDescriptor failed: %08x, expected E_INVALIDARG\n", hr); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_GetDescriptor(dmo, &desc); + } ok(hr == S_OK, "GetDescriptor failed: %08x, expected S_OK\n", hr); ok(desc.dwValidData == DMUS_OBJ_CLASS, "Got valid data %#x, expected DMUS_OBJ_CLASS\n", desc.dwValidData); - ok(IsEqualGUID(&desc.guidClass, &CLSID_DirectMusicSegment), - "Got class guid %s, expected CLSID_DirectMusicSegment\n", - wine_dbgstr_guid(&desc.guidClass)); + ok(IsEqualGUID(&desc.guidClass, forms[i].clsid), "Got class guid %s, expected CLSID_%s\n", + wine_dbgstr_guid(&desc.guidClass), forms[i].class); /* Empty RIFF stream */ empty[1] = forms[i].form; stream = gen_riff_stream(empty); memset(&desc, 0, sizeof(desc)); hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); - ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + if (forms[i].needs_size) { + todo_wine ok(hr == E_INVALIDARG, + "ParseDescriptor failed: %08x, expected E_INVALIDARG\n", hr); + desc.dwSize = sizeof(desc); + hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); + } + todo_wine_if(forms[i].needs_size) + ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); ok(desc.dwValidData == DMUS_OBJ_CLASS, "Got valid data %#x, expected DMUS_OBJ_CLASS\n", desc.dwValidData); - ok(IsEqualGUID(&desc.guidClass, &CLSID_DirectMusicSegment), - "Got class guid %s, expected CLSID_DirectMusicSegment\n", - wine_dbgstr_guid(&desc.guidClass)); + ok(IsEqualGUID(&desc.guidClass, forms[i].clsid), "Got class guid %s, expected CLSID_%s\n", + wine_dbgstr_guid(&desc.guidClass), forms[i].class); IStream_Release(stream); /* Wrong form */ empty[1] = DMUS_FOURCC_CONTAINER_FORM; stream = gen_riff_stream(empty); memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); - ok(hr == E_FAIL, "ParseDescriptor failed: %08x, expected S_OK\n", hr); + if (forms[i].needs_size) + todo_wine ok(hr == DMUS_E_CHUNKNOTFOUND, + "ParseDescriptor failed: %08x, expected DMUS_E_CHUNKNOTFOUND\n", hr); + else + ok(hr == E_FAIL, "ParseDescriptor failed: %08x, expected E_FAIL\n", hr); todo_wine ok(!desc.dwValidData, "Got valid data %#x, expected 0\n", desc.dwValidData); /* All desc chunks */ alldesc[1] = forms[i].form; stream = gen_riff_stream(alldesc); memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); valid = DMUS_OBJ_OBJECT | DMUS_OBJ_CLASS | DMUS_OBJ_VERSION; - if (forms[i].form == DMUS_FOURCC_SEGMENT_FORM) + if (forms[i].form != mmioFOURCC('W','A','V','E')) valid |= DMUS_OBJ_NAME | DMUS_OBJ_CATEGORY; todo_wine_if(forms[i].form == mmioFOURCC('W','A','V','E')) ok(desc.dwValidData == valid, "Got valid data %#x, expected %#x\n", desc.dwValidData, valid); - ok(IsEqualGUID(&desc.guidClass, &CLSID_DirectMusicSegment), - "Got class guid %s, expected %s\n", wine_dbgstr_guid(&desc.guidClass), - wine_dbgstr_guid(&CLSID_DirectMusicSegment)); + ok(IsEqualGUID(&desc.guidClass, forms[i].clsid), "Got class guid %s, expected CLSID_%s\n", + wine_dbgstr_guid(&desc.guidClass), forms[i].class); ok(IsEqualGUID(&desc.guidObject, &GUID_NULL), "Got object guid %s, expected GUID_NULL\n", wine_dbgstr_guid(&desc.guidClass)); if (forms[i].form == DMUS_FOURCC_SEGMENT_FORM) @@ -799,6 +822,7 @@ static void test_parsedescriptor(void) dupes[1] = forms[i].form; stream = gen_riff_stream(dupes); memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); todo_wine_if(forms[i].form == mmioFOURCC('W','A','V','E')) @@ -811,9 +835,10 @@ static void test_parsedescriptor(void) inam[3] = DMUS_FOURCC_UNFO_LIST; stream = gen_riff_stream(inam); memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); - todo_wine_if(forms[i].form == DMUS_FOURCC_SEGMENT_FORM) + todo_wine_if(forms[i].form != mmioFOURCC('W','A','V','E')) ok(desc.dwValidData == DMUS_OBJ_CLASS, "Got valid data %#x, expected DMUS_OBJ_CLASS\n", desc.dwValidData); IStream_Release(stream); @@ -822,6 +847,7 @@ static void test_parsedescriptor(void) inam[3] = DMUS_FOURCC_INFO_LIST; stream = gen_riff_stream(inam); memset(&desc, 0, sizeof(desc)); + desc.dwSize = sizeof(desc); hr = IDirectMusicObject_ParseDescriptor(dmo, stream, &desc); ok(hr == S_OK, "ParseDescriptor failed: %08x, expected S_OK\n", hr); valid = DMUS_OBJ_CLASS; @@ -834,8 +860,9 @@ static void test_parsedescriptor(void) todo_wine ok(!memcmp(desc.wszName, s_inam, sizeof(s_inam)), "Got name '%s', expected 'I'\n", wine_dbgstr_w(desc.wszName)); IStream_Release(stream); + + IDirectMusicObject_Release(dmo); } - IDirectMusicObject_Release(dmo); } START_TEST(dmime)
1
0
0
0
Christian Costa : wined3d: Recognize GTX 560M card with NVIDIA driver.
by Alexandre Julliard
06 Mar '18
06 Mar '18
Module: wine Branch: master Commit: 00b1f69cd2d3d7800cbacb4b05ae536eb6f9dc93 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=00b1f69cd2d3d7800cbacb4b…
Author: Christian Costa <titan.costa(a)gmail.com> Date: Mon Mar 5 04:17:48 2018 +0000 wined3d: Recognize GTX 560M card with NVIDIA driver. Signed-off-by: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/directx.c | 2 ++ dlls/wined3d/wined3d_private.h | 1 + 2 files changed, 3 insertions(+) diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c index b73966a..8bda9c4 100644 --- a/dlls/wined3d/directx.c +++ b/dlls/wined3d/directx.c @@ -1341,6 +1341,7 @@ static const struct gpu_description gpu_description_table[] = {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX550, "NVIDIA GeForce GTX 550 Ti", DRIVER_NVIDIA_GEFORCE8, 1024}, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GT555M, "NVIDIA GeForce GT 555M", DRIVER_NVIDIA_GEFORCE8, 1024}, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560TI, "NVIDIA GeForce GTX 560 Ti", DRIVER_NVIDIA_GEFORCE8, 1024}, + {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560M, "NVIDIA GeForce GTX 560M", DRIVER_NVIDIA_GEFORCE8, 3072}, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX560, "NVIDIA GeForce GTX 560", DRIVER_NVIDIA_GEFORCE8, 1024}, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX570, "NVIDIA GeForce GTX 570", DRIVER_NVIDIA_GEFORCE8, 1280}, {HW_VENDOR_NVIDIA, CARD_NVIDIA_GEFORCE_GTX580, "NVIDIA GeForce GTX 580", DRIVER_NVIDIA_GEFORCE8, 1536}, @@ -1945,6 +1946,7 @@ cards_nvidia_binary[] = {"GTX 580", CARD_NVIDIA_GEFORCE_GTX580}, /* Geforce 500 - highend */ {"GTX 570", CARD_NVIDIA_GEFORCE_GTX570}, /* Geforce 500 - midend high */ {"GTX 560 Ti", CARD_NVIDIA_GEFORCE_GTX560TI}, /* Geforce 500 - midend */ + {"GTX 560M", CARD_NVIDIA_GEFORCE_GTX560M}, /* Geforce 500 - midend mobile */ {"GTX 560", CARD_NVIDIA_GEFORCE_GTX560}, /* Geforce 500 - midend */ {"GT 555M", CARD_NVIDIA_GEFORCE_GT555M}, /* Geforce 500 - midend mobile */ {"GTX 550 Ti", CARD_NVIDIA_GEFORCE_GTX550}, /* Geforce 500 - midend */ diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index a78055a..db9dd96 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -2341,6 +2341,7 @@ enum wined3d_pci_device CARD_NVIDIA_GEFORCE_GTX550 = 0x1244, CARD_NVIDIA_GEFORCE_GT555M = 0x04b8, CARD_NVIDIA_GEFORCE_GTX560TI = 0x1200, + CARD_NVIDIA_GEFORCE_GTX560M = 0x1251, CARD_NVIDIA_GEFORCE_GTX560 = 0x1201, CARD_NVIDIA_GEFORCE_GTX570 = 0x1081, CARD_NVIDIA_GEFORCE_GTX580 = 0x1080,
1
0
0
0
Alex Henrie : msvcrt: Compile but show an error if Bessel functions aren' t available.
by Alexandre Julliard
05 Mar '18
05 Mar '18
Module: wine Branch: master Commit: acd2f1e59bd22197b63eb5ae4ac0d621a0b8cce0 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=acd2f1e59bd22197b63eb5ae…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Fri Mar 2 10:02:46 2018 -0700 msvcrt: Compile but show an error if Bessel functions aren't available. Signed-off-by: Alex Henrie <alexhenrie24(a)gmail.com> Signed-off-by: Piotr Caban <piotr(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- configure | 8 +++++++- configure.ac | 8 +++++++- dlls/msvcrt/math.c | 36 +++++++++++++++++++++++++++++++++--- include/config.h.in | 18 ++++++++++++++++++ 4 files changed, 65 insertions(+), 5 deletions(-) diff --git a/configure b/configure index fdcdfd7..397677e 100755 --- a/configure +++ b/configure @@ -17649,6 +17649,9 @@ for ac_func in \ exp2f \ expm1 \ expm1f \ + j0 \ + j1 \ + jn \ lgamma \ lgammaf \ llrint \ @@ -17673,7 +17676,10 @@ for ac_func in \ round \ roundf \ trunc \ - truncf + truncf \ + y0 \ + y1 \ + yn do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` diff --git a/configure.ac b/configure.ac index 43fdb0c..cfc2080 100644 --- a/configure.ac +++ b/configure.ac @@ -2698,6 +2698,9 @@ AC_CHECK_FUNCS(\ exp2f \ expm1 \ expm1f \ + j0 \ + j1 \ + jn \ lgamma \ lgammaf \ llrint \ @@ -2722,7 +2725,10 @@ AC_CHECK_FUNCS(\ round \ roundf \ trunc \ - truncf + truncf \ + y0 \ + y1 \ + yn ) LIBS="$ac_save_LIBS" diff --git a/dlls/msvcrt/math.c b/dlls/msvcrt/math.c index 9b48011..a3af78a 100644 --- a/dlls/msvcrt/math.c +++ b/dlls/msvcrt/math.c @@ -1412,7 +1412,12 @@ INT CDECL MSVCRT__isnan(double num) double CDECL MSVCRT__j0(double num) { /* FIXME: errno handling */ +#ifdef HAVE_J0 return j0(num); +#else + FIXME("not implemented\n"); + return 0; +#endif } /********************************************************************* @@ -1421,7 +1426,12 @@ double CDECL MSVCRT__j0(double num) double CDECL MSVCRT__j1(double num) { /* FIXME: errno handling */ +#ifdef HAVE_J1 return j1(num); +#else + FIXME("not implemented\n"); + return 0; +#endif } /********************************************************************* @@ -1430,7 +1440,12 @@ double CDECL MSVCRT__j1(double num) double CDECL MSVCRT__jn(int n, double num) { /* FIXME: errno handling */ +#ifdef HAVE_JN return jn(n, num); +#else + FIXME("not implemented\n"); + return 0; +#endif } /********************************************************************* @@ -1440,12 +1455,17 @@ double CDECL MSVCRT__y0(double num) { double retval; if (!isfinite(num)) *MSVCRT__errno() = MSVCRT_EDOM; +#ifdef HAVE_Y0 retval = y0(num); if (MSVCRT__fpclass(retval) == MSVCRT__FPCLASS_NINF) { *MSVCRT__errno() = MSVCRT_EDOM; - retval = sqrt(-1); + retval = NAN; } +#else + FIXME("not implemented\n"); + retval = 0; +#endif return retval; } @@ -1456,12 +1476,17 @@ double CDECL MSVCRT__y1(double num) { double retval; if (!isfinite(num)) *MSVCRT__errno() = MSVCRT_EDOM; +#ifdef HAVE_Y1 retval = y1(num); if (MSVCRT__fpclass(retval) == MSVCRT__FPCLASS_NINF) { *MSVCRT__errno() = MSVCRT_EDOM; - retval = sqrt(-1); + retval = NAN; } +#else + FIXME("not implemented\n"); + retval = 0; +#endif return retval; } @@ -1472,12 +1497,17 @@ double CDECL MSVCRT__yn(int order, double num) { double retval; if (!isfinite(num)) *MSVCRT__errno() = MSVCRT_EDOM; +#ifdef HAVE_YN retval = yn(order,num); if (MSVCRT__fpclass(retval) == MSVCRT__FPCLASS_NINF) { *MSVCRT__errno() = MSVCRT_EDOM; - retval = sqrt(-1); + retval = NAN; } +#else + FIXME("not implemented\n"); + retval = 0; +#endif return retval; } diff --git a/include/config.h.in b/include/config.h.in index 353c146..3346b01 100644 --- a/include/config.h.in +++ b/include/config.h.in @@ -342,6 +342,15 @@ /* Define to 1 if you have the `isnanf' function. */ #undef HAVE_ISNANF +/* Define to 1 if you have the `j0' function. */ +#undef HAVE_J0 + +/* Define to 1 if you have the `j1' function. */ +#undef HAVE_J1 + +/* Define to 1 if you have the `jn' function. */ +#undef HAVE_JN + /* Define to 1 if you have the <jpeglib.h> header file. */ #undef HAVE_JPEGLIB_H @@ -1365,6 +1374,15 @@ /* Define if Xrandr has the XRRGetScreenResources function */ #undef HAVE_XRRGETSCREENRESOURCES +/* Define to 1 if you have the `y0' function. */ +#undef HAVE_Y0 + +/* Define to 1 if you have the `y1' function. */ +#undef HAVE_Y1 + +/* Define to 1 if you have the `yn' function. */ +#undef HAVE_YN + /* Define to 1 if you have the `z' library (-lz). */ #undef HAVE_ZLIB
1
0
0
0
Nikolay Sivov : d3dx9: Improve argument validation in CloneEffect().
by Alexandre Julliard
05 Mar '18
05 Mar '18
Module: wine Branch: master Commit: c3f92419e892c54b145f925b49955b1ceecec481 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c3f92419e892c54b145f925b…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Fri Mar 2 23:35:51 2018 +0100 d3dx9: Improve argument validation in CloneEffect(). Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dx9_36/effect.c | 9 ++ dlls/d3dx9_36/tests/effect.c | 203 +++++++++++++++++++++++++++---------------- 2 files changed, 135 insertions(+), 77 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=c3f92419e892c54b145f…
1
0
0
0
← Newer
1
...
62
63
64
65
66
67
68
...
79
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
Results per page:
10
25
50
100
200