Package info.ata4.unity.cli.tools

Examples of info.ata4.unity.cli.tools.WebDownloader


)
public class SplitCmd extends AssetCommand {
   
    @Override
    public void processAsset(AssetFile asset) throws IOException {
        AssetExtractor ae = new AssetExtractor(asset);
        ae.setClassFilter(getOptions().getClassFilter());
        ae.setOutputDir(getOutputDir());
        ae.split();
    }
View Full Code Here


        return this;
    }

    @Override
    protected void processAsset(AssetFile asset) throws IOException {
        AssetExtractor ae = new AssetExtractor(asset);
        ae.setClassFilter(getOptions().getClassFilter());
        ae.setOutputDir(getOutputDir());
        ae.extract(isRaw());
    }
View Full Code Here

        addHandler("Texture2D", new Texture2DHandler());
        addHandler("Cubemap", new Texture2DHandler());
        addHandler("Font", new FontHandler());
        addHandler("TextAsset", new TextAssetHandler("txt"));
        addHandler("MovieTexture", new MovieTextureHandler());
        addHandler("Mesh", new MeshHandler());
    }
View Full Code Here

        AUDIO_EXT = Collections.unmodifiableMap(extMap);
    }

    @Override
    public void extract(UnityObject obj) throws IOException {
        AudioClip audio = new AudioClip(obj);

        ByteBuffer audioBuffer = audio.audioBuffer;

        // load audio buffer from external buffer if stream is set to 2
        int stream = obj.getValue("m_Stream");
View Full Code Here

                    if ((stream.channelMask.longValue() & 1 << j) == 0) {
                        continue;
                    }
                   
                    boolean half = false;
                    ChannelInfo channel = null;

                    // channels may not be available in older versions
                    if (!channels.isEmpty()) {
                        channel = channels.get(j);
                        half = channel.format == 1;
View Full Code Here

            triangles.add(subMeshTriangles);
        }
    }

    private void readCompressedMesh() throws IOException {
        CompressedMesh cmesh = mesh.compressedMesh;

        float[] vertexFloats = readPackedFloats(cmesh.vertices);
        for (int i = 0; i < vertexFloats.length / 3; i++) {
            Vector3f v = new Vector3f();
            v.x = vertexFloats[i * 3];
 
View Full Code Here

    }
   
    @Override
    public void extract(UnityObject obj) throws IOException {
        // unpack the mesh
        MeshData meshData = new MeshData(new Mesh(obj));
       
        // choose a mesh writer
        MeshWriter meshWriter;
       
        switch (format) {
View Full Code Here

        super(handler);
    }
   
    @Override
    void write(MeshData meshData) throws IOException {
        Mesh mesh = meshData.getMesh();

        List<Vector3f> vertices = meshData.getVertices();
        List<Vector3f> normals = meshData.getNormals();
        List<Vector2f> uv1 = meshData.getUV1();
        List<Vector2f> uv2 = meshData.getUV2();
View Full Code Here

        super(handler);
    }
   
    @Override
    public void write(MeshData meshData) throws IOException {
        Mesh mesh = meshData.getMesh();
       
        vns = meshData.getNormals();
        vts = meshData.getUV1();
       
        // use second layer if the first one is unused
View Full Code Here

        // PLY can't have more than one mesh per file, so write one file per
        // sub-mesh
        final int subMeshCount = mesh.subMeshes.size();
        final int vertsPerFace = 3;
        for (int i = 0; i < subMeshCount; i++) {
            SubMesh subMesh = mesh.subMeshes.get(i);
           
            // use prefix if there's more than one submesh
            String name = mesh.name;
            if (subMeshCount > 1) {
                name = String.format("%s_%d", name, i);
View Full Code Here

TOP

Related Classes of info.ata4.unity.cli.tools.WebDownloader

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.