This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* y3d is a WebGL library built with yui3 | |
* | |
* https://github.com/brunofarache/y3d | |
*/ | |
/** | |
* Examples: load y3d scripts from gists, click on it to see more examples | |
* Save: saves code to anonymous public gist | |
* Run: runs code (Crtl+U shortcut) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* https://gist.github.com/brunofarache/5819929 | |
*/ | |
YUI({ gallery: 'gallery-2013.10.24-18-05' }).use('gallery-y3d', function(Y) { | |
var scene = new Y.Scene({ | |
camera: new Y.Camera({ | |
position: { | |
z: 20 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Click on the left canvas and then move camera with wasd keys. | |
* Use mouse wheel to zoom in and zoom out. | |
* | |
* https://gist.github.com/brunofarache/5853591 | |
*/ | |
YUI().use('y3d-anim', 'y3d-scene', 'y3d-camera', 'y3d-geometry-box', 'y3d-geometry-sphere', 'y3d-texture', function(Y) { | |
var camera = new Y.Camera({ | |
position: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Click on the box, it should change to a random color. | |
* | |
* https://gist.github.com/brunofarache/5855622 | |
*/ | |
YUI().use('y3d-picker-plugin' ,'y3d-scene', 'y3d-geometry', 'node', function(Y) { | |
var scene = new Y.Scene({ | |
background: '#272822' | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Loading a teapot.obj file | |
* | |
* https://gist.github.com/brunofarache/6228194 | |
*/ | |
YUI().use('y3d-scene', 'y3d-camera', 'y3d-obj-loader', 'io-base', function(Y) { | |
var scene = new Y.Scene({ | |
camera: new Y.Camera({ | |
position: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Map<Integer, Integer> collided = new HashMap<Integer, Integer>(); | |
for (int i = 0; i < 4; i++) { | |
for (int j = 0; j < 7; j++) { | |
Vec3D hand = hands[i]; | |
AABB box = boxes[j]; | |
if (box.containsPoint(hand) && pointClassification.equals(cutPlane.classifyPoint(hand, 0).toString())) { | |
boolean triggered = (collided.get(i) == j); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.liferay.mobile.sdk.MobileSDKBuilder; | |
MobileSDKBuilder.build( | |
MobileSDKBuilder.ANDROID, "http://localhost:8080", | |
"calendar-portlet", "com.liferay.calendar.mobile", | |
"/folder/destination"); | |
public static void build( | |
String platform, String url, String context, String packageName, | |
String destination); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Copyright (c) 2000-2014 Liferay, Inc. All rights reserved. | |
* | |
* This library is free software; you can redistribute it and/or modify it under | |
* the terms of the GNU Lesser General Public License as published by the Free | |
* Software Foundation; either version 2.1 of the License, or (at your option) | |
* any later version. | |
* | |
* This library is distributed in the hope that it will be useful, but WITHOUT | |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+ (void)upload:(NSData *)data folderId:(long)folderId | |
title:(NSString *)title mimeType:(NSString *)mimeType | |
requestDelegate:(id)requestDelegate | |
progressDelegate:(id)progressDelegate { | |
BOOL addGroupPermissions = | |
[self getAddGroupPermissions:[PrefsUtil getGroupType]]; | |
BOOL addGuestPermissions = | |
[self getAddGuestPermissions:[PrefsUtil getGroupType]]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Liferay = require('liferay'); | |
// Session | |
var session = new Liferay.Session('http://localhost:8080', 'test@liferay.com', 'test'), | |
service = new Liferay.Calendar(session); | |
service.deleteCalendar(1, function (err, data) { | |
console.log(err, data); | |
}); |
OlderNewer