Compiling KAE

5 replies [Last post]
Joined: 07/07/2009
Points: 39

Peace!

Hi, I'd like to know if the KAE svn already includes KCW as a library?

Here are my Steps on how to compile KAE from the SVN

NOTE: This assumes that you have a working Apache Environment (LAMP) and that your HTTP_ROOT is on a folder above the project folder. Also download the phplib API and replace the ones that are inside the html-template... the existing ones are broken

1) Download the latest SVN from [html]http://www.kaltura.org/project/kae[/html]
2) Open FlexBuilder 3 and create a new Project (in another folder... name the project KalturaAdvancedVideoEditor)
   2.a) Close the newly opened KalturaAdvancedVideoEditor.mxml page
3) Copy the following folders to your Project Folder (inside the Project folder or on the root where you can see the src folder)
    src
    locale
    libs
    html-template
    docs (this is optional)
    asdocs (this is optional)
4) Click on Project -> Clean (this is doing a clean build)
5) Click on Project -> Properties -> Run/Debug Settings
     At this point you should see a Launch Configuration named KalturaAdvancedVideoEditor
     Click on that and Click on Edit
     Uncheck the "Use Defaults" option under the "URL or path to launch" area
     fill up all the text entries and change KalturaAdvancedVideoEditor.html to index.php
6) Open up /html-templates/index.template.php
     add the following lines prior to this line
               /*
                        Enter below you details (partner, secret for generating ks automatically and kshow/entry to load).
                */
    Add these lines:
    require_once("kaltura_client.php");
        // CHANGE THE FOLLOWING PARAMS TO YOUR PARTNER AND APPLICATION INFORMATION:
        // Replace the 'xxxxx' with your partner values.
        $userId = "anonymous";
        $partnerId = "<fill this up with your partner ID>";
        $subPartnerId = "<fill this up with your subpartner ID>";
        $secret = "<fill this one up>";
        $adminsecret = "<fill this one up>";
        $host = "www.kaltura.com";
        $mix_name = "<create a unique mix name... any will do>";
        $filtered_entries = "<you can skip this one, as of the moment your not using this>";

        require_once("kaltura_client.php");

        define(KALTURA_PARTNER_ID, $partnerId);
        define(KALTURA_SUBP_ID, $subPartnerId);
        define(KALTURA_SECRET, $secret);
       
        $config = new KalturaConfiguration(KALTURA_PARTNER_ID,KALTURA_SUBP_ID);
        $user = new KalturaSessionUser();
        $user->userId = "ANONYMOUS"; // if you have your userid, fill this on eup
        $user->screenName = "Anonymous";// if you have your screenName, fill this one up
       
        $client = new KalturaClient($config);
        $result = $client->startSession($user, KALTURA_SECRET, false, "edit:*");
        $ks = $result["result"]["ks"];// this is important to remember
       
        $client->setKS($ks);
        $entry = new KalturaEntry();
        $entry->name = "My First Mix";
        $res = $client->addRoughcutEntry($user, -2, $entry);
        $entryId = @$res["result"]["entry"]["id"];
       
        $flashVars = array();
        $flashVars["partnerId"] = KALTURA_PARTNER_ID;
        $flashVars["subpId"]    = KALTURA_SUBP_ID;
        $flashVars["uid"]       = $user->userId;
        $flashVars["ks"]        = $ks;
        $flashVars["kshowId"]   = "entry-".$entryId;
        $flashVars["entryId"]   = $entryId;
        $flashVars["backF"]     = "onSimpleEditorBackClick";
        $flashVars["saveF"]     = "onSimpleEditorSaveClick";
        $flashVars["quick_edit"] = 0;

7) Replace the existing variable config with this one (you'll find a bunch of code looking something like the one below... replace it with this one)
                $uid = $flashVars["uid"];
                $uname = $user->userId;
                $pid = $flashVars["partnerId"];
                $spid = $flashVars["subpId"];
                $secret = $secret;
                $kshowid = $flashVars["kshowId"];
                $entryid = $flashVars["entryId"];
                $entryversion = "-1";
                $host = "www.kaltura.com";
                $debugmode = "1";

8) Do another clean build (you don't really have to but it's just a precaution; changing the template automatically sets FlexBuilder to refresh the workspace)

NOTE2: Copy kae_net10_generic_styles.swf from html-template\content\uiconf\droga5\net10\kae_1.0.5 to bin-debug/assets/css/ before rebuilding

9) Click on Run or Debug to run your Build... and TADAH! You have your own working (loosely used) copy of KAE except that it's all RED and stuff.

Problem with this is that when you click on the ADD button (or any button that links to KCW), it'll hang the program. This is where I don't know what to do.. I traced the calling to a file PropertiesWindowCode.as

This has a custom dispatch named openContributionWizard which uses a custom Event under OpenContributionWizardEvent.as... but it's hard to trace since I don't know who the listener is... did a grep on all the mxml and so far all I can deduce is that Cairngorm does not follow a normal dispatch listener which uses a static const variable string as a base for the Event...

Anyway, I'm asking how do I integrate KCW here or basically fix this problem?

Joined: 01/05/2009
Points: 1697

Hi Andrew,

the KCW is only being referenced by the KAE, it's not compiled inside it.
what you need to do is edit the uiConf xml of the KAE and on the contribution wizard element add the uiConf id of the KCW you would like to load.

Do you use the hosted version on kaltura.com or KalturaCE ?

Joined: 07/07/2009
Points: 39

Peace!

Thanks for the hint Kalturian. Currently for my testing purposes I'm using your free service (I have not successfully installed the CE version on my Ubuntu 8.04 setup, as per advise I'm waiting for the next release http://www.kaltura.org/error-message-array-0-failed-serialize-server-res... ).

The most logical transition would be to move from the free service to the paid hosted service once I find clients who are willing to shoulder the cost. Currently I'm being hired to evaluate KAE (and another solution) but I see potential in Kaltura for future clients who wish to implement a complex video mixer for their own clientele, ergo my pursuit in Kaltura above and beyond what I'm being called for. This is really an interesting product that can benefit a lot of people, and from what I hear from Matt, you guys have a pretty good commercial offering that is worth looking into.

My experiments put myself in between what Matt is trying to push and what a Consultant/Developer like me can put as a proof of concept. Although I think my initial "sell" for Kaltura will go down the drain (I'm only one of the evaluators and it's just my gut feeling since I'm the only evaluator who seem to put a dent into the svn code in terms of customization and integration), but I know this solution is heading in the right direction... just need to convince people that it is worth looking into.

--
Engr. Andrew John P. Young
IT Consultant/RH Technician
RHCT sn# 609003172208054
"With God Everything IS POSSIBLE"

Joined: 03/29/2009
Points: 764

Hi,

Thanks a lot for the feedback. We would be happy to give any more info on this.

Joined: 10/06/2009
Points: 1

Hi All,
Sorry if this has been answered or if detailed instructions exists, but how can someone compile the application in flex?
Thanks for your patience

Joined: 06/26/2009
Points: 17

I know this thread has been dead for some time but to finish it up we have created a guide to compiling the KAE that should make it more straightforward (http://www.kaltura.org/guide-compile-kaltura-advanced-editor).

Good luck.