Out of memory!!

D2X-XL - Descent II update for modern systems with many new features and enhanced graphics. Home Page

Moderators: Grendel, Aus-RED-5

Post Reply
Weyrman
DBB Ace
DBB Ace
Posts: 163
Joined: Thu Oct 06, 2005 5:40 pm
Location: Brisbane Australia

Out of memory!!

Post by Weyrman »

Well, the time has finally come where the memory requirements for the ever increasing, beautiful hi-res graphics has outstripped my computer. I now have to disable hi res in order to play a decent sized level. I suppose I could remove some of the files so as to only load some of them, but which ones!

There is though a glimmer of hope on the horizon. My wife actually suggested that we get a new computer for christmas with some money we will be getting in mid december, so here's hoping!

Regards Weyrman

ps My new modem/wireless router turned up today! :D
Pilot from Oz
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

This astonishes me a little. Actually, memory requirements have dropped due to my recent changes to memory handling. If you get out of memory errors, please let me know which level you played (and whether you played any others before launching that one).

Please also tell me which D2X-XL version you have been using. There had been bugs after my revamping texture management terminating the program because of an erroneous diagnosis of lack of memory.

You can decrease texture quality though; dropping it from highest (512x512) to high (256x256) will cut the memory requirements to a quarter w/ a very acceptable degradation of visual quality.

If that's not enough, try to remove the animated textures first (switches, panels, doors in that sequence), as these are the worst memory hogs due them containing multiple images (animation frames).

Edit: Total memory requirement with highest tex. qual. for D2:CS Level 1 is 480 MB on my system. With high tex. qual. it is 300 MB.

(That is not just for the textures, but the complete memory used for D2X-XL).

Don't tell your wife if decreasing tex. qual. helps, or she might decide to spend the money on something else. ;)
User avatar
Kyouryuu
DBB Alumni
DBB Alumni
Posts: 5775
Joined: Fri Apr 30, 1999 2:01 am
Location: Isla Nublar
Contact:

Post by Kyouryuu »

I don't know if it's that surprising though. Some D2 levels use 60-70 different textures, and that's not counting the animated ones. If each one was 512x512 apiece, that's rather beefy. :P
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

512x512x4 = 1MB per texture, makes 70 altogether. Let there be 10 animations with an average of 8 frames per animation, makes 140. Yes, with those big textures, you can expend your memory quickly.
User avatar
Kyouryuu
DBB Alumni
DBB Alumni
Posts: 5775
Joined: Fri Apr 30, 1999 2:01 am
Location: Isla Nublar
Contact:

Post by Kyouryuu »

Right.

I don't think it's a problem with the normal D2 levels because they tended to stick with given themes, which required a limited texture set. D1 levels are a slightly different beast. It's remarkable how colorful level 15 is when viewed without lighting. :lol:

But then it's good karma to not use dozens of textures unless you have to (and even then, the clever, resourceful artist should attempt to generate the desired effect with textures that already exist!).
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Regarding lightmaps you are trying to break through open doors here. ;) I wish I had never added them, as the implementation is half-a$$ed at best. Maybe I'll get around to implement per-pixel lighting one day, which should look good with D1 too. It will always stay an option though.
Weyrman
DBB Ace
DBB Ace
Posts: 163
Joined: Thu Oct 06, 2005 5:40 pm
Location: Brisbane Australia

Post by Weyrman »

Ok Diedel,

here is the details you requested. I am posting this info here as I don't consider this a bug problem, just a \"lack of\" on my behalf.

P3 1200 512meg ram 128meg ndivia fx5200 graphics card

Stats before starting game:

Physical Memory
523760 Tot
309000 Available (approx)
159752 Cache

all hi-res textures from your download page
hi-res pyro model

Render Quality - Low
Texture Quality - Low
Render Entire Mine - off
Use smoke - on
Coloured Light - on
Weapon Light - on
Flames - on
Shield - on
Level detail - Custom - all max

D2 CS level 1
1st load after resetting ini file to turn hi res back on

ini file:

;gamenet launch parameters
;-ng_player albie
;-ng_file missions/d2-2plyr.hog
;-ng_mission dog1.rl2
;-ng_level 1
;-ng_name GameNet
;-ng_join host
;-ng_connect udp
;-ng_type anarchy
;-ng_team 0

;launch d2x-xl in fullscreen mode
-fullscreen
;keep mouse focus in game window
-grabmouse
;use sound sampled at 22 Khz
-sound22k
;skip CD ROM check
-nocdrom
;use trilinear filtering and mipmaps
-render_quality 3
;let OpenGL handle rendering of layered textures
-gl_alttexmerge 1
;display multiplayer game messages from other players
-playermessages
;suppress duplicate messages
-noredundancy
;don't playback cut scenes movies, but allow robot movies
;-nomovies 1
;use bitmap reticle
-gl_reticle 0
;use short multiplayer game data packets
-shortpackets
;send 10 updates per second in multiplayer games
-pps 10
;add your default player name here to make D2X-W32 load it at program start
-player albie
;use the following screen resolution at program start (will be overridden by player profile)
-1024x768
;set the following value to 1 to enable faster rendering of new style menus
-fastmenus 1
;set the following value to 0 to enable the original menu style
-menustyle 1
;set the following value to 0 to enable a backwards compatible camera rendering method
-render2texture 1
;set the following value to 1 to enable sound rendering via SDL_mixer (enables midi playback on non-Windows OS-s)
-sdl_mixer 0
;set the following value to 0 to use Descent 2 sounds in Descent 1 levels
-use_d1sounds 1
;specify the name of a custom menu background to use here
-altbg_name menubg.tga
;specify the brightness of the custom menu background here (0.0 < brightness <= 1.0)
-altbg_brightness 0.75
;specify the transparency of the custom menu background here (0.0 < alpha <= 1.0; -1.0 to keep what's set in the image)
-altbg_alpha -1.0
;tell whether to convert the custom menu background to a grayscale image
-altbg_grayscale 0
;enable hi-res textures
-hires_textures 1
;enable hi speed smoke
-point_sprites
-vertex_arrays
;enable usage of hires models if present
-hires_models 1
-mathformat 2
-printlog
;allow use of lightmaps
-enable_lightmaps 1
;enable use of progress bars when loading levels etc.
-progress_bars 1


created log file:

D2X-XL 1.6.171
Loading program arguments
unloading program arguments
E:\\GAMES\\Descent2\\d2x-xl.exe
-fullscreen
-grabmouse
-sound22k
-nocdrom
-render_quality 3
-gl_alttexmerge 1
-playermessages
-noredundancy
-gl_reticle 0
-shortpackets
-pps 10
-player albie
-1024x768
-fastmenus 1
-menustyle 1
-render2texture 1
-sdl_mixer 0
-use_d1sounds 1
-altbg_name menubg.tga
-altbg_brightness 0.75
-altbg_alpha -1.0
-altbg_grayscale 0
-hires_textures 1
-point_sprites
-vertex_arrays
-hires_models 1
-mathformat 2
-printlog
-enable_lightmaps 1
-progress_bars 1
GetAppFolder ('E:\\GAMES\\Descent2', '', 'data', 'descent2.hog')
GetAppFolder (data) = 'E:\\GAMES\\Descent2/data' (0)
expected game app folder = 'E:\\GAMES\\Descent2'
expected game data folder = 'E:\\GAMES\\Descent2/data'
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/models', 'models', '*.oof')
GetAppFolder (models) = 'E:\\GAMES\\Descent2/models' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/textures', 'textures', '*.tga')
GetAppFolder (textures) = 'E:\\GAMES\\Descent2/textures' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2', 'textures/d1', '*.tga')
GetAppFolder (textures/d1) = 'E:\\GAMES\\Descent2' (1)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/movies', 'movies', '*.mvl')
GetAppFolder (movies) = 'E:\\GAMES\\Descent2/movies' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/profiles', 'profiles', '')
GetAppFolder (profiles) = 'E:\\GAMES\\Descent2/profiles' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/savegames', 'savegames', '')
GetAppFolder (savegames) = 'E:\\GAMES\\Descent2/savegames' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/screenshots', 'screenshots', '')
GetAppFolder (screenshots) = 'E:\\GAMES\\Descent2/screenshots' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/demos', 'demos', '')
GetAppFolder (demos) = 'E:\\GAMES\\Descent2/demos' (0)
GetAppFolder ('E:\\GAMES\\Descent2', 'E:\\GAMES\\Descent2/config', 'config', '*.cfg')
GetAppFolder (config) = 'E:\\GAMES\\Descent2/config' (0)
Creating default tracker list
Loading main hog file
found hog file 'd2x.hog'
found hog file 'd2x-xl.hog'
found hog file 'extra.hog'
found hog file 'descent.hog'
Loading text resources
Loading hires models
Loading ban list
Initializing i/o
Reading configuration file
Initializing control types
Initializing joystick
Initializing graphics
initializing SDL
switching to fullscreen
initializing internal texture list
allocating screen buffer
initializing OpenGL window
setting OpenGL attributes
setting SDL_GL_DEPTH_SIZE to 24 succeeded
setting SDL_GL_STENCIL_SIZE to 8 succeeded
setting SDL_GL_ACCUM_RED_SIZE to 5 succeeded
setting SDL_GL_ACCUM_GREEN_SIZE to 5 succeeded
setting SDL_GL_ACCUM_BLUE_SIZE to 5 succeeded
setting SDL_GL_ACCUM_ALPHA_SIZE to 5 succeeded
setting SDL_GL_DOUBLEBUFFER to 1 succeeded
setting SDL video mode (1024x768x32, fullscreen)
initializing OpenGL view port
initializing OpenGL screen mode
initializing OpenGL extensions
Shaders are available
Rendering to texture is available
building lightmap shader programs
building texturing shader programs
Initializing render buffers
Loading default palette
Initializing game fonts
Initializing movies
found movie lib 'intro-h.mvl'
found movie lib 'other-h.mvl'
found movie lib 'robots-h.mvl'
found movie lib 'extra1-h.mvl'
found movie lib 'extra2-h.mvl'
found movie lib 'extra3-h.mvl'
found movie lib 'extra4-h.mvl'
found movie lib 'extra5-h.mvl'
Initializing game data
Initializing hash tables
Initializing sound data (254 sounds)
Initializing bitmap index (2620 indices)
Initializing placeholder bitmap
Loading game data
Loading main ham file
Loading 910 texture indices
Loading 254 sound indices
Loading 107 animation clips
Loading 105 animation descriptions
Loading 51 wall animations
Loading 66 robot descriptions
Loading 1145 robot joint descriptions
Loading 62 weapon descriptions
Loading 48 powerup descriptions
Loading 166 polymodel descriptions
Loading polymodel data
Loading 100 cockpit gauges
Loading 600 object bitmap indices
Loading player ship description
Loading 6 cockpit bitmaps
Loading 7 reactor descriptions
Loading bitmap index translation table
Looking for Descent 1 data files
Loading Descent 1 data
Loading 800 texture indices
Loading 800 texture descriptions
Initializing 250 sounds
Loading 0 animation clips
Loading 0 animation descriptions
Loading 26 wall animations
Loading 24 robot descriptions
Acquiring model data size of 78 polymodels
Loading sound data
Initializing sound data
Loading sound file
Loading sound data (183 sounds)
Loading sound data
Initializing endlevel data
Initializing sound
Loading hoard data
Showing title screens
Showing loading screen
initializing OpenGL window
initializing OpenGL view port
initializing OpenGL screen mode
Initializing texture merge buffer
Setting screen mode
Initializing game data
Objects ...
Special effects...
AI system...
gauge canvases...
exploding wall...
particle systems...
loading background bitmap...
Loading player profile
Invoking main menu
closing down IPX socket
shutting down merged textures cache
loading hires texture 'E:\\GAMES\\Descent2/textures/glow04.tga' (quality: 0)
shutting down merged textures cache
parsing mission file
'name = Descent 2: Counterstrike!'
'type = normal'
'num_levels = 24'
parsing level list
'd2leva-1.rl2'
'd2leva-2.rl2'
'd2leva-3.rl2'
'd2leva-4.rl2'
'd2levb-1.rl2'
'd2levb-2.rl2'
'd2levb-3.rl2'
'd2levb-4.rl2'
'd2levc-1.rl2'
'd2levc-2.rl2'
'd2levc-3.rl2'
'd2levc-4.rl2'
'd2levd-1.rl2'
'd2levd-2.rl2'
'd2levd-3.rl2'
'd2levd-4.rl2'
'd2leve-1.rl2'
'd2leve-2.rl2'
'd2leve-3.rl2'
'd2leve-4.rl2'
'd2levf-1.rl2'
'd2levf-2.rl2'
'd2levf-3.rl2'
'd2levf-4.rl2'
'num_secrets = 6'
parsing secret level list
'd2leva-s.rl2,1'
'd2levb-s.rl2,5'
'd2levc-s.rl2,9'
'd2levd-s.rl2,13'
'd2leve-s.rl2,17'
'd2levf-s.rl2,21'
''
getting highest level allowed to play
Looking for briefing screen 'robot.tex'
Loading level...
unloading cambot
unloading additional models
unloading extra poly models
unloading additional model textures
unloading extra bitmaps
unloading additional model textures
restoring default robot settings
Destroying camera objects
Destroying smoke objects
Initializing smoke manager
loading level 'd2leva-1.rl2'
loading palette
loading level data
loading level textures
loading hires texture 'E:\\GAMES\\Descent2/textures/ceil029.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock331.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock349.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/door05#0.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/glow04.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock313.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc060#0.tga' (quality: 0)
couldn't find animation for 'misc060#0'
loading hires texture 'E:\\GAMES\\Descent2/textures/blown01.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/pwr02#0.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock297.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/ceil028.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc040.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/metl136.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock346.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock146.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/door37#0.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/hmissil1#0.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/ceil025.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc086.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock296.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/metl154.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/lava06#0.tga' (quality: 0)
couldn't find animation for 'lava06#0'
loading hires texture 'E:\\GAMES\\Descent2/textures/door24#0.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/box01a#0.tga' (quality: 0)
couldn't find animation for 'box01a#0'
loading hires texture 'E:\\GAMES\\Descent2/textures/box01b.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/metl146.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc043.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc041.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock284.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc084#0.tga' (quality: 0)
couldn't find animation for 'misc084#0'
loading hires texture 'E:\\GAMES\\Descent2/textures/misc081.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc046.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/pwr01#0.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/blown02.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc029.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/exit02.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/misc059.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/rock332.tga' (quality: 0)
loading hires texture 'E:\\GAMES\\Descent2/textures/box02a#0.tga' (quality: 0)
couldn't find animation for 'box02a#0'
loading hires texture 'E:\\GAMES\\Descent2/textures/door53#0.tga' (quality: 0)
ERROR: Error: Not enough memory for textures.
Try to decrease texture quality
in the advanced render options menu.
shutting down merged textures cache
shutting down merged textures cache
unloading extra bitmaps
unloading extra poly models
unloading hires animations
unloading hoard data
unloading hires models
unloading tracker list
unloading lightmap data
unloading particle data
unloading shield sphere data
unloading inventory icons
unloading gauge data
restoring effect bitmaps
unloading background bitmap
unloading custom background data
shutting down merged textures cache
unloading endlevel data
unloading textures
unloading poly models
unloading movies
unloading game fonts
shutting down graphics subsystem
shutting down SDL
unloading game texts
unloading program arguments
unloading program arguments
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

This looks like a bug, because at quality 0, you are getting 64x64x4 bytes per texture, i.e. 16384 bytes/texture.

Edit: Woah! Confirmed bug. Fixed in v1.6.172.
Weyrman
DBB Ace
DBB Ace
Posts: 163
Joined: Thu Oct 06, 2005 5:40 pm
Location: Brisbane Australia

Post by Weyrman »

Thanks Diedel,

I've finally got to try it with .176 and it's great to have all the hi res textures back.
Pilot from Oz
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Good. :)
Post Reply