|
Given that the apps we're building are for internal ad-hoc distribution only, I'm quite fine with not doing bitcode, then
|
# ? Sep 30, 2017 19:24 |
|
|
# ? May 22, 2024 11:32 |
|
Doctor w-rw-rw- posted:Apple released iOS kernel source code: awesome! Eh, the OS X kernel was close enough, I'm not terribly impressed. What I want to see is UIKit, or failing that, Foundation
|
# ? Oct 1, 2017 02:33 |
|
hackbunny posted:Eh, the OS X kernel was close enough, I'm not terribly impressed. What I want to see is UIKit, or failing that, Foundation Eh. Swift foundation will eventually get there and meh, UIKit is never gonna happen.
|
# ? Oct 1, 2017 03:05 |
|
Doctor w-rw-rw- posted:Apple released iOS kernel source code: awesome! Open-sourcing launchd and libxpc is an interesting idea.
|
# ? Oct 1, 2017 03:52 |
|
Simulated posted:Open-sourcing launchd and libxpc is an interesting idea.
|
# ? Oct 1, 2017 04:27 |
|
I've been playing around with the NetService APIs and have been wondering how the heck I am supposed to convert this "addresses" property to something I can use. I'm writing a simple iOS app in Swift 4 and I guess I should be looking for some way of turning this NSData into a struct sockaddr (yeah...) https://developer.apple.com/documentation/foundation/netservice/1408528-addresses?changes=latest_beta
|
# ? Oct 1, 2017 07:11 |
|
fleshweasel posted:I've been playing around with the NetService APIs and have been wondering how the heck I am supposed to convert this "addresses" property to something I can use. I'm writing a simple iOS app in Swift 4 and I guess I should be looking for some way of turning this NSData into a struct sockaddr (yeah...) Get the bytes of the data and bind to an UnsafePointer to the socket struct type you are working with.
|
# ? Oct 1, 2017 20:15 |
|
It kills me that you can't drag around the iPhone X simulator by the bezel now that it is so small. I never remember to click on the sensor bar or the little subtitle bar. I end up whiffing on moving it around constantly.
|
# ? Oct 2, 2017 19:50 |
|
ManicJason posted:It kills me that you can't drag around the iPhone X simulator by the bezel now that it is so small. I never remember to click on the sensor bar or the little subtitle bar. I end up whiffing on moving it around constantly. You can turn off drawing the bezels and it gives you a standard MacOS titlebar.
|
# ? Oct 2, 2017 20:23 |
|
Edit: I wasn't looking at the scaled size in the last panel. Needed to be scaled down considerably to work correctly. AR Kit... I created a new project that uses the AR kit demo with the jet airplane. That works, but when I import my own scn object, and use that asset and launch the app, I can see the object, but it does not rotate as I move around it, or change size when I move further or closer to it. I checked the object's utilities pane and different sections, but I can't see anything different, except for it's size is noticeably larger, so I tried much smaller versions with no difference, except it is actually smaller on screen. The only extra panel section that the jet does not have is "Geometry". Is it important to change anything here? Any guess to why it's tracking, but not rotating or changing scale with the phone's movement? LP0 ON FIRE fucked around with this message at 16:41 on Oct 4, 2017 |
# ? Oct 2, 2017 21:47 |
|
ManicJason posted:It kills me that you can't drag around the iPhone X simulator by the bezel now that it is so small. I never remember to click on the sensor bar or the little subtitle bar. I end up whiffing on moving it around constantly. This should be better in the beta. Initially we interpreted a drag away from the virtual screen as a move and everything else as swiping. The new behavior also treats drags parallel to the virtual screen as moves. carry on then posted:You can turn off drawing the bezels and it gives you a standard MacOS titlebar. Do most people here run with bezels on or off? (Bezels on is clearly superior) Simulated fucked around with this message at 22:02 on Oct 2, 2017 |
# ? Oct 2, 2017 21:57 |
|
bezels off because trying to drag an X sim around the screen is loving annoying
|
# ? Oct 2, 2017 22:29 |
|
Interesting. I had never noticed that certain drag directions work on the bezel, but they do. I'm not sure that any of that fuzziness is needed with the precision of a mouse pointer.
|
# ? Oct 2, 2017 23:23 |
|
Simulated posted:Do most people here run with bezels on or off? Off. I'm not sure why, but the bezels look so silly to me.
|
# ? Oct 3, 2017 00:42 |
|
Plorkyeran posted:I'm not sure what's so confusing about the idea that it's really nice to get some acknowledgement that yes, the thing you reported is a bug and we'd like to fix it one day. An automatic notification that the bug was screened would probably just lead to complaints that someone looked at the bug and then "nothing happened," and you're back to the same situation as before.
|
# ? Oct 3, 2017 02:20 |
|
ManicJason posted:Interesting. I had never noticed that certain drag directions work on the bezel, but they do. I'm not sure that any of that fuzziness is needed with the precision of a mouse pointer. It’s not about fuzziness; hardware distinguishes gestures that begin on the edge or not. The bezel does the same thing: swipes that begin on the bezel are edge swipes. It’s far more accurate. Distinguishing between an edge swipe vs a drag move is ultimately what the issue is here. As I said, it should be much nicer in the beta. The bezel is also the only way to interact with certain hardware buttons.
|
# ? Oct 3, 2017 02:50 |
|
Ah, I was playing around with it some more and suspected as much. I think I'll eventually get used to grabbing the sensor bar. The X looks so silly with bezels off.
|
# ? Oct 3, 2017 03:27 |
|
Dog on Fire posted:Thanks, all, for the info on Amazon Basics. I sent the request to order a batch to the necessary people and one of them had had experience with a company named So I don't know if anyone cares, but I've now had a few days now to use these 3rd party Lightning cables: https://www.amazon.co.uk/Anker-Lightning-Connector-Certified-Ultra-High-Space-Gray/dp/B00UBLOJJG/ Unsurprisingly, it seems, I also don't have anything bad to say about them. They seem sturdy, they are cheap and they seem to work just as well as Apple's cables.
|
# ? Oct 4, 2017 11:47 |
|
Is there anything more involved than the materials inspector to get a 3D scn object to have smooth shading? I've played around with a lot of the settings in the Material Inspector tab, and I can only ever get my model to be a solid color. If it's a lot more involved, any good tutorials anyone can share?
|
# ? Oct 4, 2017 17:04 |
|
Dog on Fire posted:So I don't know if anyone cares, but I've now had a few days now to use these 3rd party Lightning cables: https://www.amazon.co.uk/Anker-Lightning-Connector-Certified-Ultra-High-Space-Gray/dp/B00UBLOJJG/ Anker specifically makes fully licensed cables, chargers, and other bits. My wife and I have a huge (26000mAh) 3-outlet battery, a Bluetooth speaker that doubles as a battery, a bunch of cables including a couple 3m, a couple of big solar chargers, and a multi-outlet wall charger, all Anker, and it's all good gear.
|
# ? Oct 6, 2017 08:59 |
|
I noticed today that Apple's Remote app has something resembling the device's home screen showing behind the whole thing when the Details modal view is brought up. So I got kind of curious as to how this sort of a thing could have been done. There are no really obvious ways to achieve this, right? Edit: Because as far as I know, if there is "nothing" behind the whole view hierarchy, it's represented as all-black. Dog on Fire fucked around with this message at 14:49 on Oct 8, 2017 |
# ? Oct 8, 2017 14:39 |
|
Not with public API, as far as I know. Back in iOS let’s say 7 you could do something that caused the user's wallpaper to show up behind your app window if you made the window transparent. But I don’t think that was intentional, it might’ve only been in the betas.
|
# ? Oct 8, 2017 14:48 |
|
I'm trying to import a mesh from Blender into iOS OpenGL. I'm trying two different ways to do it, either would be fine but both are running into problems. 1. Convert a mesh from an OBJ file into a .h file. I've been using mtl2opengl, but it doesn't seem to like the fact that the file contains multiple meshes, and each one is basically a curved line (I'm creating a grid which needs to go over a person's head in my AR app). It counts the vertices, but just outputs an empty file. 2. Import the mesh using Model I/O and render it using GLKit. I'm able to import the file into a GLKMesh, but Apple's documentation for GLKMesh is non-existent (since they want everyone to use Metal instead, but I really want this to be a cross-platform as possible). I have no idea what the rendering call should look like, and my current attempt just crashes - glDrawElements(_mesh.submeshes[0].mode, _mesh.submeshes[0].elementCount, _mesh.submeshes[0].type, (__bridge GLvoid*)_mesh.submeshes[0].elementBuffer); I can't find any sample code, but it seems like there should be some repo somewhere that someone has already done this.
|
# ? Oct 8, 2017 22:06 |
|
GLKit is (relatively) old and seems to have mostly been intended as a stopgap to help developers switch from OpenGL ES 1.1 to ES 2.0. If you're concerned about your app being cross platform, why are you using GLKit and/or Model I/O? Maybe take a look at something like AssImp for loading your model instead. Does your drawing code work if you replace the GLKMesh with a hand-written cube? You've set up your VAO, VBO, and element buffer correctly, and they're bound?
|
# ? Oct 8, 2017 23:28 |
|
Doc Block posted:GLKit is (relatively) old and seems to have mostly been intended as a stopgap to help developers switch from OpenGL ES 1.1 to ES 2.0. The main reason is because I'm having a hard time figuring out which method I should go with for loading OBJ files. Model I/O seemed like a straightforward solution except for the lack of sample code. I have everything working with a cube loaded in from a .h file, though I'm just using a simple array buffer instead of an element buffer. I briefly looked at AssImp, maybe that's the solution instead of Model I/O.
|
# ? Oct 9, 2017 02:34 |
|
Not really sure if this is the right thread, but is there a reason macOS/Xcode doesn't include uchar.h or cuchar? This is on 10.13 with Xcode 9. My game needs to convert a UTF-8 string to UTF-32. I was going to use mbrtoc32() to do it since it needs to be cross platform, and it needs the char32_t's one at a time, but neither uchar.h nor cuchar exist on my system. This is in C++. Maybe I could use mbrtowc(), but that converts to wchar_t, and my game needs to match the result to another program's UTF-32 output. I hate dealing with this Unicode crap Doc Block fucked around with this message at 15:30 on Oct 9, 2017 |
# ? Oct 9, 2017 06:26 |
|
Plorkyeran may know: https://www.reddit.com/r/cpp/comments/4aaorj/questions_regarding_stdcodecvt/
|
# ? Oct 9, 2017 06:50 |
|
Looks like a C11 thing. Have you filed a bug report?
|
# ? Oct 9, 2017 07:30 |
|
Not yet. I just discovered it. Wasn't sure if it was a bug or what. edit: anyway, my game is already using PhysFS, which has its own Unicode functions, so I'm just gonna borrow their UTF-8 to UTF-32 function and be done with it. Will still file a bug when I get the chance, probably later today. Doc Block fucked around with this message at 15:27 on Oct 9, 2017 |
# ? Oct 9, 2017 07:37 |
|
Doc Block posted:GLKit is (relatively) old and seems to have mostly been intended as a stopgap to help developers switch from OpenGL ES 1.1 to ES 2.0. It looks like AssImp also blows up when I try to load lines instead of meshes. I'm getting the error "aiScene::mNumMeshes is 0. At least one mesh must be there". Is there a way to make AssImp expect lines instead of triangle meshes?
|
# ? Oct 9, 2017 17:33 |
|
Dunno. I've never personally used it. But it sounds like you have an edge case (no pun intended). Maybe just have it be a regular mesh in the file? You can still draw that mesh with lines. If it's a grid or something you might be better off just generating it in code.
|
# ? Oct 9, 2017 18:00 |
|
eschaton posted:Looks like a C11 thing. Have you filed a bug report? Finally got the chance to file a bug report for this. rdar://34924430
|
# ? Oct 11, 2017 01:53 |
|
I know that someone already mentioned this, but I have to agree. It was super cheesy when removing a breakpoint made a little poof animation/sound. Now that it's gone, I miss it terribly.
|
# ? Oct 12, 2017 20:41 |
|
A basic question: what's a good data type in Swift to make floating point calculations with? This is for a helper app for myself that I'm making, so I'm not in a hurry or anything here and I'm most interested in just getting some new information. I have a UITextField that I'm writing a decimal in. Then I'm going to get the text field's value, and then I'm going to add this value to some other decimal. Good old NSNumber seems to handle this well, but I'm seeing new Swift types like the struct Decimal that I thought I'd try out. Initializing Decimal from String like this: code:
seems to create a Decimal instance with the correct value – 1.523. But when I create a Decimal instance with a number literal like this (in a unit test): code:
code:
Edit: or is it safest to store the numbers as integers and divide them by the necessary amount to get the decimal places? Dog on Fire fucked around with this message at 23:14 on Oct 16, 2017 |
# ? Oct 16, 2017 21:56 |
|
Decimal/NSDecimal are fixed point types. The problem might be that when you’re writing the literal “1.523” in code it’s getting represented in the binary as a float or double and then converted to a Decimal at runtime. Whereas when parsing it from a string, it has no intermediary floating point representation so the precision is left intact. I’m not at a computer right now, but NSDecimalNumber is probably just an NSDecimal in Objective-C object form. edit: yep, NSDecimalNumber is a subclass of NSNumber that’s functionally equivalent to NSDecimal but can be put in NSArrays, etc Doc Block fucked around with this message at 23:18 on Oct 16, 2017 |
# ? Oct 16, 2017 23:16 |
|
Decimal not getting parsed correctly as a decimal and instead round-tripping through some binary FP type is a bug we should fix.
|
# ? Oct 17, 2017 01:43 |
|
Dog on Fire posted:But when I create a Decimal instance with a number literal like this (in a unit test): That's weird, because when I do: Swift code:
|
# ? Oct 17, 2017 03:39 |
|
It is, unfortunately, probably target-specific, because the literal protocol is defined in terms of the target’s max fp type
|
# ? Oct 17, 2017 05:25 |
|
Finally getting my hands dirty into Swift. I'm curious if there's any convincing reason behind prepending "@obj" before some of the functions, for instance ones that are called by Timers (I think because of the selector parameter). I know it's using Obj-C, but why did they design it this way? It seems confusing to remember that some calls must have this. So why didn't they just make it Swift, or have the language know to do whatever it needs to do without adding "@obj"? Maybe there's not a good reason..
|
# ? Oct 17, 2017 17:35 |
|
|
# ? May 22, 2024 11:32 |
|
Things with @objc are visible to Objective-C; things without it aren't. This has effects in how it's compiled under the hood in ways that people more knowledgable than I can explain, but it basically comes down to "avoiding @objc will make more performant code".
|
# ? Oct 17, 2017 18:07 |