1、Why did I click the clear button,currently tracked doesn't clear. How to re-collect shader variants for project.
2、How to collect shader variants automaticlly by script?
1、In order to solve this problem, I clear the shaderCache files in project's Library folder.
2、I made a new Scene with a Quad, load all mat add to the quad in turn, last save the asset, but this would strip the variant by script Enabled Keys.
Related
I have a QGIS project that displays calculation results on a map. There are several vector layers, each with >100 calculated fields. The way the data should be visualised is very similar for all these layers/fields. I try to write a script that duplicates a template layer, and changes the expressions for the symbology according to the selected fieldname.
Below is a screenshot of the properties I try to access (if I were to change them using the UI).
How do I access/change the expressions of the line width and line offset of a graduated symbology in PyQGIS?
In case someone else runs into this issue.
I solved it using a workaround. I saved the style of the source layer to a qml-file, for the duplicated layers I create a temporary copy of the qml-file, do a search-and-replace on the qml-file and apply this to the new layer using
newLayer.loadNamedStyle(pathToTheTempQmlFile)
Hope this helps:
rule=layer.renderer().rootRule().children()[0]
rule.setFilterExpression('whatever')
see:
QgsRuleBasedRenderer.Rule
As stated here I am not the only one finding the following problem:
Shader.Find returns a Null.
In the link above they gave a solution by creating something(?) in the Resource Folder, but I am not sure I understand. First, is this necessary for all cases? (meaning Shader.Find does not work by itself?)
Second, what should I add? An unlit shader?? a material?
Very confused here
I could solve the problem finally by doing the following:
First, go to unity editor: Edit->Project Settings-> Graphics
Then in the inspector where it says "Always Included Shaders" add "Unlit/Texture"
Then change my Shader.Find code to read Shader.Find("Unlit/Texture");
With this it does not return null anymore
You should add your shaders to any of the scene objects otherwise they work only in editor.
Add your shader to Resource Folder or you can create new one.
In Resource Folder
RightClick -> Create -> Material
When you select the material you will see the shader field in inspector,choose the suitable one for you.
For example:
in my script;
var newMtl = new Material(Shader.Find("Standard (Specular setup)")) { name = materialName };
So I added the material and select Standard (Specular setup) as the shader.
Hello I'm using ImageJ to analyse -czi and -zvi files. I'm using an automatic selection with "create selection" or "analyze particle"s. It's working well when openening/importing the files with ImageJ. But when I try to use the Bio-Format importer Plugin with the same pictures, it's not working. Not my intended ROIS are selected but the background or even nothing. With using the plugin something about the parameters of the picture changes and I don't know what it is or how to undo it. Does somebody has an idea?
One of the Solutions I realised is a Change of scale. My original files use pixels, whereas the BioFormat importer converts the scale into microns.
Analyze--> Set Scale... --> Click to remove scale or changing the scale solves one part of the problem.
For a macro following code restores the scale:
run("Set Scale...", "distance=0 known=0 pixel=1 unit=pixel");
Still somethng about the colour values changes, I can't find, create selection is still not working properly.
Need to apply theme from one word document (DOCX) to another via manipulating the XMLs.
The road I'm going through is -
word/themes folder contains at least one theme#.xml and could have the rels folder containg relationship files. I decided not to touch the rels folder and copy all theme#.xmls (as could be more than one) present in word/theme folder. This is working for me.
I have two concerns over it:
1. Do I need to add theme1.xml.rels file present in word\theme_rels as well? It contains mapping to one image in word\media folder. Do I need to add the image mapping too?
2. For few themes such as "Quotable", the theme1.xml contains one reference in 'a:fmtScheme' node to relationship id, probably for DrawingML and shapes.
for ex:
<a:blipFill rotWithShape="1">
<a:blip xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" r:embed="rId1">
As the "rId1" here refers to styles.xml and maintained in word_rels\document.xml.rels, my concern is the word_rels\document.xml.rels mapping to styles.xml could not be rId1 in the document to which theme is getting applied (for instance this could be rId5 for styles.xml). So, Do I need to change this in theme1.xml while copying to work it properly.
Any help would be greatly appreciated.
If this XML appears in theme1.xml, 'rId1' is a key in theme1.xml.rels, not the document.xml.rels. The relationship ids (rId#) are unique within a 'source' XML document but are not unique within the overall package (.docx file).
Since this one is a <a:blip> element, the relationship will be to an image part, e.g. image1.jpg. I suspect this one is a large-ish quotation mark image that appears in front of a pull-out quote.
If you want it to show up properly, you'll want to make sure those relationships and their target parts are reconstructed in your target package. That would mean "yes", you would want to add the theme1.xml.rels file in the right place, as well as the image file it refers to.
I created a small city in CityEngine using the openstreetmap data (osm file), where I've the latitude, longitude and some others details of each node. Now I want to export this information to the Unity3d, so I exported the city as fbx file. At this point everything is going ok.
The problem is ... in cityEngine each block/shape represents a different object, however in unity3d this is not happen. The data is divided per texture (or something like that). But I need to recognize each block/shape or at least I need to know the right position of them.
You have a option in the exporter where you can export the scene as centered around the xyz origin (exporter options).
The exporter has many settings for mesh-granularity. The meshes are per default merged by material. But you can of course also export for each shape one object etc.
Please visit the CityEngine Forum for more info:
http://forums.arcgis.com/forums/45-Solutions
http://forums.arcgis.com/threads/51437-Export-Mesh-and-Material-Granularity?highlight=cityengine+unity