We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4916

Summary: macOS build error in SDL_render_metal.m
Product: SDL Reporter: Ozkan Sezer <sezeroz>
Component: renderAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2 CC: iryont
Version: HG 2.0Keywords: target-2.0.12
Hardware: All   
OS: Mac OS X (All)   

Description Ozkan Sezer 2019-12-23 09:55:20 UTC
With current hg and clang-5.0.2, I get:

src/render/metal/SDL_render_metal.m:955:34: error: use of undeclared identifier 'data'
        texturedata.mtlsampler = data.mtlsamplernearest;
                                 ^
src/render/metal/SDL_render_metal.m:957:34: error: use of undeclared identifier 'data'
        texturedata.mtlsampler = data.mtlsamplerlinear;
                                 ^
2 errors generated.
Comment 1 Ozkan Sezer 2019-12-23 16:26:08 UTC
This seems to be after changeset 13376:35f99d918ca2 for bug #4914.
Comment 2 Konrad 2019-12-23 16:32:49 UTC
Add:

METAL_RenderData *data = (__bridge METAL_RenderData *) renderer->driverdata;

To:

METAL_SetTextureScaleMode

Above:

METAL_TextureData *texturedata

Can you please fix it?
Comment 3 Ozkan Sezer 2019-12-23 16:55:58 UTC
Thanks: https://hg.libsdl.org/SDL/rev/7cc4fc886d9e
Closing as fixed.