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.
100
questions
0
votes
1
answer
71
views
Using Game Engine (or parts of it) In Commercial Application?
This is a difficult question, as it is not related to game development directly: we are currently evaluating, if an existing game implementation (game engine or part of it) may fulfill the needs for a ...
0
votes
1
answer
186
views
"An ID3D12Resource object is referenced by GPU operations in-flight on Command Queue": When Should I Create my Buffers?
When trying to re-create my vertex buffers, my app crashes and I get this error:
D3D12 ERROR: ID3D12Resource2::: CORRUPTION: An ID3D12Resource object (0x000001DDEBA98FC0:'Vertex Buffer Default ...
0
votes
0
answers
64
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 ...
0
votes
1
answer
121
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 ...
0
votes
1
answer
638
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 ...
0
votes
1
answer
2k
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, ...
4
votes
1
answer
918
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 ...
0
votes
0
answers
109
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 ...
1
vote
1
answer
60
views
What is the difference between cudaExternalMemoryHandleTypeD3D12Resource and cudaExternalMemoryHandleTypeD3D12Heap?
When we import a D3D12 memory object into cuda we do something like this:
...
1
vote
3
answers
414
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:
...
2
votes
3
answers
440
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 "...
2
votes
2
answers
3k
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
...
1
vote
1
answer
349
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 ...
0
votes
0
answers
500
views
Why are pyglet.image and texture so heavy?
Envrionment:
python: 3.6.6
pyglet: 1.3.2
Here is my code and results:
...
0
votes
1
answer
110
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 ...
0
votes
1
answer
53
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?
1
vote
0
answers
191
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 <...
2
votes
3
answers
1k
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++ (...
0
votes
2
answers
254
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 ...
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 ...
3
votes
2
answers
3k
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 ...
3
votes
0
answers
174
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 ...
0
votes
1
answer
1k
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 ...
0
votes
1
answer
128
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,...
2
votes
1
answer
388
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 ...
2
votes
0
answers
541
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:
...
1
vote
4
answers
3k
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 ...
1
vote
2
answers
240
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 ...
1
vote
1
answer
445
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 ...
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 ...
1
vote
2
answers
570
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 ...
1
vote
1
answer
266
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 ...
1
vote
1
answer
180
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 ...
1
vote
2
answers
480
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 ...
4
votes
2
answers
852
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 ...
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 ...
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:
...
0
votes
2
answers
121
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?
...
0
votes
2
answers
268
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 ...
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 ...
0
votes
0
answers
558
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 ...
1
vote
1
answer
270
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 ...
0
votes
1
answer
6k
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 ...
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 ...
0
votes
0
answers
89
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 ...
2
votes
1
answer
234
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?"...
7
votes
2
answers
5k
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 ...
0
votes
1
answer
84
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 ...
1
vote
1
answer
298
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 ...
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 ...