|
Sweet Home 3D Forum » List all forums » » Forum: Sweet Home 3D bar » » » Thread: Options to recover corrupted files » » » » Post: Options to recover corrupted files |
Print at Dec 17, 2025, 4:38:45 AM |
| Posted by Puybaret at May 5, 2014, 6:54:18 PM |
|
Options to recover corrupted files Hi, I need your help to help me choose the best tradeoff to recover corrupted Sweet Home 3D files. By corrupted, I mean the files that were correctly saved but which data changed afterwards because of a bad file transfer, a bad handling of the user or a hard disk failure, and that Sweet Home 3D refuses to open. As a .sh3d file is actually some kind of a ZIP file containing other files, some ZIP tools are quite often able to extract some of the files of a corrupted .sh3d file (but not all), like the Home entry that describe furniture, walls and rooms, the furniture 3D models and the texture images. If the Home entry is corrupted, Sweet Home 3D can't display anything, but if it's correct (and most of the time, it is from the files I had to fix), the "only" missing data will be some 3D models or images. Nowadays, when a user request me to fix a corrupted .sh3d file, I run some kind of ZIP tool I programmed that is able to extract all the correct files it contains, remove the furniture with a missing 3D model, remove references to missing images, and save a correct .sh3d file with the remaining information. As this tool works pretty well (even if the corrupted data is lost), I'd like to add it to Sweet Home 3D to let users repair their file by themselves. But instead of adding it as a new menu item, I propose to simply run it during an Open operation when it fails. Thus, if the user tries to open a corrupted file, instead of getting a simple error message, his file will be opened if it's partially valid, displaying only the valid data and an error message about the corrupted data. To avoid a wrong loss of the corrupted file, the user would have to confirm he wants to write over it when he saves his home later. What do you think of this behavior? What should display the error message to avoid any misleading (note that it could list the lost furniture and textures)? But I could do better in a future version: as a valid Home entry of a .sh3d file contains also furniture and textures names and their id (when it exists), the program could explore the furniture and textures catalog used by a Sweet Home 3D user, and try to reassign the lost 3D models and images to the matching ones found in the catalog. Doing this is also risky because ids and names could have changed between the currently running instance of Sweet Home 3D and the instance that was used when the .sh3d file was saved before getting corrupted. An other behavior could be also to replace missing 3D models by red (or an other color) boxes and images by a red color to let the user better view which 3D models couldn't be retrieved… What do you think? Thanks for your help... ---------------------------------------- Emmanuel Puybaret, Sweet Home 3D creator |
|
|
Current timezone is GMT Dec 17, 2025, 4:38:45 AM |