summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1cb9a58)
raw | patch | inline | side by side (parent: 1cb9a58)
author | buliabyak <buliabyak@users.sourceforge.net> | |
Fri, 20 Oct 2006 06:59:40 +0000 (06:59 +0000) | ||
committer | buliabyak <buliabyak@users.sourceforge.net> | |
Fri, 20 Oct 2006 06:59:40 +0000 (06:59 +0000) |
src/display/nr-filter.cpp | patch | blob | history |
index 328b5c12aac2bf297c8e572c070bfdda8b4127ec..592623c495e0855a741be4b342e3aaced2bfd146 100644 (file)
int Filter::render(NRArenaItem const *item, NRPixBlock *pb)
{
+ if(!_primitive[0]) { // if there are no primitives, do nothing
+ return 0;
+ }
+
Matrix trans = *item->ctm;
FilterSlot slot(_slot_count, item);
NRPixBlock *in = new NRPixBlock;
slot.set(NR_FILTER_SOURCEGRAPHIC, in);
in = NULL; // in is now handled by FilterSlot, we should not touch it
- // TODO: loop through the primitives and render them one at a time
- if(_primitive[0])
- _primitive[0]->render(slot, trans);
-
+ // TODO: loop through ALL the primitives and render them one at a time
+ _primitive[0]->render(slot, trans);
NRPixBlock *out = slot.get(_output_slot);
// Clear the pixblock, where the output will be put