I have large compositions where I have kept the original layers / pre comps that I have since rendered out and reimported to speed up the final project output. Those layers are then hidden / "turned off" / shy.
I have kept them in the project so that I’m able to re-export those shy / hidden layers if I realise in the future that they need amending.
Would render times benefit by deleting these shy hidden layers?
From my tests it suggests that it doesn’t effect render times greatly but wondered what the coding “under the hood” is actually doing.
The AE render API does a number of prefetch tests based on the actual project structure and visibility (as would anyone writing a sensible render engine). There's nothing to worry about and removing items from the project doesn't yield any further gains. This would only make sense if you have e.g. cache-dependent effects like Warp Stabilizer and/ or something is really busted and slows down overall performance like a leaky effect, a corrupted cache or a messy expression reference to one of those invisible/ unused footage items.
Thanks for the reply, it is very useful to be able to keep the layers for future amends and know that it's not causing a lot of extra render time. In the past, whenever I have deleted a layer thinking it's of no more use, that usually ends up being one that I need to re render later on down the line 🙂
Once After Effects sees that a layer is hidden, it moves on to the next layer (shy or not shy).
The project will probably launch and save faster and probably render faster without the additional layers to keep track of, but I doubt that it would be significant enough to give up the convenicne of having those layers in the project should you want to make changes later.