Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Not Untitled

Sign in to follow this  


OK I got it so the Task Manager reports 63MB's and the GC reports 2MB's(<- what?). That's better than 170MB with the GC saying 120MB(ouch).

The problem was:

1) I was creating a new entry class for each one in the WAD directory, but only had one instance. Three thousand new statements later...

2) For TEXTURE1/2 I forgot to put in the file seek line, so the classes got nothing but garbage data. One "patch"(that's what I call them) had over 5000 descriptions. Yikes!

Thanks to everyone who commented in the previous entry. Also following Rob Loach's comment, is this a good method of disposing the textures?

namespace Doom

public class Texture

private Direct3D.Texture Direct3D_Texture = null;

public static implicit operator Direct3D.Texture( Texture ConversionTexture )
return ConversionTexture.Direct3D_Texture;

// constructor + variables(without HTML)

if( Direct3D_Texture != null )
if( Direct3D_Texture.Disposed == false )



I'm creating the textures like this:

SortedList.Add( Name, new Texture( Offset, File ) );

So I assume that their destructors will be called when the list is destroyed?
Sign in to follow this  

1 Comment

Recommended Comments

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!