Jump to content

Ma-Shell

Members
  • Posts

    371
  • Joined

  • Last visited

Posts posted by Ma-Shell

  1. According to multiple posts in the ubuntu forums, canoncial seems to have removed the package from Ubuntu 13.10 and upwards. But what I think, is quite strange, is that it worked for me in the same version you are using. A workaround for this would be configuring your sources.list to allow installing of older packages. Raring (13.04) seems to be the latest version containing those libs. This (http://ubuntuforums.org/showthread.php?t=2182653) post claims to have found a solution to that, which seems to be essantially the same as I described above (I just quickly scanned through the post). If I find the time, later I will take a look into my own sources.list (currently on windows, so I can't do it now) and post the results here.

    • Upvote 1
  2. Since I am currently on windows, I can't try this myself, but you could try the following:

    1. Create a backup of your .cbp - file
       
    2. Open it with the text editor of your choice (if you are new to Linux, you might find a graphical one like "gedit" might fit your needs)
       
    3. Find the lines containing
       
    4. <Environment>
       <Variable name="LeadwerksPath" value='"..."' />
      </Environment>


      (In my file they were lines 46ff)

    5. Make sure, the path between the quots is your Leadwerks directory (this should be the top-level directory, containing the folders Library, libs, Include, etc.
       
    6. Safe the file and load it into code::blocks

    If this works for you, something might have gone wrong with setting up the $LEADWERKS_LINUX_PATH variable.

  3. So, Josh, is it really intended, that you can't simply render two different worlds/cameras, etc. over one another (with alpha)? I think, the ability of doing that was a great feature in LE2.5. Especially the ability of rendering first only the layers without lighting and then AFTER that rendering the lighting seperately (calculated only once from screen-space, as explained in your own document: http://www.leadwerks.com/files/Deferred_Rendering_in_Leadwerks_Engine.pdf). (The part about the lighting is really important for performance). The lack of this would be quite a drawback, imho.

  4. Might be, you are mistaking the Leadwerks-Project folder inside your Documents folder for the Leadwerks install folder. The former one contains only the projects (+ Backup and Screenshots). The install folder should be the one entered to the Leadwerks-updater. (Should be somewhere in your Program Files folder, I guess).

  5. This is the case when using a different setup, but with the setup as described above, I experienced, there must be something wrong.

    When I started the program described above, it startet with a Memory Usage of 2.7 * 10^6 (Byte? Measured using System::GetMemoryUsage()). I monitored the behavior for about 5 Minutes and found that the memory was never decreasing (at least not in a visible manner). In the end I had a Memory Usage of 5.4 * 10^6 (so the memory usage doubled!) still rapidly increasing and never decreasing.

    Trying the same thing with the shadows turned off, I found the behaviour I would expect from your description: The Memory Usage always flipped between two constant values (in my case these were 2673842 and 2673926). And this was also the case after five minutes.

     

    P.S. Is there a possibility to disable LUA?

  6. @ScrotieFlapWack: You need the one for Windows Desktop. The other one is for Windows 8 Apps (Ugh!).

    @all: This is already builtin for VS2013 Express. Just right-click on the scrollbar and choose "Scroll Bar Options..." and then select "Use map mode for vertical scroll bar"

    • Upvote 2
  7. There is a Memory Leak (System::GetMemoryUsage() increases quickly), that appears, when you use a material with z-sort enabled and shadows:

    Step-by-Step:

     

    - (Create New Project (C++ / LUA))

    - Add Camera, Box, Directional Light (other lights don't have the leak!!)

    - (LUA:) Add a Script to either one (I used the light) and add the following line:

    self.context:DrawText("Memory usage: "..System:GetMemoryUsage(),2,150)

    - Add a new material and assign it to the box.

    - In the Material-Settings enable Z-Sort (I don't think the other settings matter, but I used: Solid, Cast shadows, Depth Test, Depth Mask)

    - Ensure, that the Box is set to cast shadows (dynamic or static) and the directional light casts those shadows (e.g. static + dynamic)

    - Start game and watch the Memory rise...

    You can also see, that the value will not go as fast, if you untick the Z-sort OR disable shadows

     

    I attached a zip, which contains the script, material and map-file, I used. If any other files are needed, I can upload them as well.

  8. Ah, that's pretty good news. So I can use the function to see whether there is some memory leak in a method that is called quite often (which is indeed the worst kind of memory leak wink.png), but I can't see, whether I have allocated memory once and forgot to free it, or where the leaking memory was allocated, which makes troubleshooting really hard.

     

    If you want to see your own memory leaks simply search for ".cpp" inside the output window.

    It doesn't show any files/line numbers for me (even for the memory leaks I built on purpose for testing)... Did you only add the "_CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF );" or also any other defines? In case of the defines, it depends on, where it is done. Having a define of "_CRTDBG_MAP_ALLOC" before including Leadwerks.h leads to an error in the file "DetourTileCacheBuilder.h" (from LE), which defines some kind of free itself. Having it below this include doesn't show me the additional info. So what did you do for this to work?

     

     

    EDIT: I guess, there is no possibility to disable LUA, is there?

  9. When trying to use the guide below in order to use the CrtDbg Library for detecting memory leaks, I found, that it showed me leaks beyond count.

    I then tried it on a fresh c++ project (created from the wizard within the Leadwerks-Editor), and noticed, that the leaks were there even on this new project.

     

    The guide I followed:

    http://msdn.microsoft.com/en-us/library/e5ewb1h3(VS.80).aspx

    I noticed the includes and define were already in Leadwerks.h so the only thing one needs to do, is call the following line:

    _CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF );

     

    Also, the Output sadly didn't show, in which files and line-numbers the memory got allocated (Although I defined "_CRTDBG_MAP_ALLOC" and tried various different things).

    I therefore also tried Visual Leak Detector (http://vld.codeplex.com/). From what I saw, a lot of the memory seems to be allocated during various LW-functions, like the context-syncing, loading of the map or rendering, etc.

     

    Did I do something wrong? Do these tools maybe measure the memory too early?

     

    What really bothers me is that I can't really check my own code for memory leaks this way, as I simply wouldn't find them amongst the ~2000 (the exact count varies) number of leaks that are already there.

    Does anyone have a suggestion, what to do here?

     

    P.S.: Visual Leak Detector worked fine with LW2.5

    • Upvote 1
  10. PayPal is open, read the comments and main page smile.png

     

    Well, seems like you were right... Though I couldn't find the option. I think, this should have been communicated way better since it was one main point that keept me from pledging for a long time (I ended up biting the bullet and payed via creditcard).

  11. @LightLadyT: Since LE3 uses lightmapping most of the lighting has to be calculated before running the game.

    Did you use "Tools -> Calculate Lighting" after you changed something in the scene?

    Or do you mean, you can't change anything inside the demo scene? In that case you might try starting the editor as admin (this problem might occurr if you installed LE e.g. to your program files-folder instead of C:/Leadwerks and have the UAC set active)

×
×
  • Create New...