Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

161
Visualizações
Conversion of Windows.Graphics.Capture.Direct3D11CaptureFrame to OpenCvSharp::Mat

As the title suggests, the aim is to convert Direct3DCaptureFrame from the Windows.Graphics.Capture API to a matrix object available in OpenCvSharp (Mat) so that the captured frame may be used with the popular Computer Vision Library.

There's an in-depth issue available on GitHub which gives reference to current attempts and findings. It also includes sample of what the result should look like and what it does as of now.

I personally believe my way isn't the right way and there may be an easier way to handle this, but I just decided to map the memory and copy it to a byte[]. OpenCvSharp::Mat has constructor overloads which allow one to reference data.

If there is a better (hopefully as performant) and easy way to do this, please do suggest it. I would love some help here.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

This issue was recently fixed by myself.

The missing thing was padding when referencing the byte[]. It is required to set the step parameter of Mat's overloaded constructor to width * (bytes / pixel). In my case, bytes / pixel was 4.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda