[vlc-devel] [PATCH] Add new vulkan/libplacebo-based vout

Thomas Guillem thomas at gllm.fr
Wed Oct 3 09:48:40 CEST 2018


On Tue, Oct 2, 2018, at 16:28, Niklas Haas wrote:
> We can also do it like this:
> 
> vulkan
> ├── display.c
> ├── instance.c
> ├── instance.h
> ├── platform.h
> ├── platform_win32.c
> ├── platform_xcb.c
> └── surface.c
> 
> platform.h defines a platform common API like this:
> 
> // Initializes a platform-specific context to vk->sys
> int vlc_vk_InitPlatform(vlc_vk_t *);
> void vlc_vk_ClosePlatform(vlc_vk_t *);
> 
> // Contains the required platform-specific instance extension
> extern const char * const vlc_vk_PlatformExt;
> 
> // Create a vulkan surface to vk->surface
> int vlc_vk_CreateSurface(vlc_vk_t *);
> 
> Now that I've written the code I think I prefer it like this.

I think I prefer this one too, it is less prone to possible future hacks from platform specific. but I'm also OK about all solutions.

> Alternatively, we can have the implementation (i.e. the contents of
> platform_foo) live in the same file (surface.c), but grouped together
> into a single #ifdef rather than scattered across the file.
> 
> I have all three approaches written, let me know what you prefer.
> 
> On Tue, 02 Oct 2018 10:07:12 +0200, Thomas Guillem <thomas at gllm.fr> wrote:
> > 
> > 
> > On Mon, Oct 1, 2018, at 19:08, Rémi Denis-Courmont wrote:
> > > Hey,
> > > 
> > > As far as X11 is concerned, please stick to XCB. VLC only uses the piece of 
> > > legacy crap known as Xlib where unavoidable - and it is totally avoidable with 
> > > Vulkan.
> > > 
> > > Also split the X11 support code and the generic stuff.
> > 
> > What do you mean ? Split the commit or the file ? We decided to do like egl. One file for every protocol with ifdefs. 
> > 
> > > 
> > > -- 
> > > レミ・デニ-クールモン
> > > http://www.remlab.net/
> > > 
> > > 
> > > 
> > > _______________________________________________
> > > vlc-devel mailing list
> > > To unsubscribe or modify your subscription options:
> > > https://mailman.videolan.org/listinfo/vlc-devel
> > _______________________________________________
> > vlc-devel mailing list
> > To unsubscribe or modify your subscription options:
> > https://mailman.videolan.org/listinfo/vlc-devel


More information about the vlc-devel mailing list