khronosfws/openmax_al/src/gst_adaptation/xaadaptationgst.c
changeset 32 94fc26b6e006
parent 31 8dfd592727cb
child 42 1fa3fb47b1e3
equal deleted inserted replaced
31:8dfd592727cb 32:94fc26b6e006
    53             free(pSelf);
    53             free(pSelf);
    54             pSelf = NULL;
    54             pSelf = NULL;
    55             }
    55             }
    56         else
    56         else
    57             {
    57             {
    58             GError* gerror = 0;
       
    59 
       
    60             /*         Add default handler for Gst-bus messages */
    58             /*         Add default handler for Gst-bus messages */
    61             pSelf->busCb = XAAdaptationGst_GstBusCb;
    59             pSelf->busCb = XAAdaptationGst_GstBusCb;
    62 
    60 
    63             // VASU MOD BEGINS
    61             // VASU MOD BEGINS
    64             pSelf->cond_mutx_inited = XA_BOOLEAN_FALSE;
    62             pSelf->cond_mutx_inited = XA_BOOLEAN_FALSE;
    65             // VASU MOD ENDS
    63             // VASU MOD ENDS
    66 
    64 
    67             sem_init(&(pSelf->semAsyncWait), 0, 0);
    65             sem_init(&(pSelf->semAsyncWait), 0, 0);
    68 
       
    69             if (!gst_init_check(NULL, NULL, &gerror))
       
    70                 {
       
    71                 DEBUG_ERR("Gst Initalization failure.");
       
    72                 return XA_RESULT_INTERNAL_ERROR;
       
    73                 }
       
    74 
       
    75             }
    66             }
    76         }
    67         }
    77     else
    68     else
    78         {
    69         {
    79         DEBUG_ERR("Invalid Gst Base Context.")
    70         DEBUG_ERR("Invalid Gst Base Context.")
   487                             //DEBUG_INFO("alsasrc"); //Krishna
   478                             //DEBUG_INFO("alsasrc"); //Krishna
   488                             DEBUG_INFO("devsoundsrc")
   479                             DEBUG_INFO("devsoundsrc")
   489                             ;
   480                             ;
   490                             gstSrc = gst_element_factory_make("devsoundsrc",
   481                             gstSrc = gst_element_factory_make("devsoundsrc",
   491                                     name); //Krishna - changed to devsoundsrc
   482                                     name); //Krishna - changed to devsoundsrc
   492                             g_object_set(G_OBJECT (gstSrc), "num-buffers",
   483 							// no need to set num-buffers		
   493                                     80, NULL);
   484                             /*g_object_set(G_OBJECT (gstSrc), "num-buffers",
       
   485                                     80, NULL);*/
   494                             break;
   486                             break;
   495                         case XA_ADAPTID_AUDIOTESTSRC:
   487                         case XA_ADAPTID_AUDIOTESTSRC:
   496                             /*fall through*/
   488                             /*fall through*/
   497                         default:
   489                         default:
   498                             DEBUG_INFO("audiotestsrc")
   490                             DEBUG_INFO("audiotestsrc")