Skip to content

Instantly share code, notes, and snippets.

View GuyMicciche's full-sized avatar

Guy Micciche GuyMicciche

View GitHub Profile
@internetimagery
internetimagery / py2mel.py
Last active August 10, 2022 12:40
Convert Python code to Mel (using mel's python interpreter)
#!/usr/bin/env python
# Python to Mel converter
# Allows running of Python code by dragging into the Maya viewport
# Created 21/04/2015
# Jason Dixon
# [email protected]
# internetimagery.com
# Usage
@navicore
navicore / mkvpropedit
Last active February 20, 2022 09:22
mkvpropedit to edit the video file title metadata (mkv files)
#!/usr/bin/env bash
#mkvpropedit to edit the video file title metadata (mkv files)
for f in *.mkv; do mkvpropedit "$f" --edit info --set "title=${f%.mkv}"; done
@baku89
baku89 / easing-clone-size-gradually.py
Last active September 27, 2016 13:50
C4D Python Effector: Easing new clone's size gradually when cloner's count changed
import c4d
from c4d.modules import mograph as mo
prevCnt = 0
def main():
global prevCnt
md = mo.GeGetMoData(op)
if md==None: return False
@hilukasz
hilukasz / Selected_layers-PS.jsx
Last active January 3, 2025 21:07
get array of selected layers in photoshop via extendscript
var docRef = app.activeDocument;
cTID = function(s) { return app.charIDToTypeID(s); };
sTID = function(s) { return app.stringIDToTypeID(s); };
function newGroupFromLayers(doc) {
var desc = new ActionDescriptor();
var ref = new ActionReference();
ref.putClass( sTID('layerSection') );
@praveenvijayan
praveenvijayan / Copy text directly from Photoshop text layer.
Last active December 19, 2019 05:23
Copy text directly from text layer. Works above photoshop cs6. Copy following script file into /Applications/Adobe Photoshop CC 2014/Presets/Scripts (MAC) or C:\Program Files\Adobe\Adobe Photoshop CC 2014\Presets\Scripts (WIN). Assign shortcut for easy access (cmd+option+c / ctrl+alt+c)
/*****************************************************************
*
* Copy Layer text 1.0 - by Praveen Vijayan! - http://www.decodize.com/
*
* Compatibility above Photoshop CS6
*
* Licensed under the Creative Commons Attribution 2.5 License - http://creativecommons.org/licenses/by/2.5/
*
*****************************************************************/
@devdattaT
devdattaT / getTiles.py
Created July 14, 2014 08:31
Downloading of Slippy Tiles using Shapely.
import math
import os
import urllib
from shapely.geometry import Polygon
def deg2num(lat_deg, lon_deg, zoom):
lat_rad = math.radians(lat_deg)
n = 2.0 ** zoom
xtile = int((lon_deg + 180.0) / 360.0 * n)
ytile = int((1.0 - math.log(math.tan(lat_rad) + (1 / math.cos(lat_rad))) / math.pi) / 2.0 * n)
namespace GalaSoft.MvvmLight.Helpers
{
/// <summary>
/// A <see cref="BaseAdapter{T}"/> that can be used with an Android ListView. After setting
/// the <see cref="DataSource"/> and the <see cref="GetTemplate"/> properties, the adapter is
/// suitable for a list control. If the DataSource is an <see cref="INotifyCollectionChanged"/>,
/// changes to the collection will be observed and the UI will automatically be updated.
/// </summary>
/// <typeparam name="T">The type of the items contained in the <see cref="DataSource"/>.</typeparam>
////[ClassInfo(typeof(ObservableAdapter<T>),
@Cheesebaron
Cheesebaron / Chemical.cs
Last active March 15, 2023 19:30
Custom Adapter with Filter
namespace SearchViewSample
{
public class Chemical
{
public string Name { get; set; }
public int DrawableId { get; set; }
}
}
@AArnott
AArnott / ObservableCollectionAdapter.cs
Created March 12, 2014 19:19
A Xamarin.Android class that provides data binding from an ObservableCollection<T> to a ListView in the form of a BaseAdapter<T>.
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Collections.Specialized;
using System.ComponentModel;
using System.Linq;
using System.Text;
using Android.App;
using Android.Content;
using Android.OS;
@wbroek
wbroek / genymotionwithplay.txt
Last active February 13, 2025 09:37
Genymotion with Google Play Services for ARM
NOTE: Easier way is the X86 way, described on https://www.genymotion.com/help/desktop/faq/#google-play-services
Download the following ZIPs:
ARM Translation Installer v1.1 (http://www.mirrorcreator.com/files/0ZIO8PME/Genymotion-ARM-Translation_v1.1.zip_links)
Download the correct GApps for your Android version:
Google Apps for Android 6.0 (https://www.androidfilehost.com/?fid=24052804347835438 - benzo-gapps-M-20151011-signed-chroma-r3.zip)
Google Apps for Android 5.1 (https://www.androidfilehost.com/?fid=96042739161891406 - gapps-L-4-21-15.zip)
Google Apps for Android 5.0 (https://www.androidfilehost.com/?fid=95784891001614559 - gapps-lp-20141109-signed.zip)