Chlumsky / msdfgen

Multi-channel signed distance field generator
MIT License
3.91k stars 404 forks source link

Error Building With GCC #111

Closed jnhyatt closed 3 years ago

jnhyatt commented 3 years ago

On the newest commit to 'master', I'm now seeing an error when building with GCC (I'm on version 7.5.0). The issue seems to occur exclusively within msdf-edge-artifact-patcher.cpp on calls to memcpy.

Detailed log:

~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp: In instantiation of ‘void msdfgen::msdfPatchEdgeArtifactsInner(const msdfgen::BitmapRef<float, N>&, const msdfgen::Shape&, double, const msdfgen::Vector2&, const msdfgen::Vector2&) [with ContourCombiner = msdfgen::OverlappingContourCombiner; int N = 3]’:
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:161:100:   required from here
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: error: ‘memcpy’ was not declared in this scope
         memcpy(texel, subject, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:146:15: error: ‘memcpy’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
         memcpy(subject, texel, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: note: ‘memcpy’ declared here, later in the translation unit
         memcpy(texel, subject, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp: In instantiation of ‘void msdfgen::msdfPatchEdgeArtifactsInner(const msdfgen::BitmapRef<float, N>&, const msdfgen::Shape&, double, const msdfgen::Vector2&, const msdfgen::Vector2&) [with ContourCombiner = msdfgen::SimpleContourCombiner; int N = 3]’:
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:163:95:   required from here
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: error: ‘memcpy’ was not declared in this scope
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:146:15: error: ‘memcpy’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
         memcpy(subject, texel, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: note: ‘memcpy’ declared here, later in the translation unit
         memcpy(texel, subject, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp: In instantiation of ‘void msdfgen::msdfPatchEdgeArtifactsInner(const msdfgen::BitmapRef<float, N>&, const msdfgen::Shape&, double, const msdfgen::Vector2&, const msdfgen::Vector2&) [with ContourCombiner = msdfgen::OverlappingContourCombiner; int N = 4]’:
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:168:100:   required from here
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: error: ‘memcpy’ was not declared in this scope
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:146:15: error: ‘memcpy’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
         memcpy(subject, texel, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: note: ‘memcpy’ declared here, later in the translation unit
         memcpy(texel, subject, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp: In instantiation of ‘void msdfgen::msdfPatchEdgeArtifactsInner(const msdfgen::BitmapRef<float, N>&, const msdfgen::Shape&, double, const msdfgen::Vector2&, const msdfgen::Vector2&) [with ContourCombiner = msdfgen::SimpleContourCombiner; int N = 4]’:
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:170:95:   required from here
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: error: ‘memcpy’ was not declared in this scope
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:146:15: error: ‘memcpy’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
         memcpy(subject, texel, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~/dev/msdf-atlas-gen/msdfgen/core/msdf-edge-artifact-patcher.cpp:134:15: note: ‘memcpy’ declared here, later in the translation unit
         memcpy(texel, subject, N*sizeof(float));
         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~