Skip to content

OpenGLDepthPacketProcessor not working on Intel GPUs (Mac/OS X) #31

@dominiklessel

Description

@dominiklessel

Hello there!

I successfully compiled libfreenect2 on my MacBook Pro Retina (2013; QuadCore i7; Intel Iris GPU), but the IR/Depth Steam is just black. My first thought on this is a incompatible GPU … Does anybody have the same problem?

bildschirmfoto 2014-07-24 um 12 23 44

Some debugging code I added in SyncMultiFrameListener::onNewFrame(Frame::Type type, Frame *frame) (frame_listener_impl.cpp:69) outputted the following information:

if ( type == 4 ) {
  printf( "Got depth frame!\n" );
  printf( "width: %i\n", int(frame->width) );
  printf( "height: %i\n", int(frame->height) );
  printf( "bytes per pixel: %i\n", int(frame->bytes_per_pixel) );
  double sum;
  for (int i = 0; i < frame->width*frame->height*frame->bytes_per_pixel; ++i)
    sum += frame->data[i];
  printf( "sum: %f\n", sum );
}

Got depth frame!
width: 512
height: 424
bytes per pixel: 4
sum: 0

After skimming through the code I ended up looking at the different DepthPacketProcessors and swapped OpenGLDepthPacketProcessor with CpuDepthPacketProcessor (libfreenect.cpp:76) and commented out depth_packet_processor_(0) (libfreenect.cpp:277) to make Protonect compile again.

Now Protonect is outputting IR and Depth information, but turns my MacBook into a pocket heater:

bildschirmfoto 2014-07-24 um 12 25 08

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions