2024-04-11 10:13:15 +08:00
|
|
|
#include <iostream>
|
|
|
|
|
#include "refl/refl.h"
|
2024-04-03 17:58:02 +08:00
|
|
|
using namespace std;
|
2024-04-11 10:13:15 +08:00
|
|
|
using namespace refl;
|
|
|
|
|
struct vec3_parent {
|
2024-04-16 16:17:13 +08:00
|
|
|
virtual int norm(int x1, int& x2) {
|
2024-04-11 10:13:15 +08:00
|
|
|
x2 = x1 * x2;
|
2024-04-16 16:17:13 +08:00
|
|
|
return x2;
|
2024-04-11 10:13:15 +08:00
|
|
|
//cout << x2 << "vec3_parent::norm" << endl;
|
|
|
|
|
}
|
2024-04-03 17:58:02 +08:00
|
|
|
};
|
2024-04-11 10:13:15 +08:00
|
|
|
struct vec3 : public vec3_parent {
|
2024-04-28 00:23:35 +08:00
|
|
|
using MyMeta = class vec3_Meta;
|
2024-04-29 15:00:09 +08:00
|
|
|
UPROPERTY_vk({ 1.f})
|
2024-04-11 10:13:15 +08:00
|
|
|
float x = 1;
|
2024-04-29 15:00:09 +08:00
|
|
|
UPROPERTY_dx({ 2.f})
|
2024-06-14 22:24:52 +08:00
|
|
|
int y = 2;
|
2024-04-29 15:00:09 +08:00
|
|
|
UPROPERTY({ 5.f})
|
2024-06-14 22:24:52 +08:00
|
|
|
uint32_t z = 3;
|
2024-04-29 15:00:09 +08:00
|
|
|
UPROPERTY({ "hello meta"})
|
2024-06-14 22:24:52 +08:00
|
|
|
string name = "???a";
|
2024-04-29 15:00:09 +08:00
|
|
|
UFUNCTION({})
|
2024-06-14 22:24:52 +08:00
|
|
|
vec3() {
|
2024-04-11 10:13:15 +08:00
|
|
|
}
|
2024-06-14 22:24:52 +08:00
|
|
|
UFUNCTION({1, 2.f, 3.f})
|
|
|
|
|
vec3(float x1, int y1, uint32_t z1) {
|
|
|
|
|
x = x1;
|
|
|
|
|
y = y1;
|
|
|
|
|
z = z1;
|
2024-04-11 10:13:15 +08:00
|
|
|
}
|
2024-04-19 22:02:27 +08:00
|
|
|
};
|
2024-04-29 15:00:09 +08:00
|
|
|
#include "vertex_gen.inl"
|