Giter VIP home page Giter VIP logo

Comments (5)

Spirit30 avatar Spirit30 commented on June 7, 2024 1

This did the trick.
Thanks Man!

Great job,
Regards Spirit

from unity-ifcengine.

helpsterTee avatar helpsterTee commented on June 7, 2024

That actually looks like a path problem to me. Can you supply a screenshot with your folder structure in the Win_EXE directory?

from unity-ifcengine.

Spirit30 avatar Spirit30 commented on June 7, 2024

Thanks for Ideas!

Here are screenshots:
win_exe 2018-07-19 12 59 23
ifc_test 2018-07-19 13 02 44
ifc_data 2018-07-19 13 03 52
plugins 2018-07-19 13 04 08
managed 2018-07-19 13 04 33

Bellow is changed version of Manager.cs
It reads .ifc file from the Root (of Unity project if Editor or where windows build .exe is located).
It is done because .ifc file included into Assets was existed as binary part of builded Unity resources.
Correct me if I'm wrong.
Looking forward for your feedback.

Thank you!

using System.Collections;
using System.Collections.Generic;
using System.IO;
using UnityEngine;

public class Manager : MonoBehaviour {

public string fileName = "IfcOpenHouseGeoRef";
ImportIFC import;

void Start () {

    string fileFormat = Path.Combine(Directory.GetCurrentDirectory(), "{0}.ifc");
    string filePath = Path.GetFullPath(string.Format(fileFormat, fileName));
    Debug.Log(filePath);
    Debug.Log(File.ReadAllText(filePath));
    import = GetComponentInChildren<ImportIFC>();
    import.ImportFinished += new ImportIFC.CallbackEventHandler(ImportIsFinished);
    import.Init();
    import.ImportFile(filePath, fileName);
}

public void ImportIsFinished(GameObject go)
{
    Debug.Log(go.name + " is Imported!");
}

}

from unity-ifcengine.

helpsterTee avatar helpsterTee commented on June 7, 2024

Did you copy the IFC2X3-Settings.xml +.exp and IFC4-Settings.xml + .exp into the binary directory? This is needed for reading the IFC files.

from unity-ifcengine.

helpsterTee avatar helpsterTee commented on June 7, 2024

This did the trick. ...

@Spirit30 it's great people try to use it ;) if you build something presentable, just drop a note :)

Sent with GitHawk

from unity-ifcengine.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.