Changeset - b46f6977168b
[Not reviewed]
default
0 4 0
Drew Perttula - 7 years ago 2018-04-29 12:22:36
drewp@bigasterisk.com
start pixijs on timeline
Ignore-this: 51ad366ddfeae2af2b621d714ff1f9c1
4 files changed with 29 insertions and 2 deletions:
0 comments (0 inline, 0 general)
light9/web/lib/bower.json
Show inline comments
 
@@ -29,15 +29,16 @@
 
    "isotope-fit-columns": "^1.1.3",
 
    "jquery.columnizer": "https://github.com/adamwulf/Columnizer-jQuery-Plugin.git#^1.6.2"
 
  },
 
  "resolutions": {
 
    "rdflib.js": "920e59fe37",
 
    "d3": "e7194db33090a0afc06c77a959594361ffb949df",
 
    "jquery": "^3.2.1",
 
    "webcomponentsjs": "^v1.1.0",
 
    "paper-radio-button": "^2.1.0",
 
    "iron-resizable-behavior": "^2.1.0",
 
    "polymer": "2.6.0",
 
    "paper-slider": "~2.0.6",
 
    "iron-ajax": "~2.1.3"
 
    "iron-ajax": "~2.1.3",
 
    "paper-styles": "^2.1.0"
 
  }
 
}
light9/web/timeline/timeline.coffee
Show inline comments
 
@@ -272,24 +272,45 @@ Polymer
 
    zoom: { type: Object, notify: true, observer: 'onZoom' } # viewState.zoomSpec
 
    zoomFlattened: { type: Object, notify: true }
 
  observers: [
 
    'onGraph(graph, dia, setAdjuster, song, zoomInX)'
 
  ]
 
  onZoom: ->
 
    updateZoomFlattened = ->
 
      log('updateZoomFlattened')
 
      @zoomFlattened = ko.toJS(@zoom)
 
    ko.computed(updateZoomFlattened.bind(@))
 
  ready: ->
 

	
 
     stage = new PIXI.Container();
 
     
 
     renderer = PIXI.autoDetectRenderer(300,200, {
 
         backgroundColor: 0xff6060,
 
     });
 
     
 
     @$.rows.appendChild(renderer.view);
 
     graphics = new PIXI.Graphics();
 

	
 
     graphics.beginFill(0xFF3300);
 
     graphics.lineStyle(4, 0xffd900, 1);
 

	
 
     graphics.moveTo(50,50);
 
     graphics.lineTo(250, 50);
 
     graphics.lineTo(100, 100);
 
     graphics.lineTo(50, 50);
 
     graphics.endFill();
 
     
 
     stage.addChild(graphics);
 
     renderer.render(stage);
 

	
 
  onGraph: ->
 
    U = (x) => @graph.Uri(x)
 
    log('assign rows',@song)
 

	
 
    for uri in _.sortBy(@graph.objects(@song, U(':note')), 'uri')
 
      #should only make new ones
 
      child = new Note(@graph, @selection, @dia, uri, @setAdjuster, @song, @zoomInX)
 
      log('note ',uri)
 
    
 
    @rows = (new NoteRow(@graph, @dia, @song, @zoomInX, @noteUris, i, @selection) for i in [0...ROW_COUNT])
 

	
 
  attached: ->
makefile
Show inline comments
 
@@ -42,25 +42,29 @@ link_to_sys_packages:
 
binexec:
 
	chmod a+x bin/*
 

	
 

	
 
node_modules/bower/bin/bower:
 
	npm install
 

	
 
bin/node:
 
	ln -sf `which nodejs` bin/node
 

	
 
bower: node_modules/bower/bin/bower bin/node
 
	cd light9/web/lib; nodejs ../../../node_modules/bower/bin/bower install
 
	# pixi is fetched with npm
 
	ln -s ../../../node_modules/pixi.js light9/web/lib/
 

	
 
	cd light9/web/lib/N3.js; npm install; PATH=../../../../bin:$(PATH) npm run browser
 

	
 
	cd light9/web/lib/d3; PATH=../../../../bin:$(PATH) npm install
 

	
 
bin/ascoltami2: gst_packages link_to_sys_packages
 

	
 
effect_node_setup: create_virtualenv packages binexec install_python_deps
 

	
 
tkdnd_build:
 
	# get tkdnd r95 with subversion
 
	# then apply tkdnd-patch-on-r95 to that
 
	cd tkdnd/trunk
 
	./configure
 
	make
package.json
Show inline comments
 
{
 
  "name": "light9",
 
  "version": "1.0.0",
 
  "description": "Mini instructions:",
 
  "main": "index.js",
 
  "directories": {
 
    "test": "test"
 
  },
 
  "dependencies": {
 
    "bower": "^1.8.0",
 
    "chai": "^3.5.0",
 
    "mocha": "^2.5.3"
 
    "mocha": "^2.5.3",
 
    "pixi.js": "^4.7.3"
 
  },
 
  "devDependencies": {
 
    "mocha": "^2.5.3"
 
  },
 
  "scripts": {
 
    "test": "mocha"
 
  }
 
}
0 comments (0 inline, 0 general)