• What are you working on? v15
    5,001 replies, posted
[url=http://pastebin.com/0wKg5Wex]A root-finding algorithm for functions with two arguments[/url] It's just using the secant method in "two dimensions". Except that I had to divide each step by 2 because it kept leaping over the roots - I suppose that has something to do with it being two-dimensional I did no math to prove that it should converge, I was just working based on intuition. Seems to work about as well as the normal secant method. I'm doing lots of math stuff these days but I don't really apply all the crap I'm coding to anything.
[QUOTE=geel9;27194780]I'm working on a packaging system for files. It won't have any encryption or anything because...I see no reason for it.[/QUOTE] Hey me too, I have support for various data types including Sound and Images with a simple byte shuffle encryption and a zlib compression. I also have written a extension to the format (I call it pDat) that is used by the patcher program I wrote to update the main data file.
[QUOTE=HubmaN;27192968]Going through netcraft for PHP+x86 servers to have fun with the new Magic Number.[/QUOTE] I haven't found any servers vuln yet. Also: [url]http://tirania.org/blog/archive/2011/Jan-04.html[/url]
[QUOTE=COBRAa;27198944]I haven't found any servers vuln yet.[/QUOTE] I'd be shocked and disappointed if charlie hasn't written something yet that actively seeks and logs them.
[QUOTE=HubmaN;27192968] to have fun with the new Magic Number.[/QUOTE] Elaborate?
[url]http://www.exploringbinary.com/php-hangs-on-numeric-value-2-2250738585072011e-308/[/url]
[img]http://gyazo.com/eb9aa237076d3308280f9445c0492957.png[/img] results in: [img]http://gyazo.com/e5368a62a379c08b4293dc0828c7ab14.png[/img]
Hey, Boredom during History, Calculus, Physics, and similar classes led to the following: Sierpinski carpet - rendered pixel by pixel by recursively subdividing the screen into 1/3s: [img]http://anyhub.net/file/1mPY-fractal_3.png[/img] Sierpinski triangle - rendered by recursing into a given depth, N, and then drawing triangles with 3 lines: [img]http://anyhub.net/file/1mPZ-fractal_2.png[/img] Mandelbrot - rendered pixel by pixel: [img]http://anyhub.net/file/1mP_-fractal_1.png[/img] All written in TI-Basic, so they are very slow. The Sierpinski triangle is the fastest because it doesn't iterate per-pixel; the Mandelbrot is the slowest due to lots of iteration and arithmetic. In terms of code, the Sierpinski triangle was the hardest. It needed to use recursion, but the TI-83 doesn't have functions; I ended up using an extra program for the recursion, but then there was a separate issue - all programs share the same global variables, and there is no variable stack for recursion. I ended up keeping a global iteration count which I used to index into L1 to store each depth's variables, kind of like a makeshift stack :v:
[QUOTE=DrLuke;27200093][img_thumb]http://gyazo.com/eb9aa237076d3308280f9445c0492957.png[/img_thumb] \|/ [img_thumb]http://gyazo.com/e5368a62a379c08b4293dc0828c7ab14.png[/img_thumb][/QUOTE] Why? The magic number only works as a number, but a post is a string.
Whatever
[QUOTE=Robber;27200192]Why? The magic number only works as a number, but a post is a string.[/QUOTE] If the number is in the GET/POST data it redirects you there no matter what. Even if its just in the URL.
How's this so far for OOGL? [lua]#include <oogl/Window.hpp> int main() { GL::Window window( 800, 600, 0, 0, "OpenGL Triangle", GL::WindowFlags::Caption | GL::WindowFlags::CenterScreen ); GL::Context& gl = window.GetContext(); GL::Shader shader( GL::ShaderType::Fragment ); shader.Source( "void main() {}" ); // Can be overloaded to supply multiple strings, like glShaderSource. bool success = shader.Compile(); gl.ClearColor( 0.0f, 0.0f, 0.0f ); while ( window.IsOpen() ) { window.GetEvents(); gl.Clear( GL::Buffer::Color ); window.Present(); } return 0; }[/lua]
Looks pretty good.
[QUOTE=Overv;27200686]How's this so far for OOGL? [lua]#include <oogl/Window.hpp> int main() { GL::Window window( 800, 600, 0, 0, "OpenGL Triangle", GL::WindowFlags::Caption | GL::WindowFlags::CenterScreen ); GL::Context& gl = window.GetContext(); GL::Shader shader( GL::ShaderType::Fragment ); shader.Source( "void main() {}" ); // Can be overloaded to supply multiple strings, like glShaderSource. bool success = shader.Compile(); gl.ClearColor( 0.0f, 0.0f, 0.0f ); while ( window.IsOpen() ) { window.GetEvents(); gl.Clear( GL::Buffer::Color ); window.Present(); } return 0; }[/lua][/QUOTE] How do you get shader errors out of your shader.Compile()?
[QUOTE=Robber;27200192]Why? The magic number only works as a number, but a post is a string.[/QUOTE] My guess is, Compwhizzi added some code like this, to try and stop people using this bug: (replace X with 1, altered so as to actually post and all ) [lua] if (strpos(str_replace(&#8216;.&#8217;, &#8221;, serialize($GLOBALS)), &#8217;222507385850720XX&#8242;)!==false) die("fuckoff"); [/lua]
[QUOTE=limitofinf;27200161]In terms of code, the Sierpinski triangle was the hardest. It needed to use recursion, but the TI-83 doesn't have functions; I ended up using an extra program for the recursion, but then there was a separate issue - all programs share the same global variables, and there is no variable stack for recursion. I ended up keeping a global iteration count which I used to index into L1 to store each depth's variables, kind of like a makeshift stack :v:[/QUOTE] [url=http://en.wikipedia.org/wiki/Chaos_game]Or you can do it this way.[/url]
[QUOTE=blankthemuffin;27201829]How do you get shader errors out of your shader.Compile()?[/QUOTE] There will be a separate function to retrieve the error.
[QUOTE=q3k;27201963][url=http://en.wikipedia.org/wiki/Chaos_game]Or you can do it this way.[/url][/QUOTE] Hey, Yes, I know the chaos game method. However, it would have been [i]much[/i] slower than simply rendering 3 lines per triangle as it requires a very high iteration count to reduce the noise to an acceptable level. (Just to be clear, the 3 lines per triangle method took about 1 minute to render what you see in the picture.)
[QUOTE=PiXeN;27195419]And what you use will you have for it except "replace a single huge file at any minor change" ?[/QUOTE] What's wrong with that? A single data file in a game's directory looks much cleaner than a directory full of the assets.
[QUOTE=vpaan;27202393]What's wrong with that? A single data file in a game's directory looks much cleaner than a directory full of the assets.[/QUOTE] Also it is quicker to access, even modern hard dries have a slower access speed for different files vs the same file.
[QUOTE=iRzilla;27202548]2.22507385072011e-308 [editline]lol[/editline] What? D:[/QUOTE] beginning right, ending right, middle kinda got away from you didn't it?
[QUOTE=limitofinf;27202231]Hey, Yes, I know the chaos game method. However, it would have been [i]much[/i] slower than simply rendering 3 lines per triangle as it requires a very high iteration count to reduce the noise to an acceptable level. (Just to be clear, the 3 lines per triangle method took about 1 minute to render what you see in the picture.)[/QUOTE] The chaos game method isn't much slower from my experience, not to mention being way easier to program. Props for using the lists as a stack, though.
[QUOTE=esalaka;27190892]You need to [B]compile[/B] with -D_POSIX_SOURCE, not link with it.[/QUOTE] Yes that's right, I would get a compiler error from a linker...
[QUOTE=Xeon06;27193543]They do, it just wasn't apparent because of building size: [media]http://dl.dropbox.com/u/3310651/Zombie/center.png[/media] For terrain, I'll just adjust the height of the intersections and flatten where buildings are. For stuff like water and lake, probably will just remove the intersecting blocks or adjust them some way. Bridges would be fun though. And I still gotta find a nice way to generate those natural things.[/QUOTE] The sides of the divisions seems a bit too regular, especially on the larger and less densely populated ones. You could make it look a bit more organic if you subdivided each line once or twice and then randomly offset each new point by a small amount. It'd be a small change, but I'm sure it'd stack up in the bigger picture and make it look a lot nicer. Unless you have other ideas, at which point I await eagerly :smile:
[QUOTE=Larikang;27202738]The chaos game method isn't much slower from my experience, not to mention being way easier to program. Props for using the lists as a stack, though.[/QUOTE] Hey, perhaps you were right, so I wrote a chaos game version. I ran both of the programs for exactly 1 minute by using this website [url]www.online-stopwatch.com[/url] as a stopwatch. Here is the chaos game output: [img]http://anyhub.net/file/1mSB-fractal_4.png[/img] Here is the recursive output: [img]http://anyhub.net/file/1mSC-fractal_5.png[/img] As you can see, the recursive output already finished in under a minute.
[QUOTE=Ortzinator;27195470]I see it now. I think the main roads should be wider though.[/QUOTE] Indeed, it's still a work in progress. :science: [QUOTE=mechanarchy;27203479]The sides of the divisions seems a bit too regular, especially on the larger and less densely populated ones. You could make it look a bit more organic if you subdivided each line once or twice and then randomly offset each new point by a small amount. It'd be a small change, but I'm sure it'd stack up in the bigger picture and make it look a lot nicer. Unless you have other ideas, at which point I await eagerly :smile:[/QUOTE] I have a ton of commented out, half-working code that made curves in the streets. I'll eventually make it work, but I just couldn't wait to get on the buildings!
Interesting, I have just for the past 3 hours been porting OOGL to c# using c++/clr And now it works, almost natively, the managed classes are mirrored wrapers. Though the window is moving up and down, I have no idea why.
[QUOTE=Overv;27202189]There will be a separate function to retrieve the error.[/QUOTE] That's not overly C++ of you, although throwing an exception is kinda lame too.
There is no support for cURL, ergo it sucks. [editline]5th January 2011[/editline] Is there ANY library at all which I can use to just download a file that ISN'T WebClient?
working on an android app that decides what restaurant you should go to because what you want to eat is the hardest fucking decision you will ever make well I haven't actually ported it to android yet but I've got it partially running as a web app [url=http://www.buttsexv2.co.cc/rroulette/rest.php]here[/url] [editline]5th January 2011[/editline] I've just got to localize it (will be adding a zipcode thing eventually) and write the weighting scripts (I'm setting it up so a business can pay me extra to have their name show up more often)
Sorry, you need to Log In to post a reply to this thread.