# Is there a way to determine concatenated filters?

**URL:** https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284
**Category:** flash
**Created:** [April 18, 2015, 6:44pm UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284 "2015-04-18T18:44:28Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Scythe](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/scythe/32/7239_2.png) [@Scythe](https://forum.kirupa.com/u/Scythe)
#### Post date: [April 18, 2015, 6:44pm UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284/1 "2015-04-18T18:44:28Z")

</div>

I want to be able to take a symbol that may be buried in a parent/child chain and add it to the stage or the root and have it look the same. The properties transform.concatenatedColorTransform and transform.concatenatedMatrix and the localToGlobal method make this mostly pretty easy. But is there a similar way of getting all the filters that are passed down to an object? Thanks in advance.

---

<div class="post-metadata">

### Author: ![Scythe](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/scythe/32/7239_2.png) [@Scythe](https://forum.kirupa.com/u/Scythe)
#### Post date: [April 18, 2015, 7:36pm UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284/2 "2015-04-18T19:36:40Z")

</div>

Looks like this is easier than I thought it would be just using custom code like this:

```
var ancestor:DisplayObjectContainer = parent;
while (ancestor && ancestor != root) {
	filters = filters.concat(ancestor.filters);
	ancestor = ancestor.parent;
}

```

Still curious to hear if there’s another way though.

---

<div class="post-metadata">

### Author: ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)
#### Post date: [April 19, 2015, 2:04am UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284/3 "2015-04-19T02:04:32Z")

</div>

There’s nothing similar to `concatenatedMatrix`, if that’s what you mean. Also concatenatedMatrix is itself not entirely dependable. There were some failure points for that (unless they got fixed) that would require walking up the hierarchy like with what you’re doing for filters.

---

<div class="post-metadata">

### Author: ![Scythe](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/scythe/32/7239_2.png) [@Scythe](https://forum.kirupa.com/u/Scythe)
#### Post date: [April 20, 2015, 2:42am UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284/4 "2015-04-20T02:42:27Z")

</div>

Yeah, that’s what I meant. Thanks. 🙂

Oh, but what are the failure points of concatenatedMatrix?

---

<div class="post-metadata">

### Author: ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)
#### Post date: [April 20, 2015, 5:03pm UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284/5 "2015-04-20T17:03:30Z")

</div>

> [@Scythe](#):
>
> Oh, but what are the failure points of concatenatedMatrix?

I was afraid you were going to ask that haha. I wanted to say things dealing with cache as bitmap can cause problems since the hierarchy is flattened into an image, but this also happens with filters (filters are applied as bitmaps) and since you’re using those, that might not be it. Could be related to 2.5D transforms… Hmm. Ok, I did find this:

[https://bugbase.adobe.com/index.cfm?event=bug&id=2927826](https://bugbase.adobe.com/index.cfm?event=bug&id=2927826)

So maybe I was right the first time. I remember talking to someone about this not to long after we implemented this stuff, and I got the impression that this was FOL and not worth trying to fix it so that the implementation details were hidden in this case.

---

<div class="post-metadata">

### Author: ![Scythe](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/scythe/32/7239_2.png) [@Scythe](https://forum.kirupa.com/u/Scythe)
#### Post date: [April 21, 2015, 3:57am UTC](https://forum.kirupa.com/t/is-there-a-way-to-determine-concatenated-filters/621284/6 "2015-04-21T03:57:17Z")

</div>

You know, I actually discovered that bizarre bug in my tests! Getting different results depending on whether there was a filter and therefore depending on whether there was cacheAsBitmap. But it looks like the only values that are off are the coordinates, so I can get around it with localToGlobal.
