Jump to content

[1.0][Release-5-0][April 28, 2015] Active Texture Management - Save RAM!


rbray89

Recommended Posts

for the operating system, like win 7 x64 OR the 64bit verion of ksp?????

My os is 64bit, and i run both x86 and x64 versions of ksp...

You can run either. You'll have to reinstall ATM every time you change from x86 to x64, though.

For example, if you decide to run KSP in x86, you'll need to overwrite the ActiveTextureManagement.dll with the x86 version (assuming you started out with 64bit ATM) and vice versa switching back.

Link to comment
Share on other sites

Sarbian is awesome! Everyone should give Sarbian rep... Like now.

https://github.com/rbray89/ActiveTextureManagement/releases/tag/3-6

Implements a new way to override KSP's internal texture loading altogether. No more waiting for the white screen to dissapear, and textures will load 2x as fast as KSP's loading.

You guys are awsome. But actually its still not quite working for me. Now it seems to have caused a memory leak. With KSP at the title screen, using opengl, windows task manager showed initially less then 2gb, but gradually spun up to 3.5+ gb over about 60 seconds, then crashed. My log got spammed with these messages.



[TR.TextureReplacer] UnityEngine.UnityException: Texture 'TextureReplacer/EnvMap/PositiveX' is not readable, the texture memory can not be accessed from scripts. You can make the texture readable in the Texture Import Settings.
at (wrapper managed-to-native) UnityEngine.Texture2D:GetPixels (int,int,int,int,int)
at UnityEngine.Texture2D.GetPixels (Int32 miplevel) [0x00000] in <filename unknown>:0
at UnityEngine.Texture2D.GetPixels () [0x00000] in <filename unknown>:0
at TextureReplacer.Reflections.initialise () [0x00000] in <filename unknown>:0
at TextureReplacer.TextureReplacer.LateUpdate () [0x00000] in <filename unknown>:0

(Filename: C:/BuildAgent/work/d63dfc6385190b60/artifacts/StandalonePlayerGenerated/UnityEngineDebug.cpp Line: 49)
[TR.Reflections] Environment map -x -> TextureReplacer/EnvMap/NegativeX

(Filename: C:/BuildAgent/work/d63dfc6385190b60/artifacts/StandalonePlayerGenerated/UnityEngineDebug.cpp Line: 49)
[TR.Reflections] Corrupted GameDatabase! Problematic TGA? TextureReplacer/EnvMap/NegativeX

Maybe it's not playing nice with texture replacer?

Link to comment
Share on other sites

You can run either. You'll have to reinstall ATM every time you change from x86 to x64, though.

For example, if you decide to run KSP in x86, you'll need to overwrite the ActiveTextureManagement.dll with the x86 version (assuming you started out with 64bit ATM) and vice versa switching back.

Thanks tedach... That is the info I was looking for......

cheers.

Link to comment
Share on other sites

Looks like it wasn't reading from the configs. Should be fixed to address it.

Sad to say, I'm not seeing any reported memory savings now with 3-6. That seems consistent with the crash log too. Same problem with toolbar icons not showing up, and fuzzed custom navball from NavBallTextureExporter too as before.

[LOG 15:38:57.389] ActiveTextureManagement: Memory Saved : 0B

[LOG 15:38:57.391] ActiveTextureManagement: Memory Saved : 0kB

[LOG 15:38:57.392] ActiveTextureManagement: Memory Saved : 0MB

Error occurred at 2014-10-10_003320.

C:\Program Files\Steam\steamapps\common\Kerbal Space Program\KSP.exe, run by Volynov.

95% memory in use.

2046 MB physical memory [101 MB free].

0 MB paging file [999 MB free].

2048 MB user address space [77 MB free].

Write to location 00200000 caused an access violation.

Edited by lincourtl
Link to comment
Share on other sites

Sad to say, I'm not seeing any reported memory savings now with 3-6. That seems consistent with the crash log too. Same problem with toolbar icons not showing up, and fuzzed custom navball from NavBallTextureExporter too as before.

Reported savings are not accurate at all I'm afraid. Will be fixing that at some point in the future.

Link to comment
Share on other sites

The new build does not two parts from Lack's SXT. Full logs and a stripped down SXT with just the affected parts are available here. Excerpt from the logs:


NullReferenceException: Object reference not set to an instance of an object
at PartLoader.ReplaceTextures (UnityEngine.GameObject model, System.Collections.Generic.List`1 textureNames, System.Collections.Generic.List`1 newTextures) [0x00000] in <filename unknown>:0

at PartLoader.CompileModel (.UrlConfig cfg, .ConfigNode partCfg, Single scaleFactor) [0x00000] in <filename unknown>:0

at PartLoader.ParsePart (.UrlConfig urlConfig, .ConfigNode node) [0x00000] in <filename unknown>:0

at PartLoader+.MoveNext () [0x00000] in <filename unknown>:0

(Filename: Line: -1)

KSP loads fine with these parts removed or when using medsouz's patched dll from yesterday.

Edit: Another bug. I'm getting duplicate flag entries.

Edited by somnambulist
Link to comment
Share on other sites

Yea I'm not noticing any difference between when it is and is not installed. I know task manager is not that accurate but it is still showing me 3.3 GB after install. No difference and I still don't have half the mods I normally run installed.

Also, it'd really be nice if there were some basic descriptions of what I'm supposed to be doing here. There are 2 releases, x64 and x86 and no real description of what the difference is or what I should be doing playing 32 bit. I get the whole merge into gamedata so please don't feed me that line. Can someone tell me the difference between the two?

In fact, I just took ATM out and freed up .4 GB.

X64 for is for people who are running the 64 bit version of the game. X86 is for everyone else.

Link to comment
Share on other sites

I also have to report that I am running out of memory even with very few mods, even with the new update. Here is my log and I hope it helps. https://www.dropbox.com/s/j9pm1i59c04ycoi/Player.log?dl=0

Very few mods and you're running out of memory? Somehow I doubt that unless you physically have very little memory in your computer. If that is the case you should stick to stock.

Link to comment
Share on other sites

Very few mods and you're running out of memory? Somehow I doubt that unless you physically have very little memory in your computer. If that is the case you should stick to stock.

I have been playing this game heavily modded for more than a year now. Thanks to ATM I have been able to do this. I don't know why but with the few mods I have loaded it still hits the limit.

Link to comment
Share on other sites

I have an other issue. I dont get memory exhaustion and i do notice difference in speed of VAB/KSC/Map loading and overall game performance in sandbox. But my current carrer game became unplayable - i cant enter VAB/Map/SPH/Mission control. Can enter R&D, but cant exit from there - Exit button click does nothing. I cant even exit to main menu. Only Alt+F4 helps.

Tryed this with x86-release and x86-release-basic - same result:

1) Interface become unresponsive in exiting game with numerous completeed contracts and active flights.

2) Interface fully works in sandbox mode.

3) Interface works in new career game, but contracts window is empty.

I have no idea how texture managment can cause this, but i expirience this effects only when i use ATM and KSP go back to nominal after ATM deletion. I presume some mod incompatibility.

My Mods (after ATM deletion):

000_Toolbar

B9_Aerospace

BoulderCo

Chatterer

CIT

CommunityResourcePack

Contracts Window

CrossFeedEnabler

DeadlyReentry

DMagic Orbital Science

Engineer

EnvironmentalVisualEnhancements

FerramAerospaceResearch

FinePrint

Firespitter

JSI

KAS

KerbalJointReinforcement

KineTechAnimation

Klockheed_Martian

kOS

KSPLua

MagicSmokeIndustries

MechJeb2

ModuleManager.2.5.1.dll

ModuleRCSFX

MP_Nazari

NASAmission

Nereid

ORSX

PreciseNode

ProbeControlRoom

ProceduralFairings

RealChute

RemoteTech

ResGen

SCANsat

SmokeScreen

Squad

ThunderAerospace

TriggerTech

TweakScale

UmbraSpaceIndustries

UniversalStorage

Virgin Kalactic

Anyone else have such a problem?

Registered to say this and - The Mod is awesome. Period. Must have for mod greedy person like me. Great job.

Link to comment
Share on other sites

When i did a test with an empty gamedata 0.25 used about 200MB more than 0.24.2.

I created a new branch on my repo to load DDS texture without re compressing them. It does not help at all with the memory but DDS loading directly from disk to memory should be way faster than usual textures. It could be used to load cache faster (if we can get the compressed bytes), or later when 64bit is stable to make things faster.

The code is not tested, it's getting too late for me :)

Link to comment
Share on other sites

Reported savings are not accurate at all I'm afraid. Will be fixing that at some point in the future.

Yeah, but before the sarbian-fix (I'm not blaming sarbian, who is indeed awesome) it was reporting 740MB saved, which was also consistent with what I was seeing in Resource Monitor. Now Resource Monitor says almost 100% of my physical memory is being used, and the crash log agrees.

BTW: Do we know why KSP uses so much more memory now? It can't just be the SP+ parts. I was running that in 0.24.2, along with ScanSat, and SDHI, and some more smaller part mods, thanks to ATM. And that was on top of a ton of plugins. Just curious.

On edit: I know I'm trying to shoehorn KSP into 2GB, and 4GB is recommended. It used to work fine though. I'll be sad if I'm mostly confined to stock.

Edited by lincourtl
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...