@ferdinand cool. this really helpful!
Y
Latest posts made by yushang
-
RE: why my interface is sealed in maxon::Result?
-
why my interface is sealed in maxon::Result?
Hi guys,
I'm following the maxonsdk.module listed in here. Which declare aSimpleNumberInterface
and implement it withSimpleNumberImpl
. I mimic the steps as follow- projectdefinition.txt
Platform=Win64;OSX;Linux Type=DLL APIS=core.framework stylecheck=false ModuleId=net.yu.myp
- myifc.h
#pragma once #include "maxon/object.h" class MyIfc : MAXON_INTERFACE_BASES(maxon::ObjectInterface) { MAXON_INTERFACE(MyIfc,MAXON_REFERENCE_NORMAL,"net.yu.interface.myifc"); public: MAXON_METHOD void Hello(); }; #include "myifc1.hxx" MAXON_DECLARATION(maxon::Class<MyIfcRef>, MyIfcDecl, "net.yu.myifcdecl"); #include "myifc2.hxx"
- myifc.cpp
#include "myifc.h" class MyIfcImpl : public maxon::Component<MyIfcImpl,MyIfc> { MAXON_COMPONENT(); public: MAXON_METHOD void Hello() { } }; MAXON_COMPONENT_CLASS_REGISTER(MyIfcImpl, MyIfcDecl);
- main.cpp
#include "myifc.h" extern "C" __declspec(dllexport) int c4d_main(int action, void* p1, void* p2, void* p3) { MyIfcRef ifc = MyIfcDecl().Create(); // A return 1; }
At line A , I got the following error
error C2440: 'initializing': cannot convert from 'maxon::Result<MyIfcRef>' to 'MyIfcRef'
How does this happen? Many thanks!
-
RE: vcxproj toolset configuration
@ferdinand Thanks for reply. I think I understood it. As an workarround, I can replace all the v142 in generated vcxproj with v143. I'm not using VS IDE , so I have to do it manually.
-
vcxproj toolset configuration
Hi guys,
I'm newbie for C4D SDK. I'm using MSVC to build the SDK. My MSVC toolchain only support v143 toolset (I mean PlatformToolset in vcxproj file). But the SDK generated vcxproj use v142. So my question is : is there any way to change the default v412 to v143? Many thanks!