It turns out my svg was bad formed. It loads svg just fine.

Thank you both.

El mar, 28 dic 2021 a las 22:42, Brian Matherly (<brian.mathe...@yahoo.com>)
escribió:

> var pro:Producer = newFactoryProducer(p, null,
> "./resources/pexels-pixabay-97082.jpg")
> var pro:Producer = newFactoryProducer(p, null,
> "./resources/pexels-pixabay-97082.svg")
>
> The loader will figure out the best producer based on the file type.
>
> The heuristic is here:
>
> https://github.com/mltframework/mlt/blob/master/src/modules/core/loader.dict
>
> ~Brian
>
>
> On Tuesday, December 28, 2021, 02:56:23 PM CST, José María García Pérez <
> josemaria.alk...@gmail.com> wrote:
>
>
> And in order to load .svg files? How should I do it?
>
> El mar, 28 dic 2021 a las 21:53, José María García Pérez (<
> josemaria.alk...@gmail.com>) escribió:
>
> So, if I get it, I should just use "loader" as the producer for most (all)
> the cases. Is that correct?
>
> El mar, 28 dic 2021 a las 17:05, Dan Dennedy (<d...@dennedy.org>) escribió:
>
> You have not included any pixel format or color space converter, and sdl2
> does not support rgb. By specifying the producer class as an argument you
> bypass the loader producer, which is special.
>
>
> On Tue, Dec 28, 2021 at 11:01 AM José María García Pérez <
> josemaria.alk...@gmail.com> wrote:
>
> I am playing with pixbuf, but the colours I get are off:
> https://i.imgur.com/DhuBrir.png
> while I was expecting: https://i.imgur.com/p8yTx2W.jpg
>
> The code that I am using (in Nim, but readable):
>
> # nim c -r --threads:on ex02_show_red_window
> import mlt
> import os
>
> var f:Repository = initFactory("/usr/lib/mlt-7")
>
> # Create the default consumer
> var p:Profile = newProfile() #mlt_profile_init(nil)
> var sdl:Consumer = newFactoryConsumer(p, "sdl2")
> sdl["terminate_on_pause"] = 1 # Stop the consumer when finished
>
> var pro:Producer = newFactoryProducer(p, "pixbuf",
> "./resources/pexels-pixabay-97082.jpg")
>
> connect( sdl, pro )
>
> # Start the consumer
> sdl.start
>
> while not stopped( sdl ):
> sleep(1)
>
>
> I have two questions:
> 1. What can I do in order to get proper colours?
> 2. How can I scale the image to fit the profile's size?
>
> Kind regards (and have Christmas holidays!)
> _______________________________________________
> Mlt-devel mailing list
> Mlt-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mlt-devel
>
> _______________________________________________
> Mlt-devel mailing list
> Mlt-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mlt-devel
>
_______________________________________________
Mlt-devel mailing list
Mlt-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mlt-devel

Reply via email to