Movie Sprites
- PyTom
- Ren'Py Creator
- Posts: 16096
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: Movie Sprites
That's off-topic for this thread, which is about Movie sprites. It isn't clear what your first example even means, and the second has nothing to do with a Movie sprite.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
Software > Drama • https://www.patreon.com/renpytom
- ketskari
- Veteran
- Posts: 296
- Joined: Tue Dec 21, 2010 6:22 pm
- Completed: Asher, Sunrise, Tell a Demon
- Projects: Asher Remake, TEoA
- Organization: Sun Labyrinth
- Tumblr: sunlabyrinth
- Deviantart: sunlabyrinth
- itch: sunlabyrinth
- Contact:
Re: Movie Sprites
I took an animation I'd made in Blender, then converted to webM to try it out. After a few seconds it crashed on me, but omg still really looking forward to this feature. It looks great!
(Also, in the latest nightly, defined im.composites sometimes seem to revert to the default placeholder images).
(Also, in the latest nightly, defined im.composites sometimes seem to revert to the default placeholder images).
- PyTom
- Ren'Py Creator
- Posts: 16096
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: Movie Sprites
Can you send it to me?
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
Software > Drama • https://www.patreon.com/renpytom
- curry nochi rice
- Miko-Class Veteran
- Posts: 746
- Joined: Sat Mar 27, 2010 3:12 am
- Projects: Delicatessen, Whom to Notice, Start of Something, Love Sorcery
- Organization: Circle Cosine
- IRC Nick: Curry
- Skype: after.curry.rice
- itch: project-rothera
- Contact:
Re: Movie Sprites
Hi PyTom, I'm wondering how you create sequences of movie sprites in code... e.g. "[heavy_breathing, normal_breathing]". Also, how to disable the auto-loop behavior since I wouldn't want the sprite to heavy_breathing again.PyTom wrote:Yes, things will loop by default. Obviously, you'd have to loop the animation proper - Ren'Py should just seamlessly play frames.Voight-Kampff wrote:So I'm wondering if we can generate sequences that can be looped in which the sprite constantly moves just a little bit—just a little bit of sway or shifting of their weight, etc.
Or should I just wait for the documentation to appear? Hahaha. Sorry, I'm just too excited for this.
Re: Movie Sprites
A question if I may:PyTom wrote:Thanks to renoa-heartily for the animated gif I converted, which can be found in this thread: http://lemmasoft.renai.us/forums/viewto ... 79#p364740
How did you create the mask movie of that .gif (changed white background to black and all other colors to white)? What software was used or even how to phrase such a question properly for google would be of a great help, cause I cannot figure even that out.
- nyaatrap
- Crawling Chaos
- Posts: 1824
- Joined: Mon Feb 13, 2012 5:37 am
- Location: Kimashi Tower, Japan
- Contact:
Re: Movie Sprites
Using ffmpeg, I tested this code and works
To make a mask from png sequence (0000.png-) is
Code: Select all
ffmpeg -i image.gif -filter:v alphaextract mask.webm
Code: Select all
ffmpeg -r 24 -i %4d.png -filter:v alphaextract mask.webm
Re: Movie Sprites
Domo arigato! I'll try this tonight.nyaatrap wrote:Using ffmpeg, I tested this code and worksTo make a mask from png sequence (0000.png-) isCode: Select all
ffmpeg -i image.gif -filter:v alphaextract mask.webm
Code: Select all
ffmpeg -r 24 -i %4d.png -filter:v alphaextract mask.webm
- nyaatrap
- Crawling Chaos
- Posts: 1824
- Joined: Mon Feb 13, 2012 5:37 am
- Location: Kimashi Tower, Japan
- Contact:
Re: Movie Sprites
I think ffmpeg should be documented somewhere. I couldn't find other free applications that can make a mask video file. (except commercial applications like Adobe AE)
Re: Movie Sprites
There are some examples on stack overflow (now I know that ffmpeg can be used for this, searching is easier). You command line works perfectly btw, many thanks (again).
- nyaatrap
- Crawling Chaos
- Posts: 1824
- Joined: Mon Feb 13, 2012 5:37 am
- Location: Kimashi Tower, Japan
- Contact:
Re: Movie Sprites
Oh, I mean somewhere in ren'py official document, at least mention that ffmpeg is suited. I think It's rare who knows about videos in ren'py user. Most users have no clue where to find, then spend many time on random googling (that's what I did).
- curry nochi rice
- Miko-Class Veteran
- Posts: 746
- Joined: Sat Mar 27, 2010 3:12 am
- Projects: Delicatessen, Whom to Notice, Start of Something, Love Sorcery
- Organization: Circle Cosine
- IRC Nick: Curry
- Skype: after.curry.rice
- itch: project-rothera
- Contact:
Re: Movie Sprites
Basically, it's still export to .gif > convert to .webm > get alphamask from .gif
Code: Select all
#give epsilon-idle.gif, in ffmpeg that would be
ffmpeg -i epsilon-idle.gif -c:v libvpx -crf 4 -b:v 500K epsilon-idle.gif
ffmpeg -i epsilon-idle.gif -filter:v alphaextract epsilon-idle-mask.webm
- nyaatrap
- Crawling Chaos
- Posts: 1824
- Joined: Mon Feb 13, 2012 5:37 am
- Location: Kimashi Tower, Japan
- Contact:
Re: Movie Sprites
I think png is the best. Gif loses its quality many, mov also loses a bit. That's why I wrote how to make a video from png by ffmpeg.
- curry nochi rice
- Miko-Class Veteran
- Posts: 746
- Joined: Sat Mar 27, 2010 3:12 am
- Projects: Delicatessen, Whom to Notice, Start of Something, Love Sorcery
- Organization: Circle Cosine
- IRC Nick: Curry
- Skype: after.curry.rice
- itch: project-rothera
- Contact:
Re: Movie Sprites
Oh, sequential order. Do I need to do that like one by one or just that one line?nyaatrap wrote:I think png is the best. Gif loses its quality many, mov also loses a bit. That's why I wrote how to make a video from png by ffmpeg.
- nyaatrap
- Crawling Chaos
- Posts: 1824
- Joined: Mon Feb 13, 2012 5:37 am
- Location: Kimashi Tower, Japan
- Contact:
Re: Movie Sprites
-r 24 -i %4d.png will read 0000.png, 0001.png, 0002.png, .... then combine into one file with 24 framerate. You have to run ffmpeg two times for one motion: from pngs to real.webm, from pngs to mask.webm.
- curry nochi rice
- Miko-Class Veteran
- Posts: 746
- Joined: Sat Mar 27, 2010 3:12 am
- Projects: Delicatessen, Whom to Notice, Start of Something, Love Sorcery
- Organization: Circle Cosine
- IRC Nick: Curry
- Skype: after.curry.rice
- itch: project-rothera
- Contact:
Re: Movie Sprites
nyaatrap wrote:-r 24 -i %4d.png will read 0000.png, 0001.png, 0002.png, .... then combine into one file with 24 framerate. You have to run ffmpeg two times for one motion: from pngs to real.webm, from pngs to mask.webm.
ffmpeg has a default 25 fps setting to it. Anyway, the result of this afternoon's test after Nyaatrap's reply. Please forgive the dialogue, I was pretty much raging while doing this.
Edit:
I wrote a tutorial about it, check it here.
Who is online
Users browsing this forum: No registered users