Switch to DuckDuckGo Search
   July 28, 2019  
< | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | >

Toggle Join/Part | bottom
[00:02:54] <mirv_> not sure I fully follow; multiple textures and mixing their values is normal in shaders
[00:03:38] <felipealmeida> not just mixing, but instead of issuing multiple draw commands, one single command, and the frag shader draw the texture in the right position etc
[00:04:12] <felipealmeida> I'm writing a wayland compositor in vulkan, and I'm experimenting with some ideas
[00:04:48] <felipealmeida> I could have a SBO having the information on how to draw everything, and then draw that with a single VkCmdDraw
[00:05:11] <mirv_> like indirect draw?
[00:05:31] <felipealmeida> like, but instead of running the frag shader multiple times for each pixel, doing only once
[00:05:39] <felipealmeida> and doing the compositing in the frag shader
[00:06:56] <mirv_> indirect draw doesn't run the frag shader multiple times
[00:07:10] <felipealmeida> it does if I draw multiple instances, doesn't it?
[00:07:11] <mirv_> for a given triangle, I mean
[00:07:30] <felipealmeida> a compositor, with alpha blending, would have to draw multiple textures in the same place
[00:07:37] <felipealmeida> that's what I mean by multiple draws
[00:07:51] <mirv_> ok
[00:09:27] <mirv_> is there a real problem with multiple cases though?
[00:09:38] <felipealmeida> multiple draws?
[00:09:42] <mirv_> yes
[00:09:50] <felipealmeida> yes, sure, it is a graphical toolkit library too
[00:10:12] <felipealmeida> so, alpha blending on text is almost required for example
[00:11:24] <felipealmeida> but if it doesn't happen in a specific case, then it would not be a problem by using a frag shader too, except maybe having to handle coordinates to textures
[00:11:33] <felipealmeida> maybe a specific draw would be easier
[00:13:01] <felipealmeida> I was thinking of having, instead of a depth buffer, a SBO with a index to a "chain"
[00:13:15] <felipealmeida> the chains would be registered showing the order of draws
[00:13:54] <mirv_> that would almost have to be per-pixel though, wouldn't it?
[00:14:01] <felipealmeida> it would have to be per pixel
[00:14:04] *** LunarJetman <LunarJetman!LunarJetma@176.248.197.112> has left ##vulkan
[00:14:14] <felipealmeida> but I wouldn't have to calculate if a rect overlaps which windows
[00:14:20] <felipealmeida> the frag shader would do this implicitly
[00:14:48] <felipealmeida> but I'm not sure if this would speed things up, or maybe raise latency or something
[00:14:58] <felipealmeida> the idea is running this on mobile too, like MALI GPUs
[00:15:29] <mirv_> you'd basically have to stream updates through per-pixel, possibly per-frame
[00:15:36] <mirv_> that'd slow things down a lot
[00:15:56] <felipealmeida> I don't need to change the pixel buffer
[00:16:00] <mirv_> and limit the overlap to whatever you can chain support
[00:16:22] <felipealmeida> well, I may if things move, ofc, but then I can update the pixel with another shader
[00:16:43] <felipealmeida> that would keep the buffer in device memory
[00:17:02] <felipealmeida> I would only draw on "damaged" parts of the screen
[00:17:31] <mirv_> no reason you can't do that normally, just scissor off the areas marked as dirty
[00:17:51] <felipealmeida> would do exactly that
[00:18:14] <felipealmeida> already do that too
[00:18:40] <felipealmeida> but right now I have to choose the right commandbuffers based on overlap of rectangles
[00:18:43] <felipealmeida> that runs in CPU
[00:18:57] <felipealmeida> want to do that in GPU
[00:19:32] <felipealmeida> I already know the "damaged parts", I could just issue the drawcmd and let the shader do everything
[00:19:54] <felipealmeida> just give a SBO with window positions, etc
[00:21:08] <mirv_> are the window contents already rendered to a texture?
[00:22:01] <felipealmeida> yes for the compositor, and for the gui toolkit, yes too
[00:22:22] *** felipealmeida <felipealmeida!~user@191.191.10.198> has quit IRC (Remote host closed the connection)
[00:24:22] *** felipealmeida <felipealmeida!~user@191.191.10.198> has joined ##vulkan
[00:24:57] <mirv_> well order independent transparency could use forms of linked lists from what I've read (not personally played around with it myself)
[00:25:36] <felipealmeida> I already have explicit ordering for zindex
[00:25:55] <mirv_> but...I think wouldn't gain much there over just sorting by depth on the cpu, cull what can be culled, and multiple quad draws
[00:26:16] <felipealmeida> offloading CPU on mobile is always a good thing
[00:26:48] <bnieuwenhuizen> yeah, sorting by depth on the CPU is easy typically because a compositor won't have tons of iwndows?
[00:26:51] <felipealmeida> but yeah, profiling is probably the only way to know
[00:27:11] <bnieuwenhuizen> and then draw front to back with a depth buffer or stencil buffer
[00:27:12] <felipealmeida> bnieuwenhuizen: true, but that would be true for the GPU too
[00:27:31] <felipealmeida> I don't have to re-record buffers too
[00:27:39] <felipealmeida> just map, write, unmap, run
[00:28:00] <bnieuwenhuizen> same for drawindirect
[00:28:20] <felipealmeida> yeah, that's something I'm not convinced is a good thing to reimplement
[00:28:34] <bnieuwenhuizen> reimplement?
[00:28:58] <felipealmeida> I can use indirect to draw multiple damage rectangles
[00:29:11] <felipealmeida> and in each damage rectangle, do alpha compositing in the frag sahder
[00:29:13] <felipealmeida> shader*
[00:29:33] <felipealmeida> or I can indirect draw for each texture that needs alpha compositing in each damage rectangle
[00:29:44] <felipealmeida> and let the gpu do the alpha compositing itself
[00:30:57] <felipealmeida> acessing the texture by index
[00:31:52] <bnieuwenhuizen> hmm, might be worth splitting each damage rectangle into a separate draw + set the scissor and/or start a new renderpass? I don't know about Mali, but for Qualcomm Adreno chips you might be risking loading the entire framebuffer into and out of tile memory
[00:32:37] <felipealmeida> hmm, new renderpass means re-recording buffers, wouldn't that be a bit expensive?
[00:32:55] <bnieuwenhuizen> felipealmeida: you need to profile the tradeoff I guess
[00:33:07] <felipealmeida> would it load the framebuffer before evaluating the positions in vertex shader?
[00:33:38] <bnieuwenhuizen> thing is on Adreno, the tiles do not get loaded on demand, but the driver has to program it at commandbuffer record time
[00:33:55] <felipealmeida> ah, I see
[00:34:02] <bnieuwenhuizen> so unless you specify strict scissor or renderpass size it will load & store entire framebuffer
[00:34:26] <bnieuwenhuizen> as for whether that is worth avoiding the cmdbuffer recording is probably something only a benchmark can answer
[00:34:39] <felipealmeida> and command buffer can be recorded in another thread
[00:35:26] <felipealmeida> right now I do re-record it
[00:35:47] <felipealmeida> so I can use a specific renderArea
[00:38:33] <felipealmeida> binding 4096 descriptors in each command buffer recording would be slow?
[00:39:55] <bnieuwenhuizen> in a single descriptor set/draw?
[00:40:13] <felipealmeida> yes
[00:40:31] <felipealmeida> like 4096 textures in the same descriptorset
[00:40:37] <bnieuwenhuizen> just remember not every driver might support that many descriptors in a single set
[00:41:27] <felipealmeida> have to check the minimum limit
[00:42:50] <bnieuwenhuizen> minimum is 16 per shader stage
[00:43:20] <felipealmeida> that's very low
[00:43:31] <bnieuwenhuizen> yup
[00:43:32] <felipealmeida> I thought it was 80
[00:43:52] <bnieuwenhuizen> so it is 96 per descriptor set, but you only might be able to use 16 of them for the same stage
[00:44:20] <felipealmeida> using you mean having access?
[00:44:26] <felipealmeida> or having available?
[00:44:26] <bnieuwenhuizen> yeah
[00:45:02] <bnieuwenhuizen> Look at maxPerStageDescriptorSampledImages
[00:45:09] <felipealmeida> accessing more than 16 textures in the same stage is unlikely, but possible
[01:05:13] *** felipealmeida <felipealmeida!~user@191.191.10.198> has quit IRC (Remote host closed the connection)
[01:28:38] *** felipealmeida <felipealmeida!~user@191.191.10.198> has joined ##vulkan
[01:31:10] <felipealmeida> bnieuwenhuizen: raw images would have the same limit?
[01:31:13] <felipealmeida> mali has 16 limit
[01:34:27] <bnieuwenhuizen> yup
[01:34:34] <bnieuwenhuizen> storage images is even lower
[01:36:34] <felipealmeida> coul VK_DESCRIPTOR_POOL_CREATE_UPDATE_AFTER_BIND_BIT_EXT help? I can't see what the limits may be with this flag
[01:39:21] <bnieuwenhuizen> not higher
[01:39:33] <bnieuwenhuizen> also need VK_EXT_descriptor_indexing
[01:40:49] <bnieuwenhuizen> well, technically there is a command that can check if a descriptor set layout would be valid. Technically that can return ok for higher values than specified the device limits, but not guarantueed and don't expect magic
[01:47:51] *** felipealmeida <felipealmeida!~user@191.191.10.198> has quit IRC (Remote host closed the connection)
[02:07:38] *** Deluxe <Deluxe!~Deluxe@212.4.150.151> has quit IRC (Remote host closed the connection)
[03:21:34] *** pa <pa!~pa@unaffiliated/pa> has quit IRC (Ping timeout: 246 seconds)
[03:33:58] *** pa <pa!~pa@unaffiliated/pa> has joined ##vulkan
[03:34:58] *** ratchetfreak <ratchetfreak!~ratchetfr@ptr-82s3g7l9r42569r41f4.18120a2.ip6.access.telenet.be> has quit IRC (Ping timeout: 276 seconds)
[04:10:40] *** David3k <David3k!~David3k@120.29.75.241> has joined ##vulkan
[04:15:28] *** David3k <David3k!~David3k@120.29.75.241> has quit IRC (Client Quit)
[04:15:42] *** David3k <David3k!~David3k@120.29.75.241> has joined ##vulkan
[04:33:37] *** penguin42 <penguin42!~dg@cpc109017-salf6-2-0-cust428.10-2.cable.virginm.net> has quit IRC (Remote host closed the connection)
[05:14:27] *** Guy1524 <Guy1524!6c2cd738@pool-108-44-215-56.clppva.fios.verizon.net> has joined ##vulkan
[05:23:30] <Guy1524> hello all, I doing some work on a winevulkan (converts windows vulkan calls to linux vulkan calls) and I have come to a situation where I need to copy a pNext chain
[05:24:01] <Guy1524> to do this I need to get the size of any given structure in the chain, given the sType
[05:24:05] <Guy1524> is there an easy way to do this?
[07:20:03] *** Guy1524 <Guy1524!6c2cd738@pool-108-44-215-56.clppva.fios.verizon.net> has quit IRC (Ping timeout: 260 seconds)
[07:55:29] *** slime <slime!~slime73@24.215.81.93> has quit IRC (Quit: This computer has gone to sleep)
[09:37:02] *** ImQ009 <ImQ009!~ImQ009@unaffiliated/imq009> has joined ##vulkan
[09:39:12] *** LunarJetman <LunarJetman!LunarJetma@176.248.197.112> has joined ##vulkan
[09:39:48] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has joined ##vulkan
[10:16:36] *** ImQ009 <ImQ009!~ImQ009@unaffiliated/imq009> has quit IRC (Read error: Connection reset by peer)
[10:20:39] *** ImQ009 <ImQ009!~ImQ009@unaffiliated/imq009> has joined ##vulkan
[10:52:00] *** Deluxe <Deluxe!~Deluxe@212.4.150.151> has joined ##vulkan
[11:01:34] *** David3k <David3k!~David3k@120.29.75.241> has quit IRC (Quit: SOUUUUUUULS)
[11:35:02] *** ville <ville!~ville@212-149-214-47.bb.dnainternet.fi> has quit IRC (Quit:)
[11:36:53] *** ville <ville!~ville@212-149-214-47.bb.dnainternet.fi> has joined ##vulkan
[11:57:55] *** Deluxe_ <Deluxe_!~Deluxe@212.4.150.151> has joined ##vulkan
[13:03:19] <bnieuwenhuizen> No
[13:03:40] <bnieuwenhuizen> IIRC best you can do is parse the API XML to get the size of the currently existing structs
[13:12:40] *** Deluxe <Deluxe!~Deluxe@212.4.150.151> has quit IRC (Remote host closed the connection)
[13:14:17] *** ratchetfreak <ratchetfreak!~ratchetfr@ptr-82s3g7l9r42569r41f4.18120a2.ip6.access.telenet.be> has joined ##vulkan
[13:14:32] *** Deluxe <Deluxe!~Deluxe@212.4.150.151> has joined ##vulkan
[13:45:57] *** penguin42 <penguin42!~dg@cpc109017-salf6-2-0-cust428.10-2.cable.virginm.net> has joined ##vulkan
[14:49:35] *** Deluxe <Deluxe!~Deluxe@212.4.150.151> has quit IRC (Read error: Connection reset by peer)
[14:50:20] *** Deluxe_ <Deluxe_!~Deluxe@212.4.150.151> has quit IRC (Remote host closed the connection)
[14:50:50] *** Deluxe <Deluxe!~Deluxe@212.4.150.151> has joined ##vulkan
[15:28:28] *** felipealmeida <felipealmeida!~user@191.191.10.198> has joined ##vulkan
[16:21:21] *** slime <slime!~slime73@24.215.81.93> has joined ##vulkan
[16:48:30] *** slime <slime!~slime73@24.215.81.93> has quit IRC (Quit: This computer has gone to sleep)
[16:59:12] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has quit IRC (Ping timeout: 245 seconds)
[17:01:06] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has joined ##vulkan
[17:03:48] <reduz> Hi guys, question, is there any tool (command line or UI) where I can debug a spir-v object and see the contained push constant size and ranges for it?
[17:12:34] *** Andrej1 <Andrej1!~Andrej@BSN-143-212-5.dynamic.siol.net> has quit IRC (Read error: Connection reset by peer)
[18:11:01] *** salamanderrake <salamanderrake!~quassel@2605:a000:122a:2139:50b5:d668:b233:7be2> has quit IRC (Remote host closed the connection)
[18:13:19] *** salamanderrake <salamanderrake!~quassel@2605:a000:122a:2139:f000:8e58:f0e0:29cb> has joined ##vulkan
[18:37:25] <mirv_> see if spirv-reflect does what you need
[18:38:24] <mirv_> it's not a standalone tool, but can easily be made into one
[18:39:00] <mirv_> or wait...might have a sample cli built from it
[19:18:45] *** slime <slime!~slime73@blk-215-81-93.eastlink.ca> has joined ##vulkan
[19:44:07] *** ville <ville!~ville@212-149-214-47.bb.dnainternet.fi> has quit IRC (Quit:)
[20:09:09] *** ville <ville!~ville@212-149-214-47.bb.dnainternet.fi> has joined ##vulkan
[20:31:05] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has quit IRC (Ping timeout: 268 seconds)
[20:32:25] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has joined ##vulkan
[21:12:10] *** penguin42 <penguin42!~dg@cpc109017-salf6-2-0-cust428.10-2.cable.virginm.net> has quit IRC (Remote host closed the connection)
[21:33:59] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has quit IRC (Ping timeout: 268 seconds)
[21:35:39] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has joined ##vulkan
[22:10:18] *** Andrej1 <Andrej1!~Andrej@BSN-143-212-5.dynamic.siol.net> has joined ##vulkan
[22:11:15] *** ImQ009 <ImQ009!~ImQ009@unaffiliated/imq009> has quit IRC (Quit: Leaving)
[22:20:03] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has quit IRC (Ping timeout: 245 seconds)
[22:22:03] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has joined ##vulkan
[22:29:30] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has quit IRC (Ping timeout: 244 seconds)
[22:31:17] *** ryp <ryp!ryp@gateway/vpn/privateinternetaccess/ryp> has joined ##vulkan
top

   July 28, 2019  
< | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | >