Repository navigation
Releases: Unity-SeungwooLee/HiddenGeometryRemoval
Release list
Release v.0.3.0
v0.3.0: Improve camera coverage and add Small Islands cleanup
Camera setup
- Auto-compute camera FOV from the object's bounding sphere (1.2x margin)
instead of the default 50mm lens, which clipped large objects and
marked visible faces as hidden - Distribute cameras evenly between the poles; odd counts place a camera
on the equator so narrow vertical gaps (panel seams, door shuts) are seen - Cameras per Row: default 5, range 1-13 (was 4, 2-12 even only)
- Warn when camera distance is inside the object's bounding sphere
Small Islands
- Add standalone "Small Islands" sub-panel to select/delete loose mesh
islands whose world-space bounding-box diagonal is <= Max Island Size - Select Only toggle: select in Edit Mode for review, or delete directly
- Run After Removal option: remove small islands automatically after
Remove Hidden Geometry (Delete mode), after Merge by Distance - Works in Object Mode (each selected mesh) and Edit Mode (multi-object);
faces hidden with H are ignored
v0.2.1: Update HiddenGeometryRemoval.py
v0.2.1
Adds transparency-aware occlusion and a much faster ray casting backend.
Added
-
Ignore Transparent (on by default): meshes with a transparent material are
left untouched and no longer block visibility, so geometry seen through glass
survives the pass. A material counts as transparent when any of the following
holds:- the node tree contains a Glass, Transparent or Refraction BSDF
- a Principled BSDF has Alpha below 1.0, or Alpha driven by a link
- a Principled BSDF has Transmission above 0.0, or Transmission driven by a
link (both theTransmissionandTransmission Weightsocket names are
handled) - the material's render method is Blended (
surface_render_methodon 4.2+,
falling back toblend_methodon older builds) - the viewport display color has an alpha below 1.0
A linked alpha or transmission input is treated as transparent, since the
texture cannot be evaluated ahead of the pass and under-deleting is easier to
recover from than over-deleting. If any material slot on an object qualifies,
the whole object is treated as transparent.Excluding these objects from the merge is not enough on its own — they still
sit in the depsgraph and keep blocking rays. During the visibility pass the
add-on now also toggleshide_viewporton them, which drops them out of
depsgraph evaluation entirely, and restores the original state afterwards even
if the pass raises. -
Fast Ray Casting (on by default): builds a single
BVHTreefrom the
visible meshes and reuses it, instead of querying the whole scene for every
ray. The BVH is built from every visible mesh rather than just the target, so
occlusion behaves the same whether or not Merge Meshes is enabled. -
Threads: the visibility pass is now split across worker threads when Fast
Ray Casting is enabled.0uses every available core.Worker threads never touch Blender data. Sample points are extracted from the
BMesh on the main thread into plainVectorlists, and camera transforms are
flattened to position, direction and half-FOV beforehand. Workers only call
BVHTree.ray_castand hand back face indices; selection flags are written
back on the main thread.Experimental mode still runs single threaded — its flood fill depends on
selection state as it progresses, so parallelizing it would change results.
Notes
- Precomputing sample points raises peak memory use. In High precision a quad
contributes nine points, so very dense meshes will hold a large point list for
the duration of the pass. Low precision uses one point per face. - Uncheck Fast Ray Casting to fall back to the previous
scene.ray_castpath.
Release v.0.2.0
v0.2.0
Compatibility pass for Blender 5.x plus a round of bug fixes.
Compatibility
- Verified working on Blender 5.2. Minimum supported version raised to 4.2.
- Install via
Edit > Preferences > Add-ons > Install from Diskand select the
.pyfile. Single-file legacy add-ons are still supported in 5.x.
Fixed
- Outer Select mode left nothing visibly selected. Face selection was being
flushed in the wrong direction (vertices/edges to faces instead of faces to
vertices/edges), so the flags were written but never showed up in Edit Mode.
The add-on now flushes in face mode and drops into Edit Mode with the mesh
select mode set to Face, so the surviving geometry is selected and ready to
inspect or invert. - Camera cleanup deleted every camera in the scene, including the user's own.
Generated cameras are now tagged and only those are removed. The camera
collection was also renamed toHGR_Camerasto avoid clashing with an
existingCamerascollection. - Face statistics were read while in Edit Mode and reported stale counts.
- Cameras were always placed around the world origin, so objects away from
the origin were analyzed from the wrong angles. Placement now uses the
object's bounding box center. - Panel drew the "Number of Rows" block twice.
- The BMesh was not freed when an error occurred mid-run.
Added
- Auto Distance: derives camera distance from the object's bounding box.
Disable it to set the distance manually. - Merge Scope: choose between joining all visible meshes or only the
selected ones. poll()on the operator, so the button is greyed out without a mesh selected.
Changed
- The depsgraph is now fetched once per run instead of once per ray cast, which
noticeably speeds up high-precision passes on dense meshes. - Panel rewritten with
use_property_splitfor a more standard layout.
Release v0.1.3
Update Mesh Merging Options before Optimizing
Add "Merge Meshs" and "Merge By Distance" option. HiddenRemoval works well when the meshes are merged.
Release v0.1.2
Update Mesh Report and Experimental Function
Add Mesh Report after optimizing. User can see Info window (e.g. "Found 20/100 visible faces (80.0% removed)")
Add Experimental randomize mesh selection. Select randomize meshes in each cameras refer to "Face Sampling Ratio", Select near meshes according to "Flatness Angle" value. If angle increase, select more meshes nearby.
Release v0.1.1
Update Cameras UI
Add Camera On/Off UI as "Keep Cameras" bool.
Add "Cameras" collection when the user check "Keep Cameras" bool true.
Release v0.1.0
Update Camera Setting Logic
Control 'the number of Camera Splines' and 'the number of Cameras per Spline'.
Release v0.0.2
Update Delete/Outer Select dropdown UI, High/Low Precision dropdown UI