Jump to content

  • Log In with Google      Sign In   
  • Create Account


About vertex buffer copy


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 zonozz   Members   -  Reputation: 158

Like
0Likes
Like

Posted 15 February 2013 - 12:10 PM

Hi everyone, I'm a beginer of DirectX 11.I'm now coding for <Models manager>. I just use linear list to save loaded models, and I created 2 classes, one is "Model", another is "Models Manager", what I think is people can choose use manager or not, for example somewhere may be you want use model for 1 second ?

 

Question is :

 

1.I use class "Model" to create a object, and there must vertex data & index data in it. Now I should copy these data to "Model list" node, how to copy these data ?

 

2.Am I doing a right design ? Please tell me if I think in wrong way.

 

 

Thanks a lot !



Sponsor:

#2 PhillipHamlyn   Members   -  Reputation: 445

Like
0Likes
Like

Posted 15 February 2013 - 12:41 PM

Zonozz,

 

If you are asking "should I embed a reference to my Model class instance into my ModelManager Models list" and save it as a single file, I would say "no". Give a unique reference code to your Model instance, and keep a copy of that unique code in your ModelManager using list of model codes. This enables you to load and save the models and model manager seperately, as needed.

 

It this isn't what you are asking, then feel free to re-phrase your question - I maybe haven't understood what problem you are trying to solve.



#3 zonozz   Members   -  Reputation: 158

Like
0Likes
Like

Posted 15 February 2013 - 01:04 PM

Zonozz,

 

If you are asking "should I embed a reference to my Model class instance into my ModelManager Models list" and save it as a single file, I would say "no". Give a unique reference code to your Model instance, and keep a copy of that unique code in your ModelManager using list of model codes. This enables you to load and save the models and model manager seperately, as needed.

 

It this isn't what you are asking, then feel free to re-phrase your question - I maybe haven't understood what problem you are trying to solve.

 

Thanks for replying.

 

I'm now coding a ModelsManager, but before this I created a class named "Model" for saving 1 model temporary, now I want to add this temporary model to the manager's model list, when I try to copy vertex buffer & index buffer, I got memory error. And Im not mean saving model in single file, I mean should Engine forces users use models by manager ? I'm not sure this idea is in general.






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS