• What are you working on? October 2015
    1,070 replies, posted
[QUOTE=Winner;48932453]that is almost completely invisible unless I turn my screen brightness all the way up[/QUOTE] The stars are basically 40, 40, 40 RGB, how can you [B]not[/B] see them? [editline]18th October 2015[/editline] The background is 0, 0, 0
In preparation for some of the upcoming things I'm going to learn (such as tesselation), I've decided that I'm finally ready to start moving away from my own crude model format and use actual pre-existing model formats so that I could start using actual models instead of my basic cone/cube/sphere shapes. To that end, I started learning the Assimp library for importing a wide range of model formats, and quickly jury-rigged it in. It isn't working 100% yet, but it doesn't need to, as I plan to completely change a lot of my back-end pertaining to geometry, which sadly will break a lot of things, but will be worth it in the end. [t]http://i.imgur.com/0v5uecd.png[/t] The UV mapping is fucked, but at least I can see all my shaders actually illuminating something other than a cube or sphere for once.
[QUOTE=Rocket;48932565]Some people have their contrast set differently on their monitors [img]http://i.somethingawful.com/forumsystem/emoticons/emot-ssh.gif[/img][/QUOTE] Well i know that, but somebody obviously has to have wrong display configuration then. [editline]18th October 2015[/editline] Or just a shit monitor.
don't blame the user mayne
[QUOTE=Winner;48932453]that is almost completely invisible unless I turn my screen brightness all the way up[/QUOTE] I can see it fine and I'm always fucking with my screen settings, my cheap ass piece of shit TV. I can't even find it online, who is DGM?
[QUOTE=cartman300;48932648]Well i know that, but somebody obviously has to have wrong display configuration then. [editline]18th October 2015[/editline] Or just a shit monitor.[/QUOTE] A lot of laptop monitors have really poor brightness resolution and will show dark shades as (almost) black, but these are probably still a little too bright for that. Gamma settings matter too, which I doubt are correct anywhere by default unless the entire device is pre-made and runs stock software (and even then it's doubtful). [editline]19th October 2015[/editline] There's also the distinction of TV and PC monitor range, with the black point of a TV signal being significantly higher. If you use a normal PC monitor or modern digital TV that shouldn't go wrong though.
As much as I enjoy programming for my own projects... assignments aren't fun, and I need to not leave them until 3AM again.
I fixed my UV map importing: [t]http://i.imgur.com/Hjyc7LH.png[/t] I fucking love this ambient occlusion tho
[QUOTE=Karmah;48932586]In preparation for some of the upcoming things I'm going to learn (such as tesselation), I've decided that I'm finally ready to start moving away from my own crude model format and use actual pre-existing model formats so that I could start using actual models instead of my basic cone/cube/sphere shapes. To that end, I started learning the Assimp library for importing a wide range of model formats, and quickly jury-rigged it in. It isn't working 100% yet, but it doesn't need to, as I plan to completely change a lot of my back-end pertaining to geometry, which sadly will break a lot of things, but will be worth it in the end. [t]http://i.imgur.com/0v5uecd.png[/t] The UV mapping is fucked, but at least I can see all my shaders actually illuminating something other than a cube or sphere for once.[/QUOTE] It's cool seeing how far your engine has progressed over time. Congrats on all this, it's really impressive.. One of my favorite ongoing WAYWO projects honestly.
[QUOTE=srobins;48933621]It's cool seeing how far your engine has progressed over time. Congrats on all this, it's really impressive.. One of my favorite ongoing WAYWO projects honestly.[/QUOTE] Thanks! I know its taken a long time to get to this point because I've taken the very inefficient route of not just building a renderer, but an engine and editor along side and constantly having to play catch-up with the other 2 and always patching things...but it is totally worth it because I love having personal projects and being able to keep myself busy and learn things that I find interesting whenever I want. Over the past year and a half I've learned so much. Even if I don't ever do anything with any of this stuff, it has given me insight into how modern games work and a deeper appreciation for the software design aspect of games. On top of that, there is still so much cool things left that I still want to explore. I need to learn a bit more about multi-threading, create a proper separate engine timer thread, synchronize animation onto that thread, implement tessellation, and make some sick-nasty water that is 1) tessellated, 2) has animated texture map, normal map, and specular map. There's so much stuff that I want to do.
Is there such thing as a "Turing Test bronze medal" for being indistinguishable from a drunk human? Multiple people have joined my server and seen my bot skating around and asked if I was drunk. On a related note it can finally score goals fairly reliably on the empty net. [vid]http://fat.gfycat.com/DopeyLastingAcornweevil.webm[/vid] Still a long way to go before it can beat a goalie.
[IMG]http://i.imgur.com/G3bjOCx.gif[/IMG] integrated map + room generation into the game. now im gonna implement elites (they give a pack of mobs various buffs and also have higher hp/damage)
More UI shiz this time made a new directX color picker control. [IMG]https://dl.dropboxusercontent.com/u/10798900/staging/store/push/2015-10-19_21-14-13.gif[/IMG] minor improvements. [IMG]http://puu.sh/kPQfs.gif[/IMG]
[QUOTE=Darwin226;48922327]It's a bit hard to find information on this, but does anyone know how much allocation time is dependent on the size you're allocating? For example, would it be safe to assume that allocating 1kb and allocating a 100 bytes is the same thing? What are the thresholds? This probably differs from allocator to allocator, so if you know the answer for any of them, please share.[/QUOTE] For sizes that small, they probably are equivalent. Typically the first allocation you make will have the OS perform the relatively costly procedure of handing you an entire memory page (4KB on most OSes), and any subsequent allocations will just be grabbed from that same memory page, until you fill that up and the OS needs to hand you another. Allocating a larger size such as 1kb is likely to fill up the page quicker and so be slower, but assuming that all the allocated memory fits within a single memory page, they should otherwise be equivalent. [QUOTE=Tamschi;48922442]If this is C++/something else that doesn't clear the memory, then [I]I suspect[/I] it depends mainly on the internal fragmentation of the process or the amount of additional pages that have to be cleared and allocated by the OS. Allocating the same amount most likely can take various different amounts of time due to this, with no clear threshold regarding single allocations. With something like Java or the CLR that force-clears all new instances you'll also get that as additional proportional cost, but how that performs in practice definitely should depend on what exactly the OS and caches do since I can't imagine them not using [I]memset[/I] or similar internally.[/QUOTE] In practise C++ usually does clear the memory. Try writing a C++ program that uses an uninitialized variable at the start of execution - it'll always be 0. This is because (on Windows, at least) the OS always clears the memory page before handing it off to your program, as otherwise it could be a potential security flaw. However, it is possible your your program to reuse memory in the same memory page which'll always just be filled with residual data from your own code.
[QUOTE=Tommyx50;48935348]In practise C++ usually does clear the memory. Try writing a C++ program that uses an uninitialized variable at the start of execution - it'll always be 0. This is because (on Windows, at least) the OS always clears the memory page before handing it off to your program, as otherwise it could be a potential security flaw. However, it is possible your your program to reuse memory in the same memory page which'll always just be filled with residual data from your own code.[/QUOTE] So memory is only cleared in specific situations on a specific platform? To be honest it sounds like you shouldn't assume memory is cleared for you then.
[QUOTE=Tommyx50;48935348]In practise C++ usually does clear the memory. Try writing a C++ program that uses an uninitialized variable at the start of execution - it'll always be 0.[/QUOTE] this isn't true
[QUOTE=Ziks;48935422]So memory is only cleared in specific situations on a specific platform? To be honest it sounds like you shouldn't assume memory is cleared for you then.[/QUOTE] I think that would really depend on the API you are using. calloc would return cleared memory while malloc wouldn't (it may but it also may not, depends upon the implementation) The rest is kinda irrelevant because you are not directly doing a page allocation system call.
[QUOTE=Tommyx50;48935348]In practise C++ usually does clear the memory. Try writing a C++ program that uses an uninitialized variable at the start of execution - it'll always be 0.[/QUOTE] As DarKSunrise stated, this is incorrect. [B]Static[/B] variables are default initialized. Non-static are usually initialized to garbage. Using an uninitialized/garbage variable in C++ is UB and either wont compile or it will crash at run time.
I think you are all misunderstanding me. I'm not saying you should every rely on this behaviour. Using an uninitialized variable in C++ is undefined behaviour. The OS may zero the memory, it may not, it may fill the memory with random data. Most compilers will just use whatever data is already there. You should never use an uninitialized variable. It's a stupid idea. I'm just saying that when the OS gives your program memory, it gives it in pages, which the OS will usually modify so that data does not "bleed" between programs. [QUOTE=Ziks;48935422]So memory is only cleared in specific situations on a specific platform? To be honest it sounds like you shouldn't assume memory is cleared for you then.[/QUOTE] Yes. This is exactly what I mean. You should *always* initialize your variables. People are misunderstanding me. I'm not saying you should rely on this or use this. I'm just saying this is a thing that happens. [QUOTE=Rocket;48936073]I'm no expert, but wouldn't [url=http://codepad.org/2ZpTOckb]this code[/url] print "1\n0" then?[/QUOTE] It depends on the operating system. More modern OSes may fill the memory with random data instead of zeroing. [B]Again - to reiterate. This is NOT a feature of C++, this is just a quirk of operating systems.[/B] [editline]19th October 2015[/editline] Here's what I get on Windows 10 using Visual Studio 2013: [IMG]http://i.imgur.com/cIf30X1.png[/IMG] Again, depending on OS and the such, memory may be randomized or not cleared. Also, C++ may use up some data in the backend before you ever see it, showing different data. Again, this is NOT something you can rely on. Using uninitialized variables is undefined behaviour. This is simply a consequence of how OSes handle memory.
[QUOTE=Trumple;48929357]Without comments, and with ambiguously named variables, I'm not sure we can help :v:[/QUOTE] Sorry! The function returns a field line of a vector function f starting at a point v. I posted after I discovered the bug, I thought you guys would find it neat, I always love find-the-bug posts (of this type). The bug is [code]v +=[/code] instead of [code]v = v +[/code] because the former doesn't create a new vector object, instead updating the original, so my fieldline list is only references to the same point. It was particularly annoying because a print() at that point showed the vectors following the field line. And sorry that it's not PEP8, new hard drive, haven't configured sublime text yet :v:
[img]http://i.imgur.com/gXXmiSp.png[/img] 2D world portal idea: The black region is where both hidden and non-hidden geometry overlap, the red region is the non-hidden geometry and blue is the hidden geometry. Level geometry would draw over the shadows. The world portal "shadow" (yellow zone) would reveal the hidden area and it would be occluded by it but it would hide the non-hidden (red) area. The rest is just casting normal shadows so it doesn't look weird and so you can't see inside the red box as that space effectively "does not exist" (it's a part of blue box).
just stencil and draw a reoriented view from the destination portal
[t]http://imgur.com/i1d9y6h.jpg[/t] Or something like that. I like prototyping my app out with a CLI first, then implementing.
Decided to make a proper RPN calculator for my crappy old Nokia N8 phone with archaic Symbian^3 OS. [t]http://i.imgur.com/2SLX3Rh.png[/t]
[QUOTE=Map in a box;48938245]just stencil and draw a reoriented view from the destination portal[/QUOTE] That's what i said. [editline]19th October 2015[/editline] But i also added shadows so it doesn't look gay. I should probably implement that in my engine.
[QUOTE=cartman300;48939964]That's what i said. [editline]19th October 2015[/editline] But i also added shadows so it doesn't look gay. I should probably implement that in my engine.[/QUOTE] To be fair, describing your explanation as "muddled" is charitable. Referring to three different things as "it", "it", and "it" is hard to follow.
Starting to (finally) work on buildings. [img]http://i.imgur.com/v2yRT5x.png[/img] They overlap, the look like crap! This is all I have right now. [editline]20th October 2015[/editline] Made them conform to the boundaries of the road [img]http://i.imgur.com/jd6QCqR.png[/img]
[media]https://www.youtube.com/watch?v=-Et5Ivi_yIg[/media] frontier did a video on their planetgen
I realize this program is really pointless, and is, as one of my friends put it, "a weirdly specific version of MS Access". Hell, you could easily replicate the functionality of this with any spreadsheet program, but I've really been enjoying working on this. [vid]http://webm.host/8ae79/vid.webm[/vid]
[QUOTE=Billy2600;48942459]I realize this program is really pointless, and is, as one of my friends put it, "a weirdly specific version of MS Access". Hell, you could easily replicate the functionality of this with any spreadsheet program, but I've really been enjoying working on this. [vid]http://webm.host/8ae79/vid.webm[/vid][/QUOTE] Neat. What library did you use for UI?
Sorry, you need to Log In to post a reply to this thread.