Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
#!/bin/bash ###################################################################### #Copyright (C) 2024 Kris Occhipinti #https://filmsbykris.com #This program is free software: you can redistribute it and/or modify #it under the terms of the GNU General Public License as published by #the Free Software Foundation version 3 of the License. #This program is distributed in the hope that it will be useful, #but WITHOUT ANY WARRANTY; without even the implied warranty of #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #GNU General Public License for more details. #You should have received a copy of the GNU General Public License #along with this program. If not, see
. ###################################################################### [[ $1 ]] || exit [[ -f "$1" ]] || exit convert "$1" text:- |grep -v '^#'|awk '{print $1,$4}'|sed 's/: srgba(/,/g'|tr -d ')'|while read line do line="$(echo $line|sed 's/: black/,0,0,0,1/g')" pos="$(echo $line|cut -d\, -f1,2)" if [[ "$line" != *"none"* ]] then r="$(echo $line|cut -d\, -f3)" r="$(echo "scale=6; $r/255"| bc -l)" g="$(echo $line|cut -d\, -f4)" g="$(echo "scale=6; $g/255"| bc -l)" b="$(echo $line|cut -d\, -f5)" b="$(echo "scale=6; $b/255"| bc -l)" color="$r,$g,$b" name="Material.$RANDOM.$RANDOM" echo " bpy.ops.mesh.primitive_cube_add(enter_editmode=False, align='WORLD', location=($pos, 0), scale=(.5, .5, .5)) mat = bpy.data.materials.new('$name') mat.use_nodes = True bpy.data.materials['$name'].node_tree.nodes['Principled BSDF'].inputs[0].default_value = ($color, 1) bpy.context.object.active_material = mat" fi done
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)