PDA

View Full Version : Nutcracker: New Effect, Pictures



smeighan
08-16-2012, 02:42 AM
A user contacted me with a problem he was having trying to layer a gif with the fire effect.

Long story short
1) Animated gifs cannot be used in layers, you should be using pictures
2) Oops, i hadnt finished the Pictures effect class. It is now done
3) I enhanced this effect so you can pick gif,png or jpg files
4) Each picture can be moved up,down,left,right,none. None means your picture will be stationary
5) New option for changing speed. I will retrofit most effects with speed. Speed=1 means each frame animation moves one pixel.
speed=.5, animation is twice as slow, speed=3, 3 times faster. Start with 1.0 and then play

So how does it work? Select the pictures class. Upload some images and then create effects.

So, first i will show that i solved the original problem. I must give credit to user frankr (from dla) for coming up with the idea to use the pirate image to overlay the fire.

Here is a fire effect on a matrix target
http://meighan.net/nutcracker/effects/workspaces/2/PHAR+FIRE3.gif

Here is a static gif (direction=none). NOTE: gifs in the picture class are different than animated gifs in the gif class. Gifs are ok here as long as they are not animated
Here is original gif
http://meighan.net/nutcracker/effects/pictures/2/sandbones.gif
and what it looks like when projected onto matrix
http://meighan.net/nutcracker/effects/workspaces/2/PHAR+SB.gif

and here is the layer between the two. Use the Skull and bones as a mask against the fire


http://meighan.net/nutcracker/effects/workspaces/2/PHAR+FIRE_SB.gif

what about the speed and direction options?

i will use this fractal for these tests:
http://meighan.net/nutcracker/effects/pictures/2/fract13.jpg

first test
direction = left, speed=1
http://meighan.net/nutcracker/effects/workspaces/2/A+PICT13_LEFT_SPEED1.gif

second test
direction=down, speed=1
http://meighan.net/nutcracker/effects/workspaces/2/A+PICT13_DOWN_SPEED1.gif

third test
direction=down, speed=2
http://meighan.net/nutcracker/effects/workspaces/2/A+PICT13_DOWN_SPEED2.gif

enjoy pictures!

sean

maffeirw
08-21-2012, 07:33 PM
1) Although I have added 2 jpg files to my library and they appear when I hit the link to add other pictures, when I try to enter the file name in the Pictures Effect they do not appear in the dropdown.

2) When I select a non-animated gif file from the pictures dropdown I get the following warnings (first two of many listed)
Warning: getimagesize(pictures/68/snoman.gif) [function.getimagesize]: failed to open stream: No such file or directory in /users/meighan.net/htdocs/nutcracker/effects/pictures.php on line 117

Warning: getimagesize(pictures/68/snoman.gif) [function.getimagesize]: failed to open stream: No such file or directory in /users/meighan.net/htdocs/nutcracker/effects/pictures.php on line 118

Effect Settings used:
username maffeirw
user_target MTH10S
effect_class pictures
effect_name SNOMAN
window_degrees 180
frame_delay 50
file1 snoman.gif
direction left
speed 1
seq_duration 5
fade_in n
fade_out n
submit Submit Form to create your effect
OBJECT_NAME picture

Processing file pictures/68/snoman.gif

smeighan
08-21-2012, 07:46 PM
1) Although I have added 2 jpg files to my library and they appear when I hit the link to add other pictures, when I try to enter the file name in the Pictures Effect they do not appear in the dropdown.

2) When I select a non-animated gif file from the pictures dropdown I get the following warnings (first two of many listed)
Warning: getimagesize(pictures/68/snoman.gif) [function.getimagesize]: failed to open stream: No such file or directory in /users/meighan.net/htdocs/nutcracker/effects/pictures.php on line 117

Warning: getimagesize(pictures/68/snoman.gif) [function.getimagesize]: failed to open stream: No such file or directory in /users/meighan.net/htdocs/nutcracker/effects/pictures.php on line 118

Effect Settings used:
username maffeirw
user_target MTH10S
effect_class pictures
effect_name SNOMAN
window_degrees 180
frame_delay 50
file1 snoman.gif
direction left
speed 1
seq_duration 5
fade_in n
fade_out n
submit Submit Form to create your effect
OBJECT_NAME picture

Processing file pictures/68/snoman.gif

You must upload your pictures to my linux server. I cannot see pictures that are on your local computer.
Here i have logged on to your account and their are no pictures shown in your image library
you need to click on the upload link shown in red circle

http://meighan.net/nutcracker/images/2012-08-21_1737.png

upload all pictures (static gif, png, jpg) that you want to use and they should then show up in your picture library.

I have copied over some of my pictures into your picture library. here is what your screen looks like now when you select the pictures effect

http://meighan.net/nutcracker/images/2012-08-21_1744.png


so try uploading your own pictures and verify they show up in your library

thanks
sean

maffeirw
08-22-2012, 09:10 AM
You must upload your pictures to my linux server. I cannot see pictures that are on your local computer.
Here i have logged on to your account and their are no pictures shown in your image library
you need to click on the upload link shown in red circle

upload all pictures (static gif, png, jpg) that you want to use and they should then show up in your picture library.

I have copied over some of my pictures into your picture library. here is what your screen looks like now when you select the pictures effect

so try uploading your own pictures and verify they show up in your library
thanks
sean

Thanks for the images you added to my Pictures Library they seem to work fine, but it appears that I am currently unable to add my own images to the Picture Library. I'm not sure if you use separate directories for the JPG vs. GIF images but when I attempt to add images to the Picture Library at the prompt in the Pictures Effect, I am taken to the GIF Addition Screen and the image is added to a GIF Library and is not accessible to the Picture Effect. They then show up only when I attempt to use the GIF Effect and not the Picture Effect.

PS: Is there anyway to delete images from the GIF and/or Pictures Library? There are too many files, most of which are not animated GIFs, in my GIF Library?

PPS: Thanks for Nutcracker it's a great addition to our sequencing arsenal.

smeighan
08-22-2012, 10:48 AM
Thanks for the images you added to my Pictures Library they seem to work fine, but it appears that I am currently unable to add my own images to the Picture Library. I'm not sure if you use separate directories for the JPG vs. GIF images but when I attempt to add images to the Picture Library at the prompt in the Pictures Effect, I am taken to the GIF Addition Screen and the image is added to a GIF Library and is not accessible to the Picture Effect. They then show up only when I attempt to use the GIF Effect and not the Picture Effect.

PS: Is there anyway to delete images from the GIF and/or Pictures Library? There are too many files, most of which are not animated GIFs, in my GIF Library?

PPS: Thanks for Nutcracker it's a great addition to our sequencing arsenal.

ok, i have fixed the upload from pictures pointing to gifs. this was a very subtle bug, give it a try now.

kychristmas
08-22-2012, 12:02 PM
I am getting an error when I try to use this function.

"Parse error: syntax error, unexpected '<' in /users/meighan.net/htdocs/nutcracker/effects/pictures.php on line 2"

maffeirw
08-22-2012, 12:27 PM
I can now load the images into the Nutcracker library but I am getting the same error as kychristmas when I attempt to use the Picture Effect.

Parse error: syntax error, unexpected '<' in /users/meighan.net/htdocs/nutcracker/effects/pictures.php on line 2

Ron

smeighan
08-22-2012, 03:34 PM
try it now,

(I should not try to work nutcracker while i am working my real job , *smile*)


....
sean

CaptKirk
08-22-2012, 03:38 PM
(I should not try to work nutcracker while i am working my real job )


Or while driving!!! :shock:

maffeirw
08-22-2012, 05:12 PM
The picture effect seems to be working fine at this point. Thanks

Do you have a prefered method of bug reporting or should we keep adding them to threads like this?

i.e. The text effect is working as a Mega Tree effect but when used on a vertical matrix the text scrolls from right to left and is backward. See the attachment.

angus40
08-22-2012, 05:20 PM
The picture effect seems to be working fine at this point. Thanks

Do you have a prefered method of bug reporting or should we keep adding them to threads like this?

i.e. The text effect is working as a Mega Tree effect but when used on a vertical matrix the text scrolls from right to left and is backward. See the attachment.


maffeirw , would you be willing to share the nutcracker file you have for this , i would like to do a test with it in hls .

I would need it as a .hls .

smeighan
08-22-2012, 05:33 PM
The picture effect seems to be working fine at this point. Thanks

Do you have a prefered method of bug reporting or should we keep adding them to threads like this?

i.e. The text effect is working as a Mega Tree effect but when used on a vertical matrix the text scrolls from right to left and is backward. See the attachment.
Post the bugs here in the threads. As long as I keep closing them in a few days, we are ok.

If we get to having so many that they start queuing up, then we will start bug tracking

I have seen almost a doubling in active users daily (from 20 to 40 users per day)

This is great, keep kicking the tires

kychristmas
08-22-2012, 05:52 PM
Post the bugs here in the threads. As long as I keep closing them in a few days, we are ok.

If we get to having so many that they start queuing up, then we will start bug tracking

I have seen almost a doubling in active users daily (from 20 to 40 users per day)

This is great, keep kicking the tires

I would suggest posting them in the correct threads. It will get very difficult for everyone involved if Text effect bugs are being placed in the Picture effect.

smeighan
08-22-2012, 05:56 PM
Yep, the only issue is if I miss one and it is till "open"

Let's keep it like this for at lest the next week or so. I read every thread posted to nutcrackers in 8 different forums. I check the forums every few hours.

kychristmas
08-22-2012, 06:53 PM
Eventhough I mentioned in my PM, I figured I would add this here so I can see if others are having the problems...

1. Selecting 180 deg actually seems to slice the image in half and then rotages that around the image. (Haven't tried 180 deg with a top or bottom direction)
2. Directions seems to be reversed. I choose Left and it goes right and vice-vera.

Again, excellent effect and tools. I'm real excited about learning how to tweak it. Please don't take my questions or comments as criticism. You have done an amazing job with your tool.

Kelly

smeighan
08-22-2012, 07:26 PM
Eventhough I mentioned in my PM, I figured I would add this here so I can see if others are having the problems...

1. Selecting 180 deg actually seems to slice the image in half and then rotages that around the image. (Haven't tried 180 deg with a top or bottom direction)
2. Directions seems to be reversed. I choose Left and it goes right and vice-vera.

Again, excellent effect and tools. I'm real excited about learning how to tweak it. Please don't take my questions or comments as criticism. You have done an amazing job with your tool.

Kelly

Np, bring on all comments it only makes the effect better.

left and right do seem backward.

I have just released a new Pictures class.
1) Now i resize your images in both x and y directions
2) I doubled the size of file you can upload , was 512K, now 1024Kb
3) If you have 180 degree window, i auto scale to $maxStrands * (window_size/360).
This means if you have 32 strands and 360 degrees, i autosize to 32 pixels wide. If you use the exact saqme target but have 180 degrees, i assume re-size image 16 pixels wide.

Here is image i started with
Penguins.jpg 1024x768 image size
http://meighan.net/nutcracker/effects/pictures/2/Penguins.jpg

First i use a 16x100 matrix where wach string is folded into two strands. This means this matrix will be 32x50. On matrix i will be using window_degrees = 360
Effect Settings
username f
user_target AA_MATRIX
effect_class pictures
effect_name PENGUIN_MATRIX_360
window_degrees 360
frame_delay 100
file1 Penguins.jpg
direction left
speed .5
seq_duration 5
fade_in 0
fade_out 0
submit Submit Form to create your effect
OBJECT_NAME picture

http://meighan.net/nutcracker/effects/workspaces/2/AA_MATRIX+PENGUIN_MATRIX_360.gif

Next i will switch target to 16x100 mega tree. Remember, my effects are target agnostic so i will just resubmit the same effect

Effect Settings
username f
user_target A
effect_class pictures
effect_name PENGUIN_MTREE_360
window_degrees 360
frame_delay 100
file1 Penguins.jpg
direction left
speed .5
seq_duration 5
fade_in 0
fade_out 0
submit Submit Form to create your effect
OBJECT_NAME picture
http://meighan.net/nutcracker/effects/workspaces/2/A+PENGUIN_MTREE_360.gif

This next is 180 degree window. This is NOT what i would expect it to do. only front half of the tree should show, and it should slide across front half.
http://meighan.net/nutcracker/effects/workspaces/2/A+PENGUIN_MTREE_180.gif

Finally, a 180 degree view on a matrix. Again, it should slide through half of the strands. It did resize image to half the strands (good), it just is sliding through whole width in the animated gif.
Effect Settings
username f
user_target AA_MATRIX
effect_class pictures
effect_name PENGUIN_MATRIX_180
window_degrees 180
frame_delay 100
file1 Penguins.jpg
direction left
speed .5
seq_duration 5
fade_in 0
fade_out 0
submit Submit Form to create your effect
OBJECT_NAME picture

http://meighan.net/nutcracker/effects/workspaces/2/AA_MATRIX+PENGUIN_MATRIX_180.gif

BillAd
08-22-2012, 08:21 PM
Hi Sean,

Is it possible to control the automatic resize? For me I would prefer images that appear on a portion of the display field rather than being stretched top to bottom. For example could we specify the number of pixels to size the picture and perhaps the starting pixel location? For example for a tree that has a 50 pixel string length one might indicate the picture is to occupy 10 of the 50 and be positioned at pixel 30.

Regardless thank you for all of these amazing options.

Bill