Questions tagged [resource-management]

Approaches and techniques for managing of game assets (resources). Usually things like sounds, textures, models, animations, etc. that take up memory.

Filter by
Sorted by
Tagged with
0 votes
0 answers
31 views

stencil as shader resourceview

I would like to use the stencil information in my depthstencil buffer as shaderresourceview (DX11) in my shader. I have a DSV D24S8 from which I create a R24X8 resource fine using the red for ...
user avatar
  • 47
0 votes
1 answer
42 views

What is the typical way of authoring and implementing dynamic asset loading via blocks, in Unity?

Suppose that you have thousands of individual resources that need to be loaded dynamically (e.g. some kind of procedural or randomized world that spawns all manner of things etc). There are many ways ...
user avatar
  • 1,579
0 votes
1 answer
237 views

Reference counting with resource handles

I have implemented a resource handle and resource cache class. The handle stores an integer id. The cache stores a vector of objects e.g., Textures. The handle id acts as an index into the cache ...
user avatar
0 votes
1 answer
1k views

Unity difference between accessing asset prefab from reference VS from Resources.Load?

Question point Does putting prefab asset in inspector's reference and access its content inside in runtime VS. Load the same prefab asset from Resources.Load API, ...
user avatar
  • 543
3 votes
1 answer
644 views

C++ Wrapper class for raw pointer to an SDL_Texture

First time in game dev, so go easy on me. I understand it's senseless to copy textures, but I'm trying to see this from a copy/move perspective since there is a lot of that going on in my code and in ...
user avatar
0 votes
0 answers
66 views

How to extract data from a resource compiler script in c#

I need to know how to extract all data from a resource compiler script to a folder or the desktop. the .res files are compiled and added to an exe file. .res is the file extension. and if that is ...
user avatar
1 vote
1 answer
42 views

What is the difference between cudaExternalMemoryHandleTypeD3D12Resource and cudaExternalMemoryHandleTypeD3D12Heap?

When we import a D3D12 memory object into cuda we do something like this: ...
user avatar
  • 160
1 vote
3 answers
228 views

Do multiple small script files use more RAM than one bigger script file?

So I'm still new to making games that have a baseline for computer resource usage and I'm confused with my question. I can't find an answer anywhere on the internet so I'm here. Simple Question: ...
user avatar
2 votes
3 answers
252 views

Centralized ResourceManager Class for every type of Asset in an Game Engine

I am trying to Implement resource manager for my hobby game engine. The problem I am trying to solve is that I want one centralized resource manager, which delegates resource loading to a bunch of "...
user avatar
2 votes
2 answers
2k views

How to update the value of all owners of shared_ptr?

I’m writing a render, there is a class that shaders should store, something like a shader manager. These shaders are stored as ...
user avatar
1 vote
1 answer
296 views

Do I need a rendering system in my engine?

I am planning to create a cRPG game engine that would allow to easily create games like Baldur's Gate. I already tried to do that once, but my knowledge was vastly insufficient at the time. I settled ...
user avatar
0 votes
0 answers
460 views

Why are pyglet.image and texture so heavy?

Envrionment: python: 3.6.6 pyglet: 1.3.2 Here is my code and results: ...
user avatar
0 votes
1 answer
100 views

What aspect of performance should I be optimizing my code towards? (asynchronous chunk modification)

Preface I realized that the root of my question is a little simpler than all of the details below make it out to be. All other things being equal, what is the most important system aspect to optimize ...
user avatar
0 votes
1 answer
50 views

Memory Management when changing Game States [closed]

I am just wondering what are some of the issues of loading and freeing the memory every time player changes the game state? Or is it better to load all the resources at once?
user avatar
1 vote
0 answers
116 views

Design of (texture) resource system

For an open source game I wanted to redesign the resource management system but got into a dead end and need some pointers to some reading material or where to go now. Starting point was (mostly) a <...
user avatar
  • 216
2 votes
3 answers
949 views

Implementing reference counting from scratch or using shared_ptr for resource?

In an OpenGL application that I am writing, I want to have a simple shader class to wrap the OpenGL shader handle. Ultimately, I want this shader class to behave very similarly to a shared_ptr in c++ (...
user avatar
0 votes
2 answers
127 views

Most effective way to perform dynamic list of actions?

I have a huge list of predefined game objects with different actions they do. What is the best (in terms of code simplicity and runtime performance) way to store, dynamically refresh and execute their ...
user avatar
1 vote
0 answers
148 views

How could I generate a document that catalogs a collection of 3D models?

I have a lot of 3D models (.obj and .fbx) I can re-use in some games, but sometimes I forget them. So I want to create a (for instance) Word document with the images of all my 3D models. This can ...
user avatar
  • 847
3 votes
2 answers
2k views

How can I find out where a particular texture is being used in my Unity project?

I have a texture in my assets, and I need to find out where it's being used so that I can change some textures in my project. How can I find out where a specific texture is used in my project? The ...
user avatar
3 votes
0 answers
173 views

Unity - Loading Assets / Resources during run-time for a highly customizable game

I haven't had to think too much about this problem too much until now. I am in the middle of creating a character customization system for my game. There are 60+ characters in the game, I have ...
user avatar
0 votes
1 answer
672 views

Should I compress the game data files?

I am working on packaging my game resources into a single file. I have chosen the format but I don't know whether I should use compression or not. I understand the possible pros and cons: Compression ...
user avatar
0 votes
1 answer
114 views

How to hide fbx files for commercial release

I see that all commercial games I've played never expose their fbx files - usually, they archive the fbx files into PAK file or BIN file. For example, Torchlight 2 use OGRE3D for their Graphic Engine,...
user avatar
2 votes
1 answer
327 views

How can I manage resources in memory, and dispose of them at appropriate time with the Ashley framework?

I have been working on libGDX and the Ashley framework, and I have not been able to find any information on resource control in memory. I would like to know if there is any way to control those ...
user avatar
2 votes
0 answers
475 views

Set sprite for UI2DSprite from NGUI at runtime

How can I set sprite for UI2DSprite from NGUI at runtime? This is what I tried: ...
user avatar
1 vote
4 answers
2k views

Unity "static" references

I have been researching this for 2 days now and I cannot seem to find a proper response. I am trying to figure out a good way to store constant variables within my game. Basically, does it make more ...
user avatar
1 vote
2 answers
180 views

How should I manage meshes for the streets of a 3D city map in Unity?

I was recreating a small city in Unity3D and was going to place streets and pathways according to a sketch. I'm building for Android and the city is quite small; I'm planning to have the entire road ...
user avatar
  • 137
1 vote
1 answer
370 views

TextAsset thinks file is ~6856 bytes when it is 120123 bytes

So I've created a text asset in Unity of a binary file which i'm attempting to read in as a byte array. The result I'm getting is a byte array tht is almost half the size it's supposed to be. The ...
user avatar
  • 1,480
22 votes
4 answers
10k views

How do C++ games handle memory allocation failure?

I am aware of several games which are written in C++ but do not use exceptions. Since handling of memory allocation failure in C++ is generally built around the ...
user avatar
1 vote
2 answers
497 views

Instantiating without the use of Resource Folder in Unity?

I am making a game which has around 25 prefabs. I want to generate these prefabs randomly one after another and also I am destroying the last prefab. One way is to make an array of gameobjects and ...
user avatar
  • 11
1 vote
1 answer
257 views

Switching Screens without initializing them every time

I have a UI with four Screens (all extending a "main Screen") that users switch between very frequently, at the moment I am switching Screens using ...
user avatar
  • 1,863
6 votes
3 answers
3k views

How to implement a job queue system?

Essentially I'm trying to make a system which you can add a job to it then finds an AI which is idle and gives it that job to do, For an example look at Prison Architects job list system (image below)....
user avatar
  • 3,551
1 vote
1 answer
155 views

Resource management with Lua integration

I have a questions about how to better implement resource management when integrating with Lua. I have an entity system that has gameplay logic done in Lua. One of the design points was that I wanted ...
user avatar
  • 1,203
1 vote
2 answers
392 views

Reading mesh data back from OpenGL vs storing two copies

I'm wondering if whether it's a good idea or not to keep a copy of vertex data in the main memory or just read it back via glGetBufferSubData (or ...
user avatar
4 votes
2 answers
655 views

What is the Basic Game Screen/Scene Life Cycle?

Question What is the standard or basic game screen/scene life cycle used in most games? What is Screen/Scene? The term screen or scene refers to the current displayed entity holder where game ...
user avatar
  • 191
4 votes
1 answer
4k views

Resource streaming with job threading system

I am currently researching resource streaming for my current game engine. To add a bit of context, I am doing a contiguous world for a Baulder's Gate style CRPG. So while the camera is usually looking ...
user avatar
4 votes
2 answers
2k views

Is it a terrible practice to NOT initialize an object in its constructor?

I'm currently working on my own game engine, more precisely on the resources management part. For now, most of my assets inherits of the following - simplified - class: ...
user avatar
  • 999
0 votes
2 answers
118 views

How are Objects rendered or updated, when there's a Pool class?

I have a State (Title State for example), that has the ResourcePool (getImage();getSound(); etc.) and a list of the GameObjects. How do GameObjects get access to the Resources in the Pool they need? ...
user avatar
  • 641
0 votes
2 answers
236 views

Should I pass my resource manager to types that might need it, or make it global?

Say I have this Cache<typename Resource> class template, which is a resource cache that contains an ...
user avatar
  • 451
3 votes
1 answer
1k views

How should asset bundles be divided?

The only way to load an asset from an asset bundle into memory is to load the entire thing, decompress and pull out the asset you want, then unload the entire thing, except the assets you want. This ...
user avatar
  • 2,111
0 votes
0 answers
553 views

How heavy is a scene load in Unity assuming all referenced objects are in memory?

From what I understand, resources that are local to a particular scene( not a prefab, or texture, material asset etc ) are embedded in the scene file itself, while external resources are just ...
user avatar
  • 2,111
1 vote
1 answer
258 views

AssetManager proper usage in libgdx

I am a beginner in libgdx and I am coding a simple game. This game is like a word puzzle where each letter is a texture. Before loading the first level I need to load into memory 26 textures, one for ...
user avatar
  • 111
0 votes
1 answer
5k views

How can an asset bundle's resources be destroyed after destroying the compressed bundle data?

Using: AssetBundle.Unload( false ); Will clear the compressed asset bundle data. This, unfortunately, destroys the bundle object as well, which means nothing is ...
user avatar
  • 2,111
4 votes
1 answer
6k views

How does Unity load asset bundle dependencies and how can they be accessed?

Loading assets from an asset bundle is done explicitly. You give the bundle the name of the asset to load, then it returns it( either now or later. ) However, loading dependencies is done completely ...
user avatar
  • 2,111
0 votes
0 answers
88 views

Is resource management a good idea when dealing with animations?

New to the Unity environment here and I have a question concerning how to efficiently manage computer resources in a top down 2D game. I have a large area that looks like a 2d rpg from the 90's and ...
user avatar
  • 319
2 votes
1 answer
215 views

How many resources are too many?

I don't know if this question is too broad but I am finally working on a game I want to release and I find that questions like: "can I really add another 10 frames?", "Do I really need that animation?"...
user avatar
  • 1,863
7 votes
2 answers
4k views

C++ exensible resource manager class with dynamic registration of factories

I've done some some research on my own, so I hope someone can help me finish it. I'm trying to replicate the design of an extensible asset manager featured in this answer. At the moment I have ...
user avatar
  • 285
0 votes
1 answer
81 views

How to get used Resources by State/Map etc?

I'm now managing the Loading of my Resources and I got a Question in my mind. How does my Resource Manager know which Sprites,Sounds, etc. are used by the Map I want to load? First I thought of files ...
user avatar
  • 641
1 vote
1 answer
282 views

Texture organization and budgeting for a HD Sprite Based Game [closed]

I've been making a game that features 2 traditionally animated playable characters, hd backgrounds, props, and extra special effect animations. Things have gone well so far, but I have a few questions ...
user avatar
  • 160
1 vote
2 answers
1k views

How do I create a sound manager? [closed]

I have a basic entity system in place. Now I want to add audio. I want to make a database class that watches over entities, pulls data out of them, and creates audio streams whenever necessary. I'm ...
user avatar
0 votes
2 answers
1k views

Speed up loading of png files (used for textures) in Android OpenGL Game

My game has a few texture atlases that need to be loaded (in my XHDPI folder they total 3.49MB) and on a top-end device they don't take that long to load, however on a low-end device they seem to take ...
user avatar
  • 1,907