• What are you working on? v67 - March 2017
    3,527 replies, posted
[QUOTE=phygon;52930591][...] [IMG]https://i.imgur.com/NA70URQ.png[/IMG] [...][/QUOTE] Is that one of those systems where it prompts you to review it and only gives you a link to the store if you thought it was really good? :buddy: At least it's not a dummy UI in this case, but I consider that still fairly underhanded.
[QUOTE=Tamschi;52930970]Is that one of those systems where it prompts you to review it and only gives you a link to the store if you thought it was really good? :buddy: At least it's not a dummy UI in this case, but I consider that still fairly underhanded.[/QUOTE] Yep. [t]https://i.imgur.com/nZSnvCU.png[/t] It also prompts you to contact support if you give it a shit rating [t]https://i.imgur.com/D6ToXCm.png[/t] How is it underhanded? Without systems like this, nearly the only people that you get leaving reviews are those that had a bad time. Why would anyone remember take time out of their day to leave a review for something that they liked? Practically all of my reviews are people that had to contact support for some minor issue that were then happy with the customer service.
[QUOTE=phygon;52931034]Yep. [t]https://i.imgur.com/nZSnvCU.png[/t] It also prompts you to contact support if you give it a shit rating [t]https://i.imgur.com/D6ToXCm.png[/t] How is it underhanded? Without systems like this, nearly the only people that you get leaving reviews are those that had a bad time. Why would anyone remember take time out of their day to leave a review for something that they liked? Practically all of my reviews are people that had to contact support for some minor issue that were then happy with the customer service.[/QUOTE] It's still intentionally making the reviews more positive by selectively prompting people this way (/selectively keeping the negative ones off the store to some extent). I guess it's a matter of opinion though. I usually detract a star for this stuff (and will mention it in reviews that they may be distorted by the dev), but I have no use for your product so you don't have to worry about that with me. [editline]edit[/editline] What I prefer are systems on the stores' part prompting for reviews indiscriminately, but I doubt anything smaller than Steam has a large interest in them being actually accurate. Especially not quasi-monopolies like the Unity Asset Store or Google Play.
Currently working on a continuous platformer game written in C++14 using SFML2. It's essentially a clone of the game Avalanche. [thumb]https://i.snag.gy/5duU3L.jpg[/thumb] For the first time I attempted to use smart-pointers throughout, wasn't really enamored with them. What are other people's opinions?
Noticed some guy's ECS library getting some attention. Took a look and compared speeds and his is quite faster than mine while being less restrictive. And he seems to have users that leave feedback. On top of that somebody else benchmarked his lib against others (not mine though). Dunno, just feel a little bummed out. Can't even get my project to compile on windows currently :/
[QUOTE=niak;52931401]Currently working on a continuous platformer game written in C++14 using SFML2. It's essentially a clone of the game Avalanche. [thumb]https://i.snag.gy/5duU3L.jpg[/thumb] For the first time I attempted to use smart-pointers throughout, wasn't really enamored with them. What are other people's opinions?[/QUOTE] shared_ptr's get overused and are often not used very well. weak_ptr's are also often not ideal - even a single weak pointer can keep a shared pointer around longer than you'd like. unique_ptr, however, is the holy gospel when it comes to pointers/objects that something owns. as pointed out before, they're not 100% perfect, but they're really damn good. I got the chance to speak with some other devs working on space hardware and flight systems, and they're similarly in love with it too. [editline]edited[/editline] from the front page of /r/cpp, [URL="https://eklitzke.org/notes-on-std-shared-ptr-and-std-weak-ptr"]"notes on std::shared_ptr and std::weak_ptr"[/URL]. its an informative read. [URL="https://www.reddit.com/r/cpp/comments/7fqfrv/notes_on_stdshared_ptr_and_stdweak_ptr/dqdy588/"]along with STL's comment on reddit[/URL]
[QUOTE=Tamschi;52931055]It's still intentionally making the reviews more positive by selectively prompting people this way (/selectively keeping the negative ones off the store to some extent). I guess it's a matter of opinion though. I usually detract a star for this stuff (and will mention it in reviews that they may be distorted by the dev), but I have no use for your product so you don't have to worry about that with me. [editline]edit[/editline] What I prefer are systems on the stores' part prompting for reviews indiscriminately, but I doubt anything smaller than Steam has a large interest in them being actually accurate. Especially not quasi-monopolies like the Unity Asset Store or Google Play.[/QUOTE] Well you need to consider that the vast majority of people only rate things 1 or 5 stars, and furthermore that people typically only rate things when they're pissed off or if they're really enthusiastic about it (rare). This system prompts people that are having a one-star experience to get the help that they need, while also encouraging people that are having a good time to rate it highly. In my eyes, this improves the average customer experience; instead of having people be angry that their thing didn't work, rating it one star (hurting me), then remaining pissed off, it encourages them instead to take the steps towards turning their bad experience into a good one. At least with me, at the end of the day the only reason that you'd rate the asset one star would be if you didn't make any attempt to get help. I work closely with customers and offer them refunds if I can't assist effectively. Just so you can know what it's like to be on the other side of this issue ¯\_(ツ)_/¯
[QUOTE=WTF Nuke;52931436]Noticed some guy's ECS library getting some attention. Took a look and compared speeds and his is quite faster than mine while being less restrictive. And he seems to have users that leave feedback. On top of that somebody else benchmarked his lib against others (not mine though). Dunno, just feel a little bummed out. Can't even get my project to compile on windows currently :/[/QUOTE] Mind linking yours again (I remember you already did somewhere but I forgot where) and that other one too if you want?
[QUOTE=phygon;52931606]Well you need to consider that the vast majority of people only rate things 1 or 5 stars, and furthermore that people typically only rate things when they're pissed off or if they're really enthusiastic about it (rare). This system prompts people that are having a one-star experience to get the help that they need, while also encouraging people that are having a good time to rate it highly. In my eyes, this improves the average customer experience; instead of having people be angry that their thing didn't work, rating it one star (hurting me), then remaining pissed off, it encourages them instead to take the steps towards turning their bad experience into a good one. At least with me, at the end of the day the only reason that you'd rate the asset one star would be if you didn't make any attempt to get help. I work closely with customers and offer them refunds if I can't assist effectively. Just so you can know what it's like to be on the other side of this issue ¯\_(ツ)_/¯[/QUOTE] Yeah, I see where you're coming from. I just disagree on priorities, that's all.
[QUOTE=JWki;52931653]Mind linking yours again (I remember you already did somewhere but I forgot where) and that other one too if you want?[/QUOTE] Doesn't feel really presentable right now, I'll post it later when I feel more up to it, sorry. I did look at the code of his lib([url]https://github.com/skypjack/entt[/url]) and noticed where I can make improvements, but it feels like stealing someone elses solution. I don't know, just going to mull it over and try to think of improvements. Probably will end up using some of his ideas, hopefully improved somehow.
[img]https://i.imgur.com/iDE1PLv.png[/img] Oh thank god it works. I've been coding away for something like ~6 hours without running the program (beyond basic "yes this is what multiplying this matrix by this matrix should give me back"). I've implemented matrixes in C++ (in an exceptionally terrible way with only the features I need). But it works! You're looking at an orthographic projection of a cube. This post probably isn't coherent but its 5:43AM. [img]https://i.imgur.com/x3MKHuJ.png[/img] Edit: Perspective rendering! [img]https://i.imgur.com/srBglbO.png[/img]
So numerical integration is weird - because things are great, until they're [I]absolutely[/I] not: [t]https://i.imgur.com/HFpcwFz.png[/t] Left this running overnight, and came back to a couple thousand exceptions in my terminal (that's on me) and -nan values for all the element data. What's happening here is that this is a tethered satellite: I'm graphing the data of the actual "rope" part, which is subdivided into elements. It's given an initial spin, so that's the reason for the initial sinusoidal curve. eventually though, error accumulates in the integrator and shit explodes. so most of my days now are involved with trying to improve my existing systems, add new integrators, or waiting for test runs to complete. matplotlib at least makes my graphs of numerical disaster pretty though :D
I've been making a discord bot as a final project for one of my cs class. It was basically pick your own topic and since i host few 10mans with friends, i thought id make a bot for it :v: [video=youtube;VVVSzVFyEyQ]https://www.youtube.com/watch?v=VVVSzVFyEyQ[/video] [quote][vid]https://cf-e2.streamablevideo.com/video/mp4/rqrr3.mp4?token=1511995785-2KbWzfKp1AuAMvfO3%2F4%2FWSTTVs3%2B2VQpoWjevFRsvGY%3D[/vid][vid]https://cf-e2.streamablevideo.com/video/mp4/pyfq3.mp4?token=1511995851-f8hvf0wGAHCdrJ0SvGtoD%2Buaf2Ql1zi9MFQDIZT8HZM%3D[/vid][/quote] Making it with node. It's nice making something other than websites
Multi-threaded JavaScript run-time, again. [IMG]https://pbs.twimg.com/media/DP1uBLHWsAIsAfm.jpg:large[/IMG] I'm really excited. I picked up the project again last week and I've made great leaps so far. Now it integrates with JavaScriptCore directly, the performance gains are astronomical this way. A big advantage is that I don't have to override the default Promise implementation, I just mess with its internals to make it use the thread pool scheduler. :)
[QUOTE=voodooattack;52933699]Multi-threaded JavaScript run-time, again. [IMG]https://pbs.twimg.com/media/DP1uBLHWsAIsAfm.jpg:large[/IMG] I'm really excited. I picked up the project again last week and I've made great leaps so far. Now it integrates with JavaScriptCore directly, the performance gains are astronomical this way. A big advantage is that I don't have to override the default Promise implementation, I just mess with its internals to make it use the thread pool scheduler. :)[/QUOTE] I was wondering what happened to that project! One question though: How large is the absolute minimum runtime for this, if you leave out all the API bindings? I'm wondering because modern JS seems like a pretty decent choice for a script language right now, unless you want to go the extra step of having something type-safe. [editline]30th November 2017[/editline] [QUOTE=paindoc;52932666][...] eventually though, error accumulates in the integrator and shit explodes. so most of my days now are involved with trying to improve my existing systems, add new integrators, or waiting for test runs to complete. matplotlib at least makes my graphs of numerical disaster pretty though :D[/QUOTE] This doesn't really sound like what you're looking into right now, but what kind of summation algorithm are you using in the sum from the other thread? [URL="https://en.wikipedia.org/wiki/Kahan_summation_algorithm"]The Kahan summation algorithm[/URL] (or related ones, I don't know much about this field myself) seem relevant here[URL="https://en.wikipedia.org/w/index.php?title=Kahan_summation_algorithm&oldid=787018522"].[/URL]
[quote=Support ticket]Maybe next time you want to help me out just sneak up behind me and blow my head off, would save me a lot of aggravation[/quote] I greatly value the community's input. They always have constructive things to say, and are very appreciative of one-on-one support.
[t]https://my.mixtape.moe/rztmxb.png[/t] [url=https://www.shadertoy.com/view/XlffDM]Static Starfield[/url] Made an improved version of the starfield generator I found on shadertoy and clubbed together an example with varying density star fields. It uses a noise texture and squashes the values using an exponential so that bright pixels remain and dark pixels vanish. Additionally I'm using a hash function to scramble the noise texture so it doesn't create repeating patterns in the starfield. To add some visual candy I've also added a slight reddish haze to where the density is increased, giving it the appearance of additional density. Best viewed in fullscreen.
[QUOTE=Tamschi;52933900]I was wondering what happened to that project! One question though: How large is the absolute minimum runtime for this, if you leave out all the API bindings? I'm wondering because modern JS seems like a pretty decent choice for a script language right now, unless you want to go the extra step of having something type-safe. [/QUOTE] The current release build is 448.3 MB as an uncompressed executable (with -O3, so GCC is going all out), and around 160MB as a .tar.gz archive. The only external dependencies are boost and ICU. The bindings can't really be separated, because they're all cooked into the executable. I might change that later. I could do a mini-build too and see what comes of it. [b]Edit:[/b] That turned out to be the RelWithDebugInfo build. I feel stupid sometimes. The actual release build is 19.5MB uncompressed, and 5.5MB in .tar.gz format.
For those using JavaScript for whatever project, I would highly recommend looking at [url=https://www.typescriptlang.org/]TypeScript[/url]. Don't be put off by the fact it's made by Microsoft, it's a really solid (free) product. It basically adds strong typing to JS, and just compiles down to JS, so can be used anywhere.
I'm not sure how interesting this will be for most of you, but i've got neat graphs at least so hopefully it's alright (its mostly :eng101:). I've been working on improving the performance of my gravity algorithm - the first improvement was a tenfold reduction in time spent reading data from the coefficient table, thanks to tamschi [t]https://i.imgur.com/T6vSzlA.png[/t] [img]https://i.imgur.com/qYUbS48.png[/img] I was stuck on the algebra/maths of indexing into a linear array of these constants, given the odd way the indexing works, and he helped clear that right up. Then I just did some fairly standard stuff - avoiding the recalculation of values that can remain the same for the classes lifetime, making sure I'm not doing pointless copies, and trying to help the compiler do it's job. and cleaning up stuff like the three gross things in that first image above. Now I'm replacing my crappy legendere function (that I ripped from a research paper) with the GSL's Legendere stuff. I want to make sure things don't get too wildly different, though, since my previous method was stable (mostly), just a bit slow. So I started using Pandas to difference the data, here showing (data w/ new GSL stuff) - (data w/ old stuff): [t]https://i.imgur.com/pTjftBfh.png[/t] some good news right away - the difference in gravitational acceleration is minimal, being barely higher for the new method. the method is about 30% faster, too. This difference in acceleration, though, affects how the position of the Elements in the Z turns out - [t]https://i.imgur.com/WQQoWQih.png[/t] 0.8m difference in the first 80 seconds doesn't bode super well, so I made a change to how the Legendere polynomials are normalized to see if it helped things: [t]https://i.imgur.com/8ow3505h.png[/t] and 10x better, woo! It's also neat to see how the behavior changes elsewhere. Like in the case of the Y position calculated with the previous (less good) normalization, it begins to diverge fairly quickly. the better method reduces the divergence, though: [t]https://i.imgur.com/dlKtR3d.png[/t][t]https://i.imgur.com/PZSEG7v.png[/t] this post sponsored by me being bored while waiting for longer simulation runs to end, sorry :v
[QUOTE=Sam Za Nemesis;52935485]I'm loving typescript, I am prototyping something using my earlier [URL="https://www.youtube.com/watch?v=nGTPqvelk90"]sourcemod[/URL] project as inspiration to ThreeJS and typescript and it's been such a joy, the syntax is very nice and typescript makes it very maintainable with addition to providing intellisense, it's never been so fun to code like this I'm trying to get OpenGL/GLFW bindings for webgl to try to get it running natively without a browser, hopefully I can present something soon here[/QUOTE] I could actually enable WebGL support (and a plethora of other things) natively in Nexus.js with the flip of a compile time switch. Since I'm linking against WebKit anyway. I've been primarily focused on the multi-threading/IO side of the project till now. Would people want a WebGL-enabled stand-alone JavaScript runtime? Edit: Also, TypeScript is awesome. I'm never going back to vanilla JavaScript outside of Nexus development.
Screenshot because we're not supposed to share our code on the assignment or w/e (though I guess this is mostly to discourage cheating, but I don't want it coming up in a google search anyway). I'm curious how many C++ sins I've commited. From the header: [img]https://i.imgur.com/mS5BMPf.png[/img] The cpp file: [url]https://i.imgur.com/cKuDp2t.png[/url] How bad is it doc?
[QUOTE=Kybalt;52935886]Screenshot because we're not supposed to share our code on the assignment or w/e (though I guess this is mostly to discourage cheating, but I don't want it coming up in a google search anyway). I'm curious how many C++ sins I've commited. [img]https://i.imgur.com/mS5BMPf.png[/img] How bad is it doc?[/QUOTE] im gonna be a real pedant, but i'm not trying to be a dick because C++ is hard (so mistakes happen) why use pointers to return from the function, when you could return a freshly constructed object without using new? why take a reference variable as input, only to do "a.mat->", accessing things via a pointer (suggesting internal variables are naked pointers too)? why are these marked inline, are they in a header? preferably, just throw them in a source file. why doesn't vector cross take const references as arguments? Why not make some of these, like transpose, a member function returning a new object (just transposing the current matrix)? Consider initializing float "sum" in the "multiply" method as "0.0f" - a tiny critique, but the compiler will probably warn you about this anyways. on a similar topic of type's and such, generally you sorta should (correct me if im wrong) use size_t for indexing and iteration through things, unless you want negative values. size_t is just going to be a platform/architecture independent unsigned int, so it's ideal for indexing. the standard library containers use it, and will warn if you try to access them / index into them with int's. at least you didn't do what the idiot who fucked my codebase up did, which is [cpp] const vector_t& vector_t::normalize(const vector_t& input) { vector_t* result = new vector_t(); *result = input.normalized(); if(input->is_temporary()) { delete &input; } return *result; } [/cpp] [I]that's[/I] how you really be fuckin stupid. otherwise, just polish some of your stuff and keep practicing. nothing truly awful about your code, mate
[QUOTE=paindoc;52935910]im gonna be a real pedant, but i'm not trying to be a dick because C++ is hard (so mistakes happen) why use pointers to return from the function, when you could return a freshly constructed object without using new? why take a reference variable as input, only to do "a.mat->", accessing things via a pointer (suggesting internal variables are naked pointers too)? why are these marked inline, are they in a header? preferably, just throw them in a source file. why doesn't vector cross take const references as arguments? Why not make some of these, like transpose, a member function returning a new object (just transposing the current matrix)? Consider initializing float "sum" in the "multiply" method as "0.0f" - a tiny critique, but the compiler will probably warn you about this anyways. on a similar topic of type's and such, generally you sorta should (correct me if im wrong) use size_t for indexing and iteration through things, unless you want negative values. size_t is just going to be a platform/architecture independent unsigned int, so it's ideal for indexing. the standard library containers use it, and will warn if you try to access them / index into them with int's. at least you didn't do what the idiot who fucked my codebase up did, which is [cpp] const vector_t& vector_t::normalize(const vector_t& input) { vector_t* result = new vector_t(); *result = input.normalized(); if(input->is_temporary()) { delete &input; } return *result; } [/cpp] [I]that's[/I] how you really be fuckin stupid. otherwise, just polish some of your stuff and keep practicing. nothing truly awful about your code, mate[/QUOTE] Preference but I think maths operations are nicer as free functions.
[QUOTE=JWki;52935967]Preference but I think maths operations are nicer as free functions.[/QUOTE] yeah, I wasn't trying to preach a gospel or anything. Preference on that varies a lot. I like having them as class members, but thats just me and just has to do with how I've used them thus far. I'm not really in a position to pass out absolute judgement or advice on C++ lol downloading a 1gb heightmap and nearly matching albedo/color texture for the moon. happening status: it's, i.e oh god im actually going to have to do the outerra/proland thing
Math hard so I make look like C so people no angery at me.
Ladder Logic is neat and I like it but programming it gets fucking tedious with how bulky and unintuitive it gets at the more complex side of things imo. I kinda cheated my PLC programming final today as a result. I did everything flawlessly but the final optional objective was to have the ability to view the log file for our program in the HMI. Problem is that FactoryTalk View's way of doing shit doesn't make it easy to make dynamic pages for log viewing (I think the way the professor wanted us to do it was make individual display pages for each set of entries), but I instead wanted one page with dynamic content, because I'm too lazy to make number boxes for each fucking variable of each fucking entry. Unfortunately, momentary buttons can't handle expressions in View, so I instead made a virtual latch that it triggered in the actual logix program, and when it triggered an invisible element that handled the expressions that I needed for the log page to display the right content. This actually allowed me to set up log arrays of various lengths in my program and use the same function to determine how many pages I could click through, and handle the collection for what would be displayed. There's probably an object in view that does expressions when clicked but our documentation given to us for it was literally just the specs to configure it for our HMIs, it's assumed that we'd have taken time out of class between two days ago and today to come in and just learn how to program in View on our own? The Allen Bradley way sure is tedious, and their documentation is absolute ass. Half the examples for how to use shit is doing something so advanced that if you don't already know how the fucking thing works on the basic level you're just going to get more confused trying to learn. Like, imagine wanting to learn about idk, printing "hello world" to the screen and the documentation on printing to screen is the code for a program that generates a font pixel by pixel from a set of binary data written in a text file. Like, yeah you can do that, but I'm looking for the absolute basic way to make this work, not the most complex over the top thing you can come up with that is vaguely related to the concept I'm trying to figure out. Like for example, the sequencer is Allen Bradley's fancy fuck 3 object way of reading/writing to an array in a sequence. And it's so unintuitive that you have to fucking make your array 1 variable longer than your desired length because it starts at index 0 and guess where it write the first value? Index 1. Oh and that's not even fucking counting the fact that if you trigger the sequencer on a timer done bit it doesn't even fucking do that, it only does its work on a high to low transition, basically the opposite of literally every other fucking thing in ladder logic programs. So instead you have to make the sequencer triggered by the timer timing bit, so it's active while the timer is timing and then when the timer is no longer timing it finalises the entry in the array and moves up another index. Not a big deal to fix but it's a weird inconsistency among many.
I cannot embed the video because I could not upload it on youtube due to copyright music. I wanted to work a c++ project and I just bought a new motherboard with aura sync support. So I wrote some code that allowed me to control the aura lights on my motherboard, then I wired up some custom led strips to the motherboard and thus I could control them through my code as well. I then wrote some code that works out the average color of my screen, and then uses that color to set the color of the leds. This was the result Here's the link :[url]https://void.cat/73e5612d8716d34209c2f86e9962f6ac160f2f0a[/url] never mind figured it out [vid]https://void.cat/73e5612d8716d34209c2f86e9962f6ac160f2f0a[/vid]
[t]https://i.imgur.com/BxfuNOX.jpg[/t] [t]https://i.imgur.com/cC9c1zV.jpg[/t] Made this app. It's using the iPhone X's 3D camera to have a rigged Chilicorn mesh mimic your facial expression. It tries to detect your mood and switches the background out to a different environment if you're angry, sad, happy or neutral. Built in Unity using AR Kit. I did the programming, my coworker rigged the mesh. Good fun. Was presented at Slush in Finland the last two days.
Working on a ray-tracing renderer for a uni project: [vid]https://thumbs.gfycat.com/MarvelousGlossyBangeltiger-mobile.mp4[/vid]
Sorry, you need to Log In to post a reply to this thread.