Comments (5)
The warnings about nanosvg/rast.h looks sane things to fix.
I really really really hate the warnings about NSVG_NOTUSED
. A new compiler, and we're back to square one again, and again.
If upstream stb_image_write fixes the warnings, let's update, else just leave it as is.
Thanks for taking the time to improve the code!
from nanosvg.
Could you please check this version in Xcode? It compiles without warnigs with GCC 4.7.2 and VC2015 RC.
#define NSVG_NOTUSED(v) ((void)(v))
from nanosvg.
Upstream stb_image_write.h is even worse than your version ;-) I will patch only nanosvg.h and nanosvgrast.h warnings.
1>e:\source\nanosvg\example\stb_image_write.h(210): warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\windows kits\10\include\10.0.10056.0\ucrt\stdio.h(205): note: see declaration of 'fopen'
1>e:\source\nanosvg\example\stb_image_write.h(329): warning C4457: declaration of 'comp' hides function parameter
1> e:\source\nanosvg\example\stb_image_write.h(278): note: see declaration of 'comp'
1>e:\source\nanosvg\example\stb_image_write.h(372): warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\windows kits\10\include\10.0.10056.0\ucrt\stdio.h(205): note: see declaration of 'fopen'
1>e:\source\nanosvg\example\stb_image_write.h(553): warning C4456: declaration of 'i' hides previous local declaration
1> e:\source\nanosvg\example\stb_image_write.h(476): note: see declaration of 'i'
1>e:\source\nanosvg\example\stb_image_write.h(554): warning C4456: declaration of 'j' hides previous local declaration
1> e:\source\nanosvg\example\stb_image_write.h(476): note: see declaration of 'j'
1>e:\source\nanosvg\example\stb_image_write.h(702): warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
from nanosvg.
I have used that unused macro before, and cannot remember anymore why I changed that. It might have been gcc with tighter warning level.
from nanosvg.
Some warnings are fixed in #42
I didn't fix following warnings:
1>E:\Source\nanosvg\src\nanosvg.h(120): warning C4201: nonstandard extension used: nameless struct/union
1>E:\Source\nanosvg\src\nanosvg.h(359): warning C4201: nonstandard extension used: nameless struct/union
1>E:\Source\nanosvg\src\nanosvg.h(730): warning C4127: conditional expression is constant
1>E:\Source\nanosvg\src\nanosvg.h(2487): warning C4127: conditional expression is constant
1>E:\Source\nanosvg\src\nanosvg.h(2488): warning C4127: conditional expression is constant
C4201 nonstandard extension used
should be probably fixed in VC project, because anonymous structures and unions are valid in C11.
C4127 conditional expression is constant
is problematic NSVG_NOTUSED macro.
from nanosvg.
Related Issues (20)
- Unitless quantities are entirely unaffected by DPI HOT 5
- outlines donβt draw properly HOT 1
- How to find the outer loop and internal loops(holes) of a path? HOT 2
- Closed paths are not positioned correctly? HOT 2
- Firefox logo renders incorrectly HOT 11
- How to retrieve the "s" command so that my bezier curves are connected? HOT 2
- Textured shapes get incorrectly set as PAINT_NONE fill
- HTML &#; entities not supported
- nanosvg doesnt render beautyline icons HOT 7
- pathFlag never used HOT 1
- Unspecified stroke width gets read as 1, causing issues when scaled HOT 7
- Bug: "else" missing HOT 3
- heap-buffer-overflow read in nsvg__parseColorRGB()
- start versioning nanosvg. HOT 5
- Multicolor SVG rendered with a black background HOT 1
- nsvg__parseSVG HOT 1
- heap-buffer-overflow in nsvgRasterize HOT 1
- the antialiasing on different background,
- OSS Fuzz integration HOT 1
- Incorrect comment
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nanosvg.