About Store Forum Documentation Contact



Post Reply 
Resource trouble?
Author Message
Esenthel Offline
Administrator

Post: #16
RE: Resource trouble?
Hi,

Please don't remove the element manually.

I'll update the "Erase Removed Elements" to remove all ELM_MESH, ELM_PHYS, ELM_SKEL that for some reason aren't referenced by any ELM_OBJ objects.

This will be available in the next release.
04-01-2016 06:06 AM
Find all posts by this user Quote this message in a reply
mizukami Offline
Member

Post: #17
RE: Resource trouble?
(04-01-2016 04:42 AM)Esenthel Wrote:  Can you please send me (by Email or Private Message) the "Data" file of your Project?

We discussed with our manager.
And then, because of our policy, file of the project cannot send outside of our office (in this case). File "Data" includes our project name (at directory), and so on.

Sorry...

(03-31-2016 07:11 PM)RedcrowProd Wrote:  did you tried to import the project, into a clean installation of EE ?

Done.
But nothing resolved... (i wonder)

Thank you.
(This post was last modified: 04-01-2016 11:57 AM by mizukami.)
04-01-2016 11:41 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #18
RE: Resource trouble?
Hi,

That's no problem, I understand.
Please wait for the next release with the updated "erase removed elements" function, as it will remove any unreferened ELM MESH elements.
I'll try to release it within 1-3 days.
Thank you
04-01-2016 10:31 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #19
RE: Resource trouble?
Hi,

The update is now available (both Binary and Source),
Please look here:
https://github.com/Esenthel/EsenthelEngi...roject.cpp
Code:
void Project::removeOrphanedElms()
   {
      Memt<UID> used;
      TimeStamp time; time.getUTC();

      // get all used meshes
      FREPA(elms) // go forward because most likely 'used' ID's will be increasing
      {
       C Elm &elm=elms[i]; if(C ElmObj *obj_data=elm.objData())used.binaryInclude(obj_data->mesh_id, Compare);
      }
      // remove unused meshes
      REPA(elms)
      {
         Elm &elm=elms[i]; if(elm.type==ELM_MESH && !elm.removed() && !used.binaryHas(elm.id, Compare))elm.setRemoved(true, time);
      }

      used.clear();
      
      // get all used phys
      FREPA(elms) // go forward because most likely 'used' ID's will be increasing
      {
       C Elm &elm=elms[i]; if(C ElmMesh *mesh_data=elm.meshData())if(mesh_data->phys_id.valid())used.binaryInclude(mesh_data->phys_id, Compare);
      }
      // remove unused phys
      REPA(elms)
      {
         Elm &elm=elms[i]; if(elm.type==ELM_PHYS && !elm.removed() && !used.binaryHas(elm.id, Compare))elm.setRemoved(true, time);
      }
   }

This is automatically called when clicking "Erase Removed Elements" from the menu.

This should remove any ELM_MESH elements that aren't referenced by any ELM_OBJ elements.

Please note, that if you want to use "Erase Removed Elements", it's recommended to:
-Disconnect all "Esenthel Editor" apps from "Esenthel Server"
-call "Erase Removed Elements" in "Esenthel Editor" on every developer machine
-call "Erase Removed Elements" on "Esenthel Server" app (by right-clicking on the project in the project list)
-after that you can re-connect to the Server.

Hope this helps.
04-02-2016 10:05 AM
Find all posts by this user Quote this message in a reply
mizukami Offline
Member

Post: #20
RE: Resource trouble?
Thank you very much!
04-04-2016 03:35 AM
Find all posts by this user Quote this message in a reply
Post Reply