-
Notifications
You must be signed in to change notification settings - Fork 743
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Skia bindings #418
Add Skia bindings #418
Conversation
Great, thanks! But ↓ it doesn't seem like the fork is being maintained?
One of the reasons for using JavaCPP is to save time having to maintain such C wrappers. I'd like to see if we really can't map the C++ API, even if only partially at first. Could you make a quick list of pending issues so we can evaluate how much effort that might require? BTW, it looks like they are not releasing versions, so let's do like we decided for Liquidfun in pull #356 |
Check out the update-master branch, which was touched 3 days ago and is < 100 commits behind upstream. The fork is also the basis of the SkiaSharp library for C#, which is a core project of the Mono team, and so seems likely to receive continued attention for the foreseeable future. Further, the fork expands on the existing C API in Skia, which isn't well maintained in upstream, but the Skia team has written that they intend for the C API to be their stable interface. I've also reached out to the maintainer of that fork to ask about efforts to merge their changes upstream. If Skia still intends their C API to be their stable API, I think there's value in binding that API, even though the C++ API could potentially be bound directly. Here's a diff from my efforts binding the C++ API of me commenting stuff out that wasn't working: https://gist.github.com/nornagon/d801cabc36fa33ff4cd275cd2eecbefd I was trying to move pretty fast when building the binding, and with limited understanding of
|
I see, so it looks like this is going to become the official C API? That's a good start then. The C++ API sounds like it'll require some effort to get working alright. For the version, the date is the date of the commit, so 20170511 in this case. Not the date we changed something in this repository. Also, let's use it in the "Introduction" of the README.md file. Did you forget to add a build for Windows? We should either add the commands to build in |
There's also an issue building on Linux: |
Not sure if this will work, best of luck appveyor!
I'm not sure if this precisely will become the official C API, but it does seem likely that a C API of some kind will be the stable ABI to Skia in the future. I've switched to building a release instead of debug build, which should fix the linux build issue (hopefully). I've also added a windows build to the cppbuild.sh, but I'm not sure if there's anything else I'll need to do to get it building properly on Windows. We'll see what Appveyor has to say :) |
Per https://skia.org/user/build, it looks like Skia only builds on Windows with Visual Studio 2015 Update 3, but I think the appveyor setup for javcpp-presets is set up to build with mingw/msys2. I'll leave the windows build problem for another time, but it looks like the linux and mac builds are working fine on travis! |
Sounds good, others can add other platforms like Windows, etc at some later point in time when they need it :) We'll also just need to remove "windows" from |
Done. |
FYI, thanks to @vb216, SNAPSHOT artifacts are now available here: |
This binds the mono/skia fork of Skia, which has expanded C bindings.