Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

The tag has no usage guidance.

1
vote
1answer
27 views

Are the benefits of a Metal early depth test limited to one draw call

I should preface with currently this question is mostly asking about Metal and iOS GPUs. That being said if this is GPU or OS specific and you can go into detail about other platforms that would be ...
6
votes
1answer
99 views

Same draw call causing extremely different GPU usage under different triangle orders

So I have a bit of a predicament I am trying to solve. I have 10,000 triangle strips I am trying to draw. Each one has a z-order for the entire strip and within each strip the most recent triangles ...
1
vote
0answers
36 views

Sorting my geometry for alpha testing

Here is my predicament. I am trying to draw a multitude of dots that leave trails behind them real time. Heres the difficulty, that line fades. Each dot line has a defined z position and the goal ...
2
votes
2answers
66 views

How to perform additive blending in Metal. What do these terms mean?

Forgive me, I dont really understand the basis of alpha blending. Like I know the formula but when it comes to the terms blending operation, source blend factor, and destination blend factor I am ...
0
votes
0answers
13 views

Sharing a MTLCommandBuffer across multiple MTKViews

I am using MTKViews for select UI elements inside of my UIKit app. I have a central metal controller that does something somewhat like this: ...
3
votes
1answer
274 views

MTLTexture getBytes returning blank image

Inside of my application I am trying to convert a MTLTexture into a CGImage or CIimage for use in other parts of the app. I am having a difficult time doing so because none of the example code I find ...
2
votes
1answer
281 views

Passing parameters in Metal Compute Kernel using Swift 4

On the CPU side, I have a structure I want to pass to the compute kernel: ...
1
vote
0answers
66 views

Triple buffering without buffers?

Metal Best Practices Guide states that The setVertexBytes:length:atIndex: method is the best option for binding a very small amount (less than 4 KB) of dynamic buffer data to a vertex function I ...
3
votes
1answer
88 views

Mipmap sampler in Metal compute kernel (not vertex or fragment shader)

I have a source texture (480x480) that was created with mipmapped set to true (error checking removed to simply this post), and a dest texture (100x100): ...
6
votes
1answer
98 views

How do you design the code of a graphics engine to target multiple frameworks

I am starting to think about how I can make my app (currently written in Metal) available on older device that dont have Metal as well as Android. This is a predicament because while I could write two ...
1
vote
0answers
52 views

How to format a vertex layout descriptor (MTLVertexBufferLayoutDescriptor) for this scenario

I am having a lot of trouble understanding what the difference between a layout and a descriptor is inside of a MTLVertexBufferLayoutDescriptor object. I am hoping to create a layout descriptor that ...