猫史档案馆


imgainary_number

imgainary_number

Lv.1

很多人把画面作为评价一个作品的标准,然而我不那么认为,我认为一个游戏应该是玩法占大头

获赞:12617收藏:1348浏览:68724作品收藏:2541

签名:这么想来,我在bcm已有将近6年的时间了,如今也应该做个告别 是的,我退猫了 3年的时间我在和大伙一样用2D 而我却又花了3年的时间研究了3D 开发了光线追踪,空间音频,导入外部模型,遮挡剔除,光栅化,LOD... 以及众多版本的3D游戏引擎,建立起了一个完整的bcm3D游戏工作流 但是那也只是过去的事了 不论是bcm也好,ccw也好,但是它们都已经不适合我了,但是在这累计的一些经验却是十分有用的 以后我主要在stream上发布作品,使用Godot进行创作

回复帖子评论
上一页9 页 / 共 16下一页

太恐怖了😱 中回复

宁说的是scratch和kitten么?

2024-07-01T20:31:22 点赞:1

新3D引擎预告 中回复

预计将实现光照模型

obj模型导入

多边形碰撞等

2024-07-01T21:27:38 点赞:0

新3D引擎预告 中回复

center_image

2024-07-01T21:39:15 点赞:0

新3D引擎预告 中回复

center_image

2024-07-01T21:42:29 点赞:0

[灌水]我妹不仅会魔法攻击,还会物理攻击 中回复

*Timmie发出耀眼的光芒并伴随着尖锐的爆鸣声()

2024-07-02T21:34:26 点赞:3

哈哈哈放假了 中回复

我也

2024-07-05T22:00:55 点赞:1

我的成长记录 中回复

center_image

谁比我厉害

2024-07-06T11:54:50 点赞:0

比较器.exe 中回复

输入两个数,在选择等于或不等于,它就会输出0或1

2024-07-06T13:56:26 点赞:0

比较器.exe 中回复

center_image

3=1 ( return 0)

center_image

3!=1 (return 1)

 

2024-07-06T13:58:28 点赞:0

一个小游戏:请打出楼下名字的第一个字和最后一个字 中回复

张家

2024-07-06T18:05:03 点赞:0

一个小游戏:请打出楼下名字的第一个字和最后一个字 中回复

「」

2024-07-06T18:11:16 点赞:0

扫厕所 照片【转】 中回复

老图(?

2024-07-07T09:51:51 点赞:1

说说你楼下的名字应该配什么头像 中回复

紫薯

2024-07-07T13:39:04 点赞:0

看到的来聊会天(可将楼主当作靶子) 中回复

hello

2024-07-07T16:19:36 点赞:0

构思编程猫 中回复

你还别说,我之前给kitten测过速

结果是这样的

NO.1 kitten3

NO.2 kitten4

NO.3 kittenN

在这几个版本里kitten3是最快的,可能Nome更快

2024-07-07T19:11:42 点赞:0

求助求回复:摸不透kn怎么办!!! 中回复

kittenN的一步执行是kitten全版本最慢的

2024-07-08T07:54:13 点赞:2

假如这是你最后一次登陆毛毡 中回复

会当众发电

2024-07-08T10:33:04 点赞:0

✟猫站圣经✟ 中回复

✟猫门✟

2024-07-08T13:50:39 点赞:1

【讨论】该怎让优化3D引擎才能达到不低于10帧的情况下渲染10000给三角形? 中回复

我认为要在不低于10帧的情况下渲染10000个三角形应该需要两个角色并行运算

然后还得有一个顶点缓存

2024-07-08T14:48:35 点赞:0

当别人问我为什么一个音频处理那么久 中回复

各位不要误会了,这里的无缝音频指的是可以无限播放下去而不会出现衔接痕迹的音频

2024-07-08T19:56:03 点赞:0

深蓝浅蓝4434收徒喽 中回复

收我(bushi

2024-07-09T08:57:34 点赞:0

C++!!! 中回复

#include <iostream>
#include <cmath>

const int screenWidth = 80;   // 输出屏幕的宽度
const int screenHeight = 40;  // 输出屏幕的高度

struct Vec3 {
    double x, y, z;

    Vec3(double x_ = 0, double y_ = 0, double z_ = 0) : x(x_), y(y_), z(z_) {}

    double lengthSquared() const {
        return x * x + y * y + z * z;
    }

    double length() const {
        return sqrt(lengthSquared());
    }

    Vec3 normalize() const {
        double len = length();
        return Vec3(x / len, y / len, z / len);
    }

    Vec3 operator+(const Vec3& rhs) const {
        return Vec3(x + rhs.x, y + rhs.y, z + rhs.z);
    }

    Vec3 operator-(const Vec3& rhs) const {
        return Vec3(x - rhs.x, y - rhs.y, z - rhs.z);
    }

    Vec3 operator*(double scalar) const {
        return Vec3(x * scalar, y * scalar, z * scalar);
    }

    double dot(const Vec3& rhs) const {
        return x * rhs.x + y * rhs.y + z * rhs.z;
    }

    Vec3 cross(const Vec3& rhs) const {
        return Vec3(y * rhs.z - z * rhs.y,
            z * rhs.x - x * rhs.z,
            x * rhs.y - y * rhs.x);
    }
};

struct Sphere {
    Vec3 center;
    double radius;

    Sphere(const Vec3& center_, double radius_) : center(center_), radius(radius_) {}

    bool intersect(const Vec3& orig, const Vec3& dir, double& t) const {
        Vec3 oc = orig - center;
        double a = dir.dot(dir);
        double b = 2.0 * oc.dot(dir);
        double c = oc.dot(oc) - radius * radius;
        double discriminant = b * b - 4 * a * c;
        if (discriminant < 0) return false;
        double sqrtD = sqrt(discriminant);
        double t1 = (-b - sqrtD) / (2.0 * a);
        double t2 = (-b + sqrtD) / (2.0 * a);
        if (t1 > t2) std::swap(t1, t2);
        if (t1 < 0) {
            t1 = t2;
            if (t1 < 0) return false;
        }
        t = t1;
        return true;
    }
};

char rayTrace(const Vec3& orig, const Vec3& dir, const Sphere& sphere) {
    double t;
    if (sphere.intersect(orig, dir, t)) {
        Vec3 hitPoint = orig + dir * t;
        Vec3 normal = (hitPoint - sphere.center).normalize();
        double intensity = normal.dot(Vec3(1, 1, 1).normalize());

        const char chars[] = "@%#*+=-:. ";
        int charIdx = static_cast<int>(intensity * (sizeof(chars) - 1));
        return chars[charIdx];
    }
    return ' ';
}

int main() {
    Sphere sphere(Vec3(0, 0, -10), 3.0);

    double screenDist = 10.0; 

    for (double t = 0; t < 100; t += 0.1) { 
        Vec3 cameraPos(6 * cos(t), 0, 10 * sin(t));

        for (int y = 0; y < screenHeight; ++y) {
            for (int x = 0; x < screenWidth; ++x) {
                double screenX = (2.0 * x - screenWidth) / double(screenWidth);
                double screenY = (2.0 * y - screenHeight) / double(screenHeight);
                Vec3 rayDir(screenX, -screenY, -screenDist);
                rayDir = rayDir.normalize();

                char pixel = rayTrace(cameraPos, rayDir, sphere);
                std::cout << pixel;
            }
            std::cout << std::endl;
        }

        std::cout << "\x1b[H"; 

    }

    return 0;
}

光线追踪

2024-07-10T13:54:29 点赞:0

求助!!! 中回复

center_image

2024-07-10T16:43:22 点赞:0

小调查请问你们用的都是什么浏览器,我用的是谷歌 中回复

center_image

2024-07-11T13:01:31 点赞:0

第一个3D游戏将在八月左右做好 中回复

做的完么?

Z-Clip Triangle问题解决没有?

2024-07-11T17:14:08 点赞:0

【问卷调查】我想知道我们的处境,和我们的对策 中回复

A

C

B

C

A,B,C

2024-07-12T10:03:03 点赞:0

【小游戏】把你最近复制或保存的图片发出来 中回复

center_image.

2024-07-13T15:04:35 点赞:0

说说你楼下的名字应该配什么头像 中回复

center_image

2024-07-14T12:02:09 点赞:0

我就不信去我网站也抢不到700000 中回复

现在是12了(笑

2024-07-14T12:33:25 点赞:0

满级代码. 中回复

center_image

center_image

 

2024-07-14T12:39:27 点赞:1