SlideShare una empresa de Scribd logo
1 de 13
Kinect
Captura Automática de fotografías con el esqueleto
Objetivo
• Tomar la fotografía cuando Kinect detecte la
mano derecha.
Itinerario
• ¿Qué es el Skeletal tracking?
• Sentado o de pie
• Partes del esqueleto
• Código
• Recomendaciones
Skeletal tracking
• Skeletal tracking significa seguimiento de
esqueleto y se basa en un algoritmo que logra
identificar partes del cuerpo, gestos y/o posturas
de quienes están en el campo de visión del
sensor.
Seated or Default
Es el esqueleto
predeterminado en el
cual Kinect identifica
las 20 partes del
cuerpo
fundamentales en las
extremidades y en el
rostro del cuerpo
humano.
Default
Es el esqueleto que
Kinect detecta si el
usuario esta sentado,
solo cuenta con 10
puntos de
identificación, se
utiliza comúnmente
cuando el usuario
esta cerca del sensor.
Seated
Partes del esqueleto
Default
Seated
Código
SDK 1.8
1. Declarar el Esqueleto
• Skeleton[] totalSkeleton = new Skeleton[6];
• // El número 6 es la cantidad máxima de
esqueletos puede detectar.
2. Habilitamos el esqueleto
if (!this.sensor.SkeletonStream.IsEnabled)
{
// Habilitamos el esqueleto.
this.sensor.SkeletonStream.Enable();
// Determinamos el tipo de esqueleto.
this.sensor.SkeletonStream.TrackingMode =
SkeletonTrackingMode.Seated;
// Llamamos al método SkeletonFrameReady.
this.sensor.SkeletonFrameReady += new
EventHandler<SkeletonFrameReadyEventArgs>(sensor_SkeletonFrameReady);
}
3. Método sensor_SkeletonFrameReady
using (SkeletonFrame skeletonFrame = e.OpenSkeletonFrame())
{
// Verifica que se encontró un esqueleto.
if (skeletonFrame == null)
{
return;
}
//copia la información del frame en la colección
skeletonFrame.CopySkeletonDataTo(totalSkeleton);
//Obtiene el primer esqueleto
Skeleton firstSkeleton = (from trackskeleton in totalSkeleton
where trackskeleton.TrackingState == SkeletonTrackingState.Tracked
select trackskeleton).FirstOrDefault();
3. Método sensor_SkeletonFrameReady
//Verificamos si el primer esqueleto regresa nulo, es decir no encontrado
if (firstSkeleton == null)
{
return;
}
//Aquí es donde detectamos la mano derecha
if (firstSkeleton.Joints[JointType.HandRight].TrackingState ==
JointTrackingState.Tracked)
{
this.saveImage();
this.sensor.Stop();
}
}
Recomendaciones
• Dependiendo del tipo de aplicación que estés
haciendo, piensa bien en que parte del cuerpo
usaras para tomar la fotografía.
• Toma muy en cuenta la ubicación que tendrá
Kinect para que tu aplicación sea más eficiente.
Maria Elena Abrego N.
MVP Kinect for Windows 2015
@Maleny_Abrego
malenyabrego.wordpress.com
/Malenymsp

Más contenido relacionado

Último

PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...
PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...
PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...
angierangel29072017
 

Último (7)

Suiwen He - eCommerce Day Chile 2024
Suiwen He  -  eCommerce  Day  Chile 2024Suiwen He  -  eCommerce  Day  Chile 2024
Suiwen He - eCommerce Day Chile 2024
 
Expo Construir 2024 agenda-workshops (2).pdf
Expo Construir 2024 agenda-workshops (2).pdfExpo Construir 2024 agenda-workshops (2).pdf
Expo Construir 2024 agenda-workshops (2).pdf
 
Modelos comunicacionales. Antonella Castrataro.pdf
Modelos comunicacionales. Antonella Castrataro.pdfModelos comunicacionales. Antonella Castrataro.pdf
Modelos comunicacionales. Antonella Castrataro.pdf
 
PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...
PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...
PRESENTACION EN SST, plan de trabajo del sistema de seguridad y salud en el t...
 
Alexander Rubilar, Enzo Tapia - eCommerce Day Chile 2024
Alexander Rubilar, Enzo Tapia - eCommerce Day Chile 2024Alexander Rubilar, Enzo Tapia - eCommerce Day Chile 2024
Alexander Rubilar, Enzo Tapia - eCommerce Day Chile 2024
 
Felipe González - eCommerce Day Chile 2024
Felipe González - eCommerce Day Chile 2024Felipe González - eCommerce Day Chile 2024
Felipe González - eCommerce Day Chile 2024
 
Willer Gehizon Sanchez Mora
Willer Gehizon Sanchez MoraWiller Gehizon Sanchez Mora
Willer Gehizon Sanchez Mora
 

Destacado

Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Destacado (20)

PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
 

Automatización de toma de fotografías Parte 2

  • 1. Kinect Captura Automática de fotografías con el esqueleto
  • 2. Objetivo • Tomar la fotografía cuando Kinect detecte la mano derecha.
  • 3. Itinerario • ¿Qué es el Skeletal tracking? • Sentado o de pie • Partes del esqueleto • Código • Recomendaciones
  • 4. Skeletal tracking • Skeletal tracking significa seguimiento de esqueleto y se basa en un algoritmo que logra identificar partes del cuerpo, gestos y/o posturas de quienes están en el campo de visión del sensor.
  • 5. Seated or Default Es el esqueleto predeterminado en el cual Kinect identifica las 20 partes del cuerpo fundamentales en las extremidades y en el rostro del cuerpo humano. Default Es el esqueleto que Kinect detecta si el usuario esta sentado, solo cuenta con 10 puntos de identificación, se utiliza comúnmente cuando el usuario esta cerca del sensor. Seated
  • 8. 1. Declarar el Esqueleto • Skeleton[] totalSkeleton = new Skeleton[6]; • // El número 6 es la cantidad máxima de esqueletos puede detectar.
  • 9. 2. Habilitamos el esqueleto if (!this.sensor.SkeletonStream.IsEnabled) { // Habilitamos el esqueleto. this.sensor.SkeletonStream.Enable(); // Determinamos el tipo de esqueleto. this.sensor.SkeletonStream.TrackingMode = SkeletonTrackingMode.Seated; // Llamamos al método SkeletonFrameReady. this.sensor.SkeletonFrameReady += new EventHandler<SkeletonFrameReadyEventArgs>(sensor_SkeletonFrameReady); }
  • 10. 3. Método sensor_SkeletonFrameReady using (SkeletonFrame skeletonFrame = e.OpenSkeletonFrame()) { // Verifica que se encontró un esqueleto. if (skeletonFrame == null) { return; } //copia la información del frame en la colección skeletonFrame.CopySkeletonDataTo(totalSkeleton); //Obtiene el primer esqueleto Skeleton firstSkeleton = (from trackskeleton in totalSkeleton where trackskeleton.TrackingState == SkeletonTrackingState.Tracked select trackskeleton).FirstOrDefault();
  • 11. 3. Método sensor_SkeletonFrameReady //Verificamos si el primer esqueleto regresa nulo, es decir no encontrado if (firstSkeleton == null) { return; } //Aquí es donde detectamos la mano derecha if (firstSkeleton.Joints[JointType.HandRight].TrackingState == JointTrackingState.Tracked) { this.saveImage(); this.sensor.Stop(); } }
  • 12. Recomendaciones • Dependiendo del tipo de aplicación que estés haciendo, piensa bien en que parte del cuerpo usaras para tomar la fotografía. • Toma muy en cuenta la ubicación que tendrá Kinect para que tu aplicación sea más eficiente.
  • 13. Maria Elena Abrego N. MVP Kinect for Windows 2015 @Maleny_Abrego malenyabrego.wordpress.com /Malenymsp